Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Simox
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Florian Leander Singer
Simox
Commits
f552baab
Commit
f552baab
authored
5 years ago
by
Rainer Kartmann
Browse files
Options
Downloads
Patches
Plain Diff
Add setter
parent
4ed2b381
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
VirtualRobot/XML/mujoco/MujocoIO.cpp
+5
-0
5 additions, 0 deletions
VirtualRobot/XML/mujoco/MujocoIO.cpp
VirtualRobot/XML/mujoco/MujocoIO.h
+9
-5
9 additions, 5 deletions
VirtualRobot/XML/mujoco/MujocoIO.h
with
14 additions
and
5 deletions
VirtualRobot/XML/mujoco/MujocoIO.cpp
+
5
−
0
View file @
f552baab
...
...
@@ -728,6 +728,11 @@ void MujocoIO::setActuatorTypeSuffixes(const std::map<ActuatorType, std::string>
this
->
actuatorTypeSuffixes
=
suffixes
;
}
void
MujocoIO
::
setBodySanitizeMode
(
BodySanitizeMode
mode
)
{
this
->
bodySanitizeMode
=
mode
;
}
void
MujocoIO
::
setWithMocapBody
(
bool
enabled
)
{
this
->
withMocapBody
=
enabled
;
...
...
This diff is collapsed.
Click to expand it.
VirtualRobot/XML/mujoco/MujocoIO.h
+
9
−
5
View file @
f552baab
...
...
@@ -8,18 +8,17 @@
#include
"BodySanitizer.h"
namespace
VirtualRobot
{
namespace
mujoco
namespace
VirtualRobot
::
mujoco
{
/// Actuator type.
enum
class
ActuatorType
{
MOTOR
,
POSITION
,
VELOCITY
,
};
ActuatorType
toActuatorType
(
const
std
::
string
&
string
);
/// Body sanitization mode.
enum
class
BodySanitizeMode
{
...
...
@@ -29,6 +28,9 @@ namespace mujoco
BodySanitizeMode
toBodySanitizeMode
(
const
std
::
string
&
string
);
/**
* @brief Converts a VirtualRobot robot model to MuJoCo MJCF format.
*/
class
MujocoIO
{
public:
...
...
@@ -66,6 +68,8 @@ namespace mujoco
/// Set suffixes appended to actuator names if adding actuator type suffixes is enabled.
void
setActuatorTypeSuffixes
(
const
std
::
map
<
ActuatorType
,
std
::
string
>&
suffixes
);
/// Set the body sanitize mode.
void
setBodySanitizeMode
(
BodySanitizeMode
mode
);
/**
* @brief Enable or disable adding of a mocap body controlling the robot pose.
...
...
@@ -201,4 +205,4 @@ namespace mujoco
};
}
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment