|
ADTF
|
#include <sample_codec.h>
Inherits adtf::mediadescription::osborn::adtf_ddl_access::cCodecFactoryLegacy.
Inherited by adtf::mediadescription::osborn::decoding_sample_reader< ReaderImplementation >, and adtf::mediadescription::osborn::encoding_sample_writer< WriterImplementation >.
Public Types | |
| typedef ddl::codec::FactoryElement< sample_codec_factory_access< const cSampleCodecFactory > > | tElement |
| typedef ddl::codec::ChildElements< sample_codec_factory_access< const cSampleCodecFactory > > | tElements |
Public Types inherited from adtf::mediadescription::osborn::adtf_ddl_access::cCodecFactoryLegacy | |
| typedef ddl::StructElement | DefinedStructElementType |
| type definition for the old access_element API. | |
Additional Inherited Members | |
Static Public Member Functions inherited from adtf::mediadescription::osborn::adtf_ddl_access::cCodecFactoryLegacy | |
| static const char * | GetStaticStructElementName (const ddl::StructElement *pElement) |
Factory class for ddl codecs for samples.
| typedef ddl::codec::FactoryElement<sample_codec_factory_access<const cSampleCodecFactory> > adtf::mediadescription::osborn::cSampleCodecFactory::tElement |
Iterator value element type for the factory to get element information.
| typedef ddl::codec::ChildElements<sample_codec_factory_access<const cSampleCodecFactory> > adtf::mediadescription::osborn::cSampleCodecFactory::tElements |
Iterator container to iterate all elements of the factory.
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | ) |
Empty constructor. This exists to enable uninitialized member variables of this type that are move-assigned later on.
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | const char * | strStructName, |
| const char * | strMediaDescription, | ||
| ddl::tDataRepresentation | eDefaultDataRepresentation = ddl::tDataRepresentation::Deserialized ) |
Constructor that take a DDL string for initialization.
| [in] | strStructName | The name of the struct for which codecs should be generated. |
| [in] | strMediaDescription | The DDL description. |
| [in] | eDefaultDataRepresentation | The representation used for the Make* factory methods without an parameter for the data representation. |
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | const ddl::dd::StructType & | oStruct, |
| const ddl::dd::DataDefinition & | oParentDD, | ||
| ddl::tDataRepresentation | eDefaultDataRepresentation = ddl::tDataRepresentation::Deserialized ) |
Constructor that uses an OO-DDL struct for initialization.
| [in] | oStruct | The struct definition. |
| [in] | oParentDD | The parent data definition for the struct definition, used to resolve referenced types. |
| [in] | eDefaultDataRepresentation | The representation used for the Make* factory methods without an parameter for the data representation. |
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | const std::pair< std::string, std::string > & | oMDDescription, |
| ddl::tDataRepresentation | eDefaultDataRepresentation = ddl::tDataRepresentation::Deserialized ) |
Construct a new c Sample Codec Factory.
| oMDDescription | String pair of "struct_name", "data_description". |
| eDefaultDataRepresentation | Default data representation if creting a codec without representation value |
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | const ddl::DDStructure & | oTypeDefinition, |
| ddl::tDataRepresentation | eDefaultDataRepresentation = ddl::tDataRepresentation::Deserialized ) |
Construct a new c Sample Codec Factory.
| oTypeDefinition | Data definition defined within a DDStructure. |
| eDefaultDataRepresentation | Default data representation if creting a codec without representation value |
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | const streaming::ant::IStreamType & | oStreamType | ) |
Construct a new c Sample Codec Factory.
| oStreamType | Streamtype with set properties "md_struct" and "md_description". |
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | const ucom::ant::iobject_ptr< const streaming::ant::IStreamType > & | pStreamType | ) |
Construct a new c Sample Codec Factory.
| pStreamType | Streamtype with set properties "md_struct" and "md_description". |
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | const cSampleCodecFactory & | ) |
Copy constructor
| adtf::mediadescription::osborn::cSampleCodecFactory::cSampleCodecFactory | ( | cSampleCodecFactory && | ) |
Move constructor
| tElement adtf::mediadescription::osborn::cSampleCodecFactory::GetChildElement | ( | const tCodecIndex & | oCodecIndex, |
| std::string_view | strElementPath ) |
Retrieves an element for the given name.
| [in] | oCodecIndex | The codec index of the parent element. |
| [in] | strElementPath | The full name of the element in point notation (i.e. "element1.child_element[4].element_value"). |
| throws | tResult if not found. |
| ddl::tDataRepresentation adtf::mediadescription::osborn::cSampleCodecFactory::GetDefaultDataRepresentation | ( | ) | const |
Returns the current default data representation whuke creating codec or decoder.
| tElement adtf::mediadescription::osborn::cSampleCodecFactory::GetElement | ( | const tCodecIndex & | oCodecIndex | ) | const |
| tElement adtf::mediadescription::osborn::cSampleCodecFactory::GetElement | ( | std::string_view | strElementFullName | ) | const |
Retrieves an element for the given name.
| [in] | strElementFullName | The full name of the element in point notation (i.e. "element1.child_element[4].element_value"). |
| throws | tResult if not found. |
| const std::string & adtf::mediadescription::osborn::cSampleCodecFactory::GetElementBaseName | ( | const tCodecIndex & | oCodecIndex | ) | const |
Retrieves the base name of the element within its structured element.
If the element is an array you get the elements base name respresentation : "element_name" for each array element. If the element is not an array you get the elements name respresentation is also the base name respresentation: "element_name" .
| [in] | oCodecIndex | The codec index of the element. |
| throws | tResult if not found. |
| size_t adtf::mediadescription::osborn::cSampleCodecFactory::GetElementChildCount | ( | const tCodecIndex & | oCodecIndex | ) | const |
Retrieves the amount of child elements for the given codec index.
| [in] | oCodecIndex | The codec index of the element. |
| 0 | has no children. May be a leaf element. |
| >0 | has children. May be a structured element. |
| throws | tResult if not found. |
| std::string adtf::mediadescription::osborn::cSampleCodecFactory::GetElementFullName | ( | const tCodecIndex & | oCodecIndex | ) | const |
Retrieves the full name of the element within its main structure.
If the element is an array you get the elements array name respresentation: "main_element.element_name[0]" or main_element.element_name[1] ... etc. If the element is not an array you get the elements name respresentation: "main_element.element_name".
| [in] | oCodecIndex | The codec index of the element. |
| throws | tResult if not found. |
| std::string adtf::mediadescription::osborn::cSampleCodecFactory::GetElementName | ( | const tCodecIndex & | oCodecIndex | ) | const |
Retrieves the name of the element within its structured element.
If the element is an array you get the elements array name respresentation: "element_name[0]" or element_name[1] ... etc. If the element is not an array you get the elements name respresentation: "element_name".
| [in] | oCodecIndex | The codec index of the element. |
| throws | tResult if not found. |
| const tElements & adtf::mediadescription::osborn::cSampleCodecFactory::GetElements | ( | ) | const |
Retrieves the elements of the factory to get element information.
| size_t adtf::mediadescription::osborn::cSampleCodecFactory::GetStaticBufferSize | ( | ddl::tDataRepresentation | eRep = ddl::tDataRepresentation::Deserialized | ) | const |
Gets the static buffer size in bytes for the structure.
| eRep | option to retrieve size in bytes for the deserialized or serialized representation. |
| size_t | size in bytes of the structure depending on the given representation eRep |
| tResult adtf::mediadescription::osborn::cSampleCodecFactory::IsValid | ( | ) | const |
Check if the factory is in a valid state.
|
inline |
Creates a codec for the given sample using the default data representation.
| [in] | oSample | The sample. |
| cSampleCodec adtf::mediadescription::osborn::cSampleCodecFactory::MakeCodecFor | ( | adtf::streaming::ISample & | oSample, |
| ddl::tDataRepresentation | eDataRepresentation ) const |
Creates a codec for the given sample.
| [out] | oSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
|
inline |
Creates a codec for the given sample using the default data representation.
| [in] | pSample | The sample. |
|
inline |
Creates a codec for the given sample.
| [out] | pSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
|
inline |
Creates a decoder for the given sample using the default data representation.
| [in] | oSample | The sample. |
| cSampleDecoder adtf::mediadescription::osborn::cSampleCodecFactory::MakeDecoderFor | ( | const adtf::streaming::ISample & | oSample, |
| ddl::tDataRepresentation | eDataRepresentation ) const |
Creates a decoder for the given sample.
| [in] | oSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
|
inline |
Creates a decoder for the given sample using the default data representation.
| [in] | pSample | The sample. |
|
inline |
Creates a decoder for the given sample.
| [in] | pSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
|
inline |
Creates a static codec for the given sample using the default data representation.
| [in] | oSample | The sample. |
| cStaticSampleCodec adtf::mediadescription::osborn::cSampleCodecFactory::MakeStaticCodecFor | ( | adtf::streaming::ISample & | oSample, |
| ddl::tDataRepresentation | eDataRepresentation ) const |
Creates a static codec for the given sample.
| [out] | oSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
|
inline |
Creates a static codec for the given sample using the default data representation.
| [in] | pSample | The sample. |
|
inline |
Creates a static codec for the given sample.
| [out] | pSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
|
inline |
Creates a static decoder for the given sample using the default data representation.
| [in] | oSample | The sample. |
| cStaticSampleDecoder adtf::mediadescription::osborn::cSampleCodecFactory::MakeStaticDecoderFor | ( | const adtf::streaming::ISample & | oSample, |
| ddl::tDataRepresentation | eDataRepresentation ) const |
Creates a static decoder for the given sample.
| [in] | oSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
|
inline |
Creates a static decoder for the given sample using the default data representation.
| [in] | pSample | The sample. |
|
inline |
Creates a static decoder for the given sample.
| [in] | pSample | The sample. |
| [in] | eDataRepresentation | The data representation that the sample is in. |
| cSampleCodecFactory & adtf::mediadescription::osborn::cSampleCodecFactory::operator= | ( | const cSampleCodecFactory & | ) |
assignment operator
| cSampleCodecFactory & adtf::mediadescription::osborn::cSampleCodecFactory::operator= | ( | cSampleCodecFactory && | ) |
Move assignment operator
| void adtf::mediadescription::osborn::cSampleCodecFactory::Resolve | ( | tCodecIndex & | oCodecIndex | ) | const |
retrieves the lyoutinformation for the given codec index.
| [in] | oCodecIndex | The codec index of the element to retrieve. |
| tCodecIndex adtf::mediadescription::osborn::adtf_ddl_access::cCodecFactoryLegacy::Resolve | ( | tCodecLeafIndex | nElementLeafIndex | ) | const |
Legacy: Retrieves a codec index with element information for the given leaf index.
| nElementLeafIndex | The leaf index (between 0 and GetElementCount()) |
| throws | tResult if not found. |