Add optional azimuth and elevation to initial free camera.
- Add `azimuth` and `elevation` to `visual.global`. - Add `mjv_defaultFreeCamera`. - Use `mjv_defaultFreeCamera` in `simulate`. PiperOrigin-RevId: 465505244 Change-Id: I61e60f14a990d4e2d220958adb75c325001978ee
This commit is contained in:
committed by
Copybara-Service
parent
5ee184ddaa
commit
b966a37855
@@ -418,8 +418,10 @@ typedef struct mjOption_ mjOption;
|
||||
|
||||
struct mjVisual_ { // visualization options
|
||||
struct { // global parameters
|
||||
float fovy; // y-field of view (deg) for free camera
|
||||
float fovy; // y-field of view for free camera (degrees)
|
||||
float ipd; // inter-pupilary distance for free camera
|
||||
float azimuth; // initial azimuth of free camera (degrees)
|
||||
float elevation; // initial elevation of free camera (degrees)
|
||||
float linewidth; // line width for wireframe and ray rendering
|
||||
float glow; // glow coefficient for selected body
|
||||
int offwidth; // width of offscreen buffer
|
||||
|
||||
@@ -492,6 +492,9 @@ MJAPI mjtNum mju_raySkin(int nface, int nvert, const int* face, const float* ver
|
||||
// Set default camera.
|
||||
MJAPI void mjv_defaultCamera(mjvCamera* cam);
|
||||
|
||||
// Set default free camera.
|
||||
MJAPI void mjv_defaultFreeCamera(const mjModel* m, mjvCamera* cam);
|
||||
|
||||
// Set default perturbation.
|
||||
MJAPI void mjv_defaultPerturb(mjvPerturb* pert);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user