|
Blender V4.3
|
#include <usd_reader_instance.hh>
Inherits blender::io::usd::USDXformReader.
Public Member Functions | |
| USDInstanceReader (const pxr::UsdPrim &prim, const USDImportParams &import_params, const ImportSettings &settings) | |
| bool | valid () const override |
| void | create_object (Main *bmain, double motionSampleTime) override |
| void | set_instance_collection (Collection *coll) |
| pxr::SdfPath | proto_path () const |
Public Member Functions inherited from blender::io::usd::USDXformReader | |
| USDXformReader (const pxr::UsdPrim &prim, const USDImportParams &import_params, const ImportSettings &settings) | |
| void | create_object (Main *bmain, double motionSampleTime) override |
| void | read_object_data (Main *bmain, double motionSampleTime) override |
| void | read_matrix (float r_mat[4][4], float time, float scale, bool *r_is_constant) const |
| bool | use_parent_xform () const |
| void | set_use_parent_xform (bool flag) |
| bool | prim_has_xform_ops () const |
Public Member Functions inherited from blender::io::usd::USDPrimReader | |
| USDPrimReader (const pxr::UsdPrim &prim, const USDImportParams &import_params, const ImportSettings &settings) | |
| virtual | ~USDPrimReader () |
| const pxr::UsdPrim & | prim () const |
| Object * | object () const |
| void | object (Object *ob) |
| USDPrimReader * | parent () const |
| void | parent (USDPrimReader *parent) |
| ReportList * | reports () const |
| int | refcount () const |
| void | incref () |
| void | decref () |
| const std::string & | name () const |
| const std::string & | prim_path () const |
| void | set_is_in_instancer_proto (bool flag) |
| bool | is_in_instancer_proto () const |
| bool | is_in_proto () const |
Additional Inherited Members | |
Protected Member Functions inherited from blender::io::usd::USDXformReader | |
| bool | is_root_xform_prim () const |
| virtual std::optional< XformResult > | get_local_usd_xform (float time) const |
Protected Member Functions inherited from blender::io::usd::USDPrimReader | |
| void | set_props (bool merge_with_parent=false, pxr::UsdTimeCode motionSampleTime=pxr::UsdTimeCode::Default()) |
Protected Attributes inherited from blender::io::usd::USDPrimReader | |
| std::string | name_ |
| std::string | prim_path_ |
| Object * | object_ |
| pxr::UsdPrim | prim_ |
| const USDImportParams & | import_params_ |
| USDPrimReader * | parent_reader_ |
| const ImportSettings * | settings_ |
| int | refcount_ |
| bool | is_in_instancer_proto_ |
Convert a USD instanced prim to a blender collection instance.
Definition at line 16 of file usd_reader_instance.hh.
| blender::io::usd::USDInstanceReader::USDInstanceReader | ( | const pxr::UsdPrim & | prim, |
| const USDImportParams & | import_params, | ||
| const ImportSettings & | settings ) |
Definition at line 15 of file usd_reader_instance.cc.
|
overridevirtual |
Create an object that instances a collection.
Implements blender::io::usd::USDPrimReader.
Definition at line 27 of file usd_reader_instance.cc.
References BKE_object_add_only_object(), Object::data, Object::instance_collection, blender::io::usd::USDPrimReader::name_, OB_DUPLICOLLECTION, OB_EMPTY, blender::io::usd::USDPrimReader::object_, and Object::transflag.
| pxr::SdfPath blender::io::usd::USDInstanceReader::proto_path | ( | ) | const |
Get the path of the USD prototype prim.
Definition at line 47 of file usd_reader_instance.cc.
References blender::io::usd::USDPrimReader::prim_.
Referenced by blender::io::usd::set_instance_collection().
| void blender::io::usd::USDInstanceReader::set_instance_collection | ( | Collection * | coll | ) |
Assign the given collection to the object.
Definition at line 35 of file usd_reader_instance.cc.
References Collection::id, id_us_min(), id_us_plus(), Object::instance_collection, and blender::io::usd::USDPrimReader::object_.
Referenced by blender::io::usd::set_instance_collection().
|
overridevirtual |
Reimplemented from blender::io::usd::USDPrimReader.
Definition at line 22 of file usd_reader_instance.cc.
References blender::io::usd::USDPrimReader::prim_.