Rename mjBuffer to mjByteVec.
PiperOrigin-RevId: 664872558 Change-Id: I7b003374c390958667635fb21089faf2ece54b14
This commit is contained in:
committed by
Copybara-Service
parent
4aab00fa2d
commit
5d91231d31
@@ -33,7 +33,6 @@ extern "C" {
|
||||
|
||||
#ifdef __cplusplus
|
||||
// C++: defined to be compatible with corresponding std types
|
||||
using mjBuffer = std::vector<std::byte>;
|
||||
using mjString = std::string;
|
||||
using mjStringVec = std::vector<std::string>;
|
||||
using mjIntVec = std::vector<int>;
|
||||
@@ -41,9 +40,9 @@ extern "C" {
|
||||
using mjFloatVec = std::vector<float>;
|
||||
using mjFloatVecVec = std::vector<std::vector<float>>;
|
||||
using mjDoubleVec = std::vector<double>;
|
||||
using mjByteVec = std::vector<std::byte>;
|
||||
#else
|
||||
// C: opaque types
|
||||
typedef void mjBuffer;
|
||||
typedef void mjString;
|
||||
typedef void mjStringVec;
|
||||
typedef void mjIntVec;
|
||||
@@ -51,6 +50,7 @@ extern "C" {
|
||||
typedef void mjFloatVec;
|
||||
typedef void mjFloatVecVec;
|
||||
typedef void mjDoubleVec;
|
||||
typedef void mjByteVec;
|
||||
#endif
|
||||
|
||||
|
||||
@@ -515,7 +515,7 @@ typedef struct mjsTexture_ { // texture specification
|
||||
mjStringVec* cubefiles; // different file for each side of the cube
|
||||
|
||||
// method 4: from buffer read by user
|
||||
mjBuffer* data; // texture data
|
||||
mjByteVec* data; // texture data
|
||||
|
||||
// flip options
|
||||
mjtByte hflip; // horizontal flip
|
||||
|
||||
@@ -1630,7 +1630,7 @@ MJAPI mjsMaterial* mjs_asMaterial(mjsElement* element);
|
||||
//---------------------------------- Attribute setters ---------------------------------------------
|
||||
|
||||
// Copy buffer.
|
||||
MJAPI void mjs_setBuffer(mjBuffer* dest, const void* array, int size);
|
||||
MJAPI void mjs_setBuffer(mjByteVec* dest, const void* array, int size);
|
||||
|
||||
// Copy text to string.
|
||||
MJAPI void mjs_setString(mjString* dest, const char* text);
|
||||
|
||||
Reference in New Issue
Block a user