Bifrost SDK
Bifrost SDK documentation
Data GeoProperty

Functions

Amino::Ptr< Bifrost::Object > BIFROST_GEOMETRY_DECL Bifrost::Geometry::getDataGeoPropPrototype (Amino::StringView property=Geometry::sGenericDataGeoProp)
 Returns the prototypical data geometry property object. More...
 
template<typename T >
void Bifrost::Geometry::populateDataGeoProperty (T defaultValue, Bifrost::Object &object)
 Populate a Geometry object with the required properties to conform to the data geometry property schema. More...
 
template<typename DataType >
void Bifrost::Geometry::populateDataGeoProperty (const DataType &defaultValue, Amino::Ptr< Amino::Array< DataType > > data, Amino::StringView target, Bifrost::Object &geoProp)
 Populate a Geometry object with the required properties to conform to the data geometry property schema. More...
 
Amino::Ptr< Bifrost::Object > BIFROST_GEOMETRY_DECL Bifrost::Geometry::getDataGeoProperty (const Bifrost::Object &object, Amino::StringView property)
 Get a geo property from an object, with the specified name. More...
 
template<typename T >
Amino::Ptr< Amino::Array< T > > Bifrost::Geometry::getDataGeoPropValues (const Bifrost::Object &object, Amino::StringView property)
 Get the actual data array from a data geometry property. More...
 
template<typename DataType >
bool Bifrost::Geometry::setDataGeoPropValues (Amino::StringView property, Amino::Ptr< Amino::Array< DataType > > dataPropValues, Bifrost::Object &object)
 Sets the actual data array in a data geometry property. More...
 
bool BIFROST_GEOMETRY_DECL Bifrost::Geometry::isOffsetDataGeoProp (const Bifrost::Object &object, Amino::StringView property)
 Queries if the specified property is an offset array. More...
 

Detailed Description

Functions for manipulating Data GeoProperties.

Function Documentation

◆ getDataGeoProperty()

Amino::Ptr< Bifrost::Object > BIFROST_GEOMETRY_DECL Bifrost::Geometry::getDataGeoProperty ( const Bifrost::Object object,
Amino::StringView  property 
)

Get a geo property from an object, with the specified name.

Parameters
[in]objectThe data geo property.
[in]propertyThe property name.
Returns
The data geo property object, or nullptr if it does not exist.

Referenced by Bifrost::Geometry::hasDataGeoProperty().

◆ getDataGeoPropPrototype()

Amino::Ptr< Bifrost::Object > BIFROST_GEOMETRY_DECL Bifrost::Geometry::getDataGeoPropPrototype ( Amino::StringView  property = Geometry::sGenericDataGeoProp)

Returns the prototypical data geometry property object.

The returned pointer may be used in conjunction with Bifrost::Object::isA to determine if an object conforms to the data geometry property schema. The returned object may not be modified.

If the generic data geometry property object is returned then it will match with any data geometry property whatever the specific data and default types of the data geometry property checked with Bifrost::Object::isA.

Parameters
[in]propertyThe name of a standard data geometry property found on a standard geometry prototype built from a geometry schema. If the data geometry property does not exists then an invalid data geometry property prototype is returned and nothing will match with it.
Returns
The data geometry property prototype.

◆ getDataGeoPropValues()

template<typename T >
Amino::Ptr< Amino::Array< T > > Bifrost::Geometry::getDataGeoPropValues ( const Bifrost::Object object,
Amino::StringView  property 
)

Get the actual data array from a data geometry property.

Parameters
[in]objectObject on which to look for the data geometry property.
[in]propertyData geometry property name. If this name does not specify a valid data geometry property, this function will fail.
Returns
Referenced counted pointer to the array of data. The reference count secures the data access.

Definition at line 258 of file GeoProperty.h.

References Bifrost::Geometry::sData.

◆ isOffsetDataGeoProp()

bool BIFROST_GEOMETRY_DECL Bifrost::Geometry::isOffsetDataGeoProp ( const Bifrost::Object object,
Amino::StringView  property 
)

Queries if the specified property is an offset array.

Parameters
[in]objectObject on which to look for the data geometry property.
[in]propertyData geometry property name.
Returns
True if the data geo property exists on the object and is an offset array.

◆ populateDataGeoProperty() [1/2]

template<typename DataType >
void Bifrost::Geometry::populateDataGeoProperty ( const DataType &  defaultValue,
Amino::Ptr< Amino::Array< DataType > >  data,
Amino::StringView  target,
Bifrost::Object geoProp 
)

Populate a Geometry object with the required properties to conform to the data geometry property schema.

The geo property is initialized with the specified data.

Parameters
[in]defaultValueThe default value of the data geometry property.
[in]dataThe Amino::Array of initial data.
[in]targetThe target of the geo property.
[in,out]geoPropObject to be populated.

Definition at line 232 of file GeoProperty.h.

References Bifrost::Geometry::populateDataGeoProperty(), Bifrost::Geometry::sData, Bifrost::Object::setProperty(), and Bifrost::Geometry::sTarget.

◆ populateDataGeoProperty() [2/2]

template<typename T >
void Bifrost::Geometry::populateDataGeoProperty ( defaultValue,
Bifrost::Object object 
)

Populate a Geometry object with the required properties to conform to the data geometry property schema.

The geo property is initially empty.

Parameters
[in]defaultValueThe default value of the data geometry property.
[in,out]objectObject to be populated.

Definition at line 206 of file GeoProperty.h.

References Bifrost::Geometry::Common::Linear, Bifrost::Geometry::sData, Bifrost::Geometry::sDefault, Bifrost::Geometry::sDependsOn, Bifrost::Geometry::sInterp, Bifrost::Geometry::sNullString, and Bifrost::Geometry::sTarget.

Referenced by Bifrost::Geometry::populateDataGeoProperty().

◆ setDataGeoPropValues()

template<typename DataType >
bool Bifrost::Geometry::setDataGeoPropValues ( Amino::StringView  property,
Amino::Ptr< Amino::Array< DataType > >  dataPropValues,
Bifrost::Object object 
)

Sets the actual data array in a data geometry property.

Parameters
[in]propertyData geometry property name. If this name does not specify a valid data geometry property, this function will fail.
[in]dataPropValuesThe new Amino::Array of data to set in the data geo property.
[in,out]objectParent object of the data geometry property.
Returns
true on success, false otherwise.

Definition at line 279 of file GeoProperty.h.

References Bifrost::Geometry::sData.