cesium-native
0.41.0
|
Provides write access to an AccessorView. More...
#include <CesiumGltf/AccessorWriter.h>
Public Member Functions | |
AccessorWriter (const AccessorView< T > &accessorView) | |
Constructs a new instance from an AccessorView. | |
AccessorWriter (std::byte *pData, int64_t stride, int64_t offset, int64_t size) | |
AccessorWriter (Model &model, const Accessor &accessor) | |
Creates a new instance from a given model and Accessor. More... | |
AccessorWriter (Model &model, int32_t accessorIndex) noexcept | |
Creates a new instance from a given model and accessor index. More... | |
const T & | operator[] (int64_t i) const |
Provides the specified accessor element. More... | |
T & | operator[] (int64_t i) |
Provides the specified accessor element. More... | |
int64_t | size () const noexcept |
Returns the size (number of elements) of this accessor. More... | |
AccessorViewStatus | status () const noexcept |
Gets the status of this accessor writer. More... | |
Provides write access to an AccessorView.
Definition at line 10 of file AccessorWriter.h.
|
inline |
Definition at line 25 of file AccessorWriter.h.
|
inline |
Creates a new instance from a given model and Accessor.
If the accessor cannot be viewed, the construct will still complete successfully without throwing an exception. However, size will return 0 and status will indicate what went wrong.
model | The model to access. |
accessor | The accessor to view. |
Definition at line 29 of file AccessorWriter.h.
|
inlinenoexcept |
Creates a new instance from a given model and accessor index.
If the accessor cannot be viewed, the construct will still complete successfully without throwing an exception. However, size will return 0 and status will indicate what went wrong.
model | The model to access. |
accessorIndex | The index of the accessor to view in the model's Model::accessors list. |
Definition at line 33 of file AccessorWriter.h.
|
inline |
Provides the specified accessor element.
i | The index of the element. |
A | std::range_error if the given index is negative or not smaller than the size of this accessor. |
Definition at line 40 of file AccessorWriter.h.
|
inline |
Provides the specified accessor element.
i | The index of the element. |
A | std::range_error if the given index is negative or not smaller than the size of this accessor. |
Definition at line 37 of file AccessorWriter.h.
|
inlinenoexcept |
Returns the size (number of elements) of this accessor.
This is the number of elements of type T
that this accessor contains.
Definition at line 43 of file AccessorWriter.h.
|
inlinenoexcept |
Gets the status of this accessor writer.
Indicates whether the writer accurately reflects the accessor's data, or whether an error occurred.
Definition at line 51 of file AccessorWriter.h.