Rename mj_stackAlloc to mj_stackAllocNum.
PiperOrigin-RevId: 561040193 Change-Id: I49ea21ffb5b596471d2aacefb1961c11c5c905d0
This commit is contained in:
committed by
Copybara-Service
parent
ea5e00cad8
commit
b979a26b10
@@ -53,12 +53,12 @@ mjMARKSTACK
|
||||
#define mjMARKSTACK int _mark = d->pstack;
|
||||
|
||||
This macro is helpful when using the MuJoCo stack in custom computations. It works together with the next macro and the
|
||||
:ref:`mj_stackAlloc` function, and assumes that mjData\* d is defined. The use pattern is this:
|
||||
:ref:`mj_stackAlloc` family of functions, and assumes that mjData\* d is defined. The use pattern is this:
|
||||
|
||||
.. code-block:: C
|
||||
|
||||
mjMARKSTACK;
|
||||
mjtNum* temp = mj_stackAlloc(d, 100);
|
||||
mjtNum* temp = mj_stackAllocNum(d, 100);
|
||||
// ... use temp as needed
|
||||
mjFREESTACK;
|
||||
|
||||
|
||||
@@ -1232,12 +1232,12 @@ mj_resetDataKeyframe
|
||||
|
||||
Reset data, set fields from specified keyframe.
|
||||
|
||||
.. _mj_stackAlloc:
|
||||
.. _mj_stackAllocNum:
|
||||
|
||||
mj_stackAlloc
|
||||
~~~~~~~~~~~~~
|
||||
mj_stackAllocNum
|
||||
~~~~~~~~~~~~~~~~
|
||||
|
||||
.. mujoco-include:: mj_stackAlloc
|
||||
.. mujoco-include:: mj_stackAllocNum
|
||||
|
||||
Allocate array of mjtNums on :ref:`mjData` stack. Call mju_error on stack overflow.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user