object Class Reference

glTF binary object More...

Inheritance diagram for object:
[legend]
Collaboration diagram for object:
[legend]

Public Member Functions

 object ()
 Default construct. More...
 
 object (const word &name)
 Construct with name. More...
 
template<class Type >
void addData (const Type &fld)
 Add data to the buffer. More...
 
template<class Type1 , class Type2 >
void addData (const Type1 &fld1, const Type2 &fld2)
 Add data to the buffer from 2 containers of the same size. More...
 
const Foam::List< float > & data () const noexcept
 Return const access to the data buffer. More...
 
- Public Member Functions inherited from base
 base ()
 Default construct. More...
 
 base (const word &name)
 Construct with name. More...
 
 ~base ()=default
 Destructor. More...
 
label & id () noexcept
 Return access to the ID. More...
 
const wordname () const noexcept
 Return const access to the name. More...
 
void write (Ostream &os) const
 Write. More...
 
void operator= (const base &gltf)
 

Additional Inherited Members

- Protected Attributes inherited from base
word name_
 Name. More...
 
label id_
 ID. More...
 

Detailed Description

glTF binary object

Note
Implements the glTF v2 specification
Source files

Definition at line 57 of file foamGltfObject.H.

Constructor & Destructor Documentation

◆ object() [1/2]

object ( )

Default construct.

Definition at line 33 of file foamGltfObject.C.

References Foam::abort(), Foam::FatalError, and FatalErrorInFunction.

Here is the call graph for this function:

◆ object() [2/2]

object ( const word name)
explicit

Construct with name.

Definition at line 47 of file foamGltfObject.C.

References Foam::abort(), Foam::FatalError, and FatalErrorInFunction.

Here is the call graph for this function:

Member Function Documentation

◆ addData() [1/2]

void addData ( const Type &  fld)

Add data to the buffer.

Definition at line 29 of file foamGltfObjectTemplates.C.

References Foam::component(), fld(), forAll, List< T >::resize(), and UList< T >::size().

Here is the call graph for this function:

◆ addData() [2/2]

void addData ( const Type1 &  fld1,
const Type2 &  fld2 
)

Add data to the buffer from 2 containers of the same size.

E.g. to combine vector and scalar to create RGBA data

Definition at line 47 of file foamGltfObjectTemplates.C.

References Foam::abort(), Foam::component(), Foam::FatalError, FatalErrorInFunction, and forAll.

Here is the call graph for this function:

◆ data()

const Foam::List< float > & data ( ) const
noexcept

Return const access to the data buffer.

Definition at line 63 of file foamGltfObject.C.


The documentation for this class was generated from the following files: