Blender
V3.3
|
#include <attribute.h>
Public Member Functions | |
AttributeSet (Geometry *geometry, AttributePrimitive prim) | |
AttributeSet (AttributeSet &&)=default | |
~AttributeSet () | |
Attribute * | add (ustring name, TypeDesc type, AttributeElement element) |
Attribute * | find (ustring name) const |
void | remove (ustring name) |
Attribute * | add (AttributeStandard std, ustring name=ustring()) |
Attribute * | find (AttributeStandard std) const |
void | remove (AttributeStandard std) |
Attribute * | find (AttributeRequest &req) |
Attribute * | find_matching (const Attribute &other) |
void | remove (Attribute *attribute) |
void | remove (list< Attribute >::iterator it) |
void | resize (bool reserve_only=false) |
void | clear (bool preserve_voxel_data=false) |
void | update (AttributeSet &&new_attributes) |
bool | modified (AttrKernelDataType kernel_type) const |
void | clear_modified () |
Public Attributes | |
Geometry * | geometry |
AttributePrimitive | prim |
list< Attribute > | attributes |
Definition at line 176 of file scene/attribute.h.
AttributeSet::AttributeSet | ( | Geometry * | geometry, |
AttributePrimitive | prim | ||
) |
Definition at line 451 of file scene/attribute.cpp.
|
default |
AttributeSet::~AttributeSet | ( | ) |
Definition at line 456 of file scene/attribute.cpp.
Attribute * AttributeSet::add | ( | AttributeStandard | std, |
ustring | name = ustring() |
||
) |
Definition at line 504 of file scene/attribute.cpp.
References add(), ATTR_ELEMENT_CORNER, ATTR_ELEMENT_CORNER_BYTE, ATTR_ELEMENT_CURVE, ATTR_ELEMENT_CURVE_KEY, ATTR_ELEMENT_CURVE_KEY_MOTION, ATTR_ELEMENT_FACE, ATTR_ELEMENT_MESH, ATTR_ELEMENT_VERTEX, ATTR_ELEMENT_VERTEX_MOTION, ATTR_ELEMENT_VOXEL, ATTR_STD_CURVE_INTERCEPT, ATTR_STD_CURVE_LENGTH, ATTR_STD_CURVE_RANDOM, ATTR_STD_FACE_NORMAL, ATTR_STD_GENERATED, ATTR_STD_GENERATED_TRANSFORM, ATTR_STD_MOTION_VERTEX_NORMAL, ATTR_STD_MOTION_VERTEX_POSITION, ATTR_STD_POINT_RANDOM, ATTR_STD_POINTINESS, ATTR_STD_POSITION_UNDEFORMED, ATTR_STD_POSITION_UNDISPLACED, ATTR_STD_PTEX_FACE_ID, ATTR_STD_PTEX_UV, ATTR_STD_RANDOM_PER_ISLAND, ATTR_STD_SHADOW_TRANSPARENCY, ATTR_STD_UV, ATTR_STD_UV_TANGENT, ATTR_STD_UV_TANGENT_SIGN, ATTR_STD_VERTEX_COLOR, ATTR_STD_VERTEX_NORMAL, ATTR_STD_VOLUME_COLOR, ATTR_STD_VOLUME_DENSITY, ATTR_STD_VOLUME_FLAME, ATTR_STD_VOLUME_HEAT, ATTR_STD_VOLUME_TEMPERATURE, ATTR_STD_VOLUME_VELOCITY, ATTR_STD_VOLUME_VELOCITY_X, ATTR_STD_VOLUME_VELOCITY_Y, ATTR_STD_VOLUME_VELOCITY_Z, geometry, Geometry::geometry_type, Geometry::HAIR, Geometry::MESH, NULL, Geometry::POINTCLOUD, Attribute::standard_name(), Attribute::std, TypeFloat2(), TypeRGBA(), and Geometry::VOLUME.
Attribute * AttributeSet::add | ( | ustring | name, |
TypeDesc | type, | ||
AttributeElement | element | ||
) |
Definition at line 460 of file scene/attribute.cpp.
References attributes, Attribute::element, element, find(), geometry, prim, remove(), Attribute::type, and type.
Referenced by add(), Mesh::add_face_normals(), Mesh::add_undisplaced(), Mesh::add_vertex_normals(), ApplyPrimvars(), attr_create_generic(), attr_create_motion(), attr_create_pointiness(), attr_create_random_per_island(), attr_create_uv(), attr_create_uv_map(), copy_attributes(), create_mesh(), GeometryManager::create_volume_mesh(), GeometryManager::device_update_attributes(), EdgeDice::EdgeDice(), export_hair_curves(), export_hair_curves_motion(), export_pointcloud(), export_pointcloud_motion(), ExportCurveSegments(), ExportCurveSegmentsMotion(), mikk_compute_tangents(), EdgeDice::reserve(), sync_smoke_volume(), sync_volume_object(), update(), Hair::update_shadow_transparency(), and xml_read_mesh().
Definition at line 731 of file scene/attribute.cpp.
References ATTR_ELEMENT_VOXEL, ATTR_STD_GENERATED_TRANSFORM, and attributes.
Referenced by Mesh::clear(), Hair::clear(), and PointCloud::clear().
void AttributeSet::clear_modified | ( | ) |
Definition at line 774 of file scene/attribute.cpp.
References attributes, and Attribute::modified.
Attribute * AttributeSet::find | ( | AttributeRequest & | req | ) |
Definition at line 700 of file scene/attribute.cpp.
References ATTR_STD_NONE, find(), AttributeRequest::name, and AttributeRequest::std.
Attribute * AttributeSet::find | ( | AttributeStandard | std | ) | const |
Definition at line 655 of file scene/attribute.cpp.
References attributes, NULL, and Attribute::std.
Attribute * AttributeSet::find | ( | ustring | name | ) | const |
Definition at line 479 of file scene/attribute.cpp.
References attributes, Attribute::name, and NULL.
Referenced by add(), Mesh::add_face_normals(), BVHBuild::add_reference_curves(), BVHBuild::add_reference_points(), BVHBuild::add_reference_triangles(), Mesh::add_undisplaced(), Mesh::add_vertex_normals(), Hair::apply_transform(), Mesh::apply_transform(), PointCloud::apply_transform(), attr_create_generic(), attr_create_motion(), Hair::compute_bounds(), Mesh::compute_bounds(), PointCloud::compute_bounds(), copy_attributes(), Hair::copy_center_to_motion_step(), Mesh::copy_center_to_motion_step(), PointCloud::copy_center_to_motion_step(), GeometryManager::device_update_attributes(), ObjectManager::device_update_object_transform(), GeometryManager::displace(), export_hair_curves_motion(), export_hair_motion_validate_attribute(), export_pointcloud_motion(), ExportCurveSegmentsMotion(), find(), Hair::get_uv_tiles(), Mesh::get_uv_tiles(), PointCloud::get_uv_tiles(), Geometry::has_motion_blur(), MikkUserData::MikkUserData(), Mesh::pack_normals(), read_shader_output(), BVH2::refit_primitives(), remove(), and Hair::update_shadow_transparency().
Definition at line 664 of file scene/attribute.cpp.
References attributes, Attribute::element, Attribute::name, Attribute::std, and Attribute::type.
bool AttributeSet::modified | ( | AttrKernelDataType | kernel_type | ) | const |
Definition at line 797 of file scene/attribute.cpp.
Referenced by update_attribute_realloc_flags().
Definition at line 708 of file scene/attribute.cpp.
References ATTR_STD_NONE, attribute, and remove().
void AttributeSet::remove | ( | AttributeStandard | std | ) |
Definition at line 684 of file scene/attribute.cpp.
References attributes, find(), and remove().
Definition at line 718 of file scene/attribute.cpp.
References attributes.
void AttributeSet::remove | ( | ustring | name | ) |
Definition at line 488 of file scene/attribute.cpp.
References attributes, and find().
Referenced by add(), attr_create_uv_map(), GeometryManager::displace(), export_hair_motion_validate_attribute(), export_pointcloud_motion(), remove(), update(), and Hair::update_shadow_transparency().
Definition at line 724 of file scene/attribute.cpp.
References attributes, geometry, prim, and Attribute::resize().
Referenced by PointCloud::reserve(), Hair::reserve_curves(), Mesh::reserve_mesh(), PointCloud::resize(), Hair::resize_curves(), and Mesh::resize_mesh().
void AttributeSet::update | ( | AttributeSet && | new_attributes | ) |
Definition at line 750 of file scene/attribute.cpp.
References add(), attributes, Attribute::element, geometry, Attribute::name, remove(), Attribute::set_data_from(), Attribute::std, Geometry::transform_applied, and Attribute::type.
list<Attribute> AttributeSet::attributes |
Definition at line 182 of file scene/attribute.h.
Referenced by add(), attr_create_generic(), clear(), clear_modified(), Object::compute_volume_step_size(), GeometryManager::create_volume_mesh(), GeometryManager::device_update_volume_images(), find(), find_matching(), Geometry::has_voxel_attributes(), remove(), resize(), update(), and update_device_flags_attribute().
Geometry* AttributeSet::geometry |
Definition at line 180 of file scene/attribute.h.
AttributePrimitive AttributeSet::prim |
Definition at line 181 of file scene/attribute.h.