class
#include <selection.hpp>
v_1_0_0::DescriptorPreference Interface for a descriptor preference.
A preference is a numerically expressed likeliness that a descriptor should be selected for the given pair of Format and Codec.
The actual type
of a preference value is an unsigned integer type. The minimal possible preference is expressed by MIN_PREFERENCE which can be taken for 'no actual preference'. The maximal possible preference is MAX_PREFERENCE.
Derived classes
- class v_1_0_0::DefaultPreference final
- Preference for the most specific descriptor.
- class v_1_0_0::FormatPreference final
- Preference for the most specific descriptor accepting the Format.
- class v_1_0_0::MinPreference final
- DescriptorPreference equivalent to MIN_PREFERENCE.
Public types
- using type = unsigned int
- An unsigned integer type to express the actual preference value.
Public static variables
- static type MAX_PREFERENCE constexpr
- Maximal preference value.
- static type MIN_PREFERENCE constexpr
- Minimal preference value.
Constructors, destructors, conversion operators
- ~DescriptorPreference() virtual noexcept
- Virtual default destructor.
Public functions
- auto preference(const Format format, const Codec codec, const FileReaderDescriptor& desc) const -> type
- Get a preference of one descriptor for a specified pair of Format and Codec.
Function documentation
type arcsdec:: v_1_0_0:: DescriptorPreference:: preference(const Format format,
const Codec codec,
const FileReaderDescriptor& desc) const
Get a preference of one descriptor for a specified pair of Format and Codec.
Parameters | |
---|---|
format in | File format |
codec in | Audio codec |
desc in | The descriptor to check |
Returns | Preference value to read format and codec with this descriptor |