Blender
V3.3
|
#include <usd_writer_abstract.h>
Public Member Functions | |
USDAbstractWriter (const USDExporterContext &usd_export_context) | |
virtual void | write (HierarchyContext &context) override |
virtual bool | is_supported (const HierarchyContext *context) const |
const pxr::SdfPath & | usd_path () const |
![]() | |
virtual | ~AbstractHierarchyWriter ()=default |
Protected Member Functions | |
virtual void | do_write (HierarchyContext &context)=0 |
std::string | get_export_file_path () const |
pxr::UsdTimeCode | get_export_time_code () const |
pxr::UsdShadeMaterial | ensure_usd_material (const HierarchyContext &context, Material *material) |
void | write_visibility (const HierarchyContext &context, const pxr::UsdTimeCode timecode, pxr::UsdGeomImageable &usd_geometry) |
virtual bool | mark_as_instance (const HierarchyContext &context, const pxr::UsdPrim &prim) |
![]() | |
virtual bool | check_is_animated (const HierarchyContext &context) const |
Protected Attributes | |
const USDExporterContext | usd_export_context_ |
pxr::UsdUtilsSparseValueWriter | usd_value_writer_ |
bool | frame_has_been_written_ |
bool | is_animated_ |
Additional Inherited Members | |
![]() | |
static bool | check_has_physics (const HierarchyContext &context) |
static bool | check_has_deforming_physics (const HierarchyContext &context) |
Definition at line 26 of file usd_writer_abstract.h.
blender::io::usd::USDAbstractWriter::USDAbstractWriter | ( | const USDExporterContext & | usd_export_context | ) |
Definition at line 40 of file usd_writer_abstract.cc.
|
protectedpure virtual |
|
protected |
Definition at line 87 of file usd_writer_abstract.cc.
References blender::compositor::context, blender::io::usd::create_usd_preview_surface_material(), blender::io::usd::create_usd_viewport_material(), blender::io::AbstractHierarchyIterator::get_id_name(), get_mesh_active_uvlayer_name(), blender::io::usd::USDExporterContext::hierarchy_iterator, Material::id, material, stage, blender::io::usd::USDExporterContext::stage, usd_export_context_, usd_path(), and Material::use_nodes.
|
protected |
Definition at line 50 of file usd_writer_abstract.cc.
References blender::io::usd::USDHierarchyIterator::get_export_file_path(), blender::io::usd::USDExporterContext::hierarchy_iterator, and usd_export_context_.
|
protected |
Definition at line 55 of file usd_writer_abstract.cc.
References blender::io::usd::USDHierarchyIterator::get_export_time_code(), blender::io::usd::USDExporterContext::hierarchy_iterator, is_animated_, and usd_export_context_.
Referenced by blender::io::usd::USDCameraWriter::do_write(), blender::io::usd::USDHairWriter::do_write(), blender::io::usd::USDLightWriter::do_write(), blender::io::usd::USDTransformWriter::do_write(), and blender::io::usd::USDVolumeWriter::do_write().
|
virtual |
Returns true if the data to be written is actually supported. This would, for example, allow a hypothetical camera writer accept a perspective camera but reject an orthogonal one.
Returning false from a transform writer will prevent the object and all its descendants from being exported. Returning false from a data writer (object data, hair, or particles) will only prevent that data from being written (and thus cause the object to be exported as an Empty).
Reimplemented in blender::io::usd::USDMetaballWriter, blender::io::usd::USDGenericMeshWriter, blender::io::usd::USDLightWriter, and blender::io::usd::USDCameraWriter.
Definition at line 45 of file usd_writer_abstract.cc.
Referenced by blender::io::usd::USDHierarchyIterator::create_data_writer().
|
protectedvirtual |
Turn prim
into an instance referencing context.original_export_path
. Return true when the instancing was successful, false otherwise.
Reference the original data instead of writing a copy.
Definition at line 128 of file usd_writer_abstract.cc.
References BLI_assert, BLI_assert_msg, and blender::compositor::context.
const pxr::SdfPath & blender::io::usd::USDAbstractWriter::usd_path | ( | ) | const |
Definition at line 82 of file usd_writer_abstract.cc.
References usd_export_context_, and blender::io::usd::USDExporterContext::usd_path.
Referenced by blender::io::usd::USDLightWriter::do_write(), and ensure_usd_material().
|
overridevirtual |
Implements blender::io::AbstractHierarchyWriter.
Definition at line 66 of file usd_writer_abstract.cc.
References blender::io::AbstractHierarchyWriter::check_is_animated(), blender::compositor::context, do_write(), USDExportParams::export_animation, blender::io::usd::USDExporterContext::export_params, frame_has_been_written_, is_animated_, and usd_export_context_.
|
protected |
Definition at line 114 of file usd_writer_abstract.cc.
References blender::compositor::context, USDExportParams::evaluation_mode, blender::io::usd::USDExporterContext::export_params, usd_export_context_, and usd_value_writer_.
|
protected |
Definition at line 31 of file usd_writer_abstract.h.
Referenced by write().
|
protected |
Definition at line 32 of file usd_writer_abstract.h.
Referenced by get_export_time_code(), and write().
|
protected |
Definition at line 28 of file usd_writer_abstract.h.
Referenced by blender::io::usd::USDCameraWriter::do_write(), blender::io::usd::USDHairWriter::do_write(), blender::io::usd::USDLightWriter::do_write(), blender::io::usd::USDTransformWriter::do_write(), blender::io::usd::USDVolumeWriter::do_write(), ensure_usd_material(), get_export_file_path(), blender::io::usd::USDMetaballWriter::get_export_mesh(), get_export_time_code(), blender::io::usd::USDGenericMeshWriter::is_supported(), blender::io::usd::USDMetaballWriter::is_supported(), usd_path(), write(), and write_visibility().
|
protected |
Definition at line 29 of file usd_writer_abstract.h.
Referenced by blender::io::usd::USDHairWriter::do_write(), and write_visibility().