|
Blender V5.3
|
#include <BKE_attribute.hh>
Public Member Functions | |
| SpanAttributeWriter ()=default | |
| SpanAttributeWriter (AttributeWriter< T > &&other, const bool copy_values_to_span) | |
| operator bool () const | |
| void | finish () |
Public Attributes | |
| MutableVArraySpan< T > | span |
| AttrDomain | domain |
| std::function< void()> | tag_modified_fn |
A version of AttributeWriter for the common case when the user of the attribute wants to write to a span instead of a virtual array. Since most attributes are spans internally, this can result in better performance and also simplifies code.
Definition at line 246 of file BKE_attribute.hh.
|
default |
|
inline |
Definition at line 262 of file BKE_attribute.hh.
|
inline |
Has to be called when done writing to the attribute. This makes sure that the data is copied to the underlying attribute if it was not stored as an array. Furthermore, this may invalidate other data depending on the modified attribute.
Definition at line 279 of file BKE_attribute.hh.
|
inline |
Definition at line 269 of file BKE_attribute.hh.
| AttrDomain blender::bke::SpanAttributeWriter< T >::domain |
Domain of the attribute. Also determines the size of the span.
Definition at line 254 of file BKE_attribute.hh.
| MutableVArraySpan<T> blender::bke::SpanAttributeWriter< T >::span |
A span based on the virtual array that contains the attribute data. This may be empty.
Definition at line 250 of file BKE_attribute.hh.
| std::function<void()> blender::bke::SpanAttributeWriter< T >::tag_modified_fn |
Has to be called after writing to the span.
Definition at line 258 of file BKE_attribute.hh.