9 #ifdef USE_ADTF_MEDIA_DESCRIPTION_LEGACY
10 #ifndef NO_ADTF_MEDIA_DESCRIPTION_LEGACY
15 #include <adtfbase/adtf_base_type_traits.h>
25 namespace mediadescription
32 template<
typename,
typename =
void>
33 constexpr
bool is_defined_v =
false;
36 constexpr
bool is_defined_v<T, std::void_t<decltype(
sizeof(T))>> =
true;
55 constexpr
bool has_description_v = detail::is_defined_v<description<T>>;
81 static_assert(base::penguin::detail::always_false<T>,
82 "There is no md_sample_data specialization available for this type."
83 " Please make sure that you generate and include the corresponding header file.");
95 template <
typename T,
typename UnderlyingType = T>
100 std::shared_ptr<adtf::mediadescription::osborn::cSampleDecoder> pDecoder):
101 m_pIndices(aIndices),
106 T operator[](
size_t nIndex)
const
108 return static_cast<T
>(m_pDecoder->template GetElementValue<UnderlyingType>(m_pIndices[nIndex]));
113 std::shared_ptr<adtf::mediadescription::osborn::cSampleDecoder> m_pDecoder;
124 template <
typename T>
129 std::shared_ptr<adtf::mediadescription::osborn::cSampleDecoder> decoder):
130 m_pIndices(aIndices),
142 std::shared_ptr<adtf::mediadescription::osborn::cSampleDecoder> m_pDecoder;
148 template <
typename T>
154 pIndices(std::move(pIndices))
157 std::shared_ptr<indices<T>> pIndices;
173 template <
typename T>
177 static_assert(has_description_v<T>,
178 "md_sample_data_factory<T>() can only be used if ddl description was generated with adtf_mdgen!");
211 m_oFactory(oStreamType),
212 m_pIndices(std::make_shared<
indices<T>>())
215 m_pIndices->Find(m_oFactory,
"");
225 m_oFactory(strStructName, strDefinition),
226 m_pIndices(std::make_shared<
indices<T>>())
229 m_pIndices->Find(m_oFactory,
"");
246 std::shared_ptr<indices<T>> m_pIndices;
251 using osborn::md_sample_data_factory;
252 using osborn::md_sample_data;
253 using osborn::description;
254 using osborn::has_description_v;
255 using osborn::md_array;
256 using osborn::md_struct_array;
Copyright © Audi Electronics Venture GmbH.
Defines access methods for the interface of a Stream Type - see also Stream Type and Stream Meta Type...
Base object pointer to realize binary compatible reference counting in interface methods.
Fast Access Index Type for the coders.
Copyright © Audi Electronics Venture GmbH.
Namespace for entire ADTF SDK.
Copyright © Audi Electronics Venture GmbH.
#define THROW_IF_FAILED(s)
throws if the expression returns a failed tResult