gstreamer-rs/gstreamer-audio/src
François Laignel fe319af598 Implement FormattedValue on any candidate type
The trait FormattedValue was only implemented on types which
could implement the full range of values for a Format. In order
to declare a function which could take both the intrinsic type
of any Format (e.g. `ClockTime`) as well the full range of values
(e.g. `Option<ClockTime>`), the argument was declared:

```rust
    impl Into<GenericFormattedValue>,
```

This commit implements `FormattedValue` for any type representing
a format. E.g.: both `ClockTime` and `Option<ClockTime>` will now
implement `FormattedValue`. The trait `FormattedValueFullRange`
is implemented on types which can be built from any raw value.

These changes are intended to help for the implementation of a
means to enforce format conformity at compilation time for
functions with multiple formatted value arguments.

The following signatures were found to be incorrect and are fixed:

- `message::StepDone`: forced the type for `amount` and `duration`
  to be of the same type, when `duration` is expected to be of the
  `Time` format.
- `query::Convert::set`: the two arguments were forced to the same
  type, so potentialy the same format, unless a
  `GenericFormattedValue` was used.

See https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1059
2022-07-11 19:45:52 +02:00
..
auto Regenerate 2022-06-30 08:46:06 +03:00
subclass Use IntoGlibPtr trait instead of implementing into_ptr 2022-05-07 13:38:11 +02:00
audio_aggregator.rs Update minimum supported version to 1.14 2022-04-07 12:45:47 +03:00
audio_aggregator_convert_pad.rs audio: Add audioaggregator bindings 2022-04-01 11:04:08 +03:00
audio_aggregator_pad.rs audio: Add audioaggregator bindings 2022-04-01 11:04:08 +03:00
audio_buffer.rs Handle empty slices correctly 2022-02-07 12:50:37 +02:00
audio_channel_position.rs Add missing doc aliases to manual code 2021-05-19 22:36:18 +02:00
audio_converter.rs Update minimum supported version to 1.14 2022-04-07 12:45:47 +03:00
audio_decoder.rs Use IntoGlibPtr trait instead of implementing into_ptr 2022-05-07 13:38:11 +02:00
audio_encoder.rs Use IntoGlibPtr trait instead of implementing into_ptr 2022-05-07 13:38:11 +02:00
audio_format.rs Implement more iterator functions / traits in custom iterators for efficiency reasons 2022-05-22 12:42:42 +03:00
audio_format_info.rs audio,video: Remove dox feature from function bodies 2021-06-04 11:51:01 +02:00
audio_info.rs Implement FormattedValue on any candidate type 2022-07-11 19:45:52 +02:00
audio_meta.rs Implement FormattedValue on any candidate type 2022-07-11 19:45:52 +02:00
audio_ring_buffer_spec.rs manual code: fix-getters-def doc aliases 2021-05-03 20:46:57 +02:00
audio_stream_align.rs Update minimum supported version to 1.14 2022-04-07 12:45:47 +03:00
flag_serde.rs Add De/Serialization for most bitflag types 2022-05-06 09:05:52 +00:00
functions.rs Use IntoGlibPtr trait instead of implementing into_ptr 2022-05-07 13:38:11 +02:00
lib.rs Store whether GStreamer was initialized in an AtomicBool 2022-06-27 10:28:28 +03:00
utils.rs audio: Add audioaggregator bindings 2022-04-01 11:04:08 +03:00