Commit graph

13 commits

Author SHA1 Message Date
Sebastian Dröge 33a6aab6d7 Run everything through latest rustfmt 2018-07-27 13:36:40 +03:00
Sebastian Dröge c0422acf66 Fix reference cycles and minor related problems in all examples and tutorials
These are now all leak-free.
2018-07-27 13:07:24 +03:00
Mathieu Duponchelle ab0df6ddf0 examples: use Cargo.toml required-features
This lets us avoid #ifdef forests
2018-02-26 20:35:23 +02:00
fengalin 21c687f256 Examples: message handlers: invoke generic Message method from the concrete message
Generic methods for events, messages and queries can now be invoked from the concrete type.
2018-01-29 17:33:49 +02:00
Sebastian Dröge 9b6efb2339 Fix various clippy warnings 2017-12-20 21:46:58 +02:00
Sebastian Dröge c99928d030 Change FormatValue related API to be more convenient to use
FormatValue is now renamed to GenericFormattedValue and the API slightly
changed. In addition there is now a FormattedValue trait, and a
SpecificFormattedValue trait plus types for Bytes, Buffers and the
existing ClockTime.

This allows to create functions like
  Pad::query_duration<F: SpecificFormattedValue>() -> Option<F>
and doesn't require the caller to unwrap the generic value anymore,
which is completely unneeded in these cases.

In addition, Segment became FormattedSegment<T> with API to
upcast/downcast between the specific formatted values and the generic
formatted value. This greatly simplifies usage of Segments.
2017-12-09 19:45:18 +02:00
Sebastian Dröge f895f484cc Fix up tutorials and examples for Message::get_src() returning an Option now 2017-11-16 13:58:56 +02:00
Sebastian Dröge c39c0c7264 Implement ClockTime as ClockTime(Option<u64>)
And also implement a FormatValue type that holds a value together with
its format to make usage of the positions/durations/seek positions/etc
more convenient and safe.

Fixes https://github.com/sdroege/gstreamer-rs/issues/3
2017-11-11 11:57:29 +01:00
Sebastian Dröge 884c9790ef Fix compilation of GTK examples with latest gio 2017-10-01 16:32:33 +02:00
Sebastian Dröge d608cff9e9 Fix build with latest GApplication API changes 2017-09-26 10:41:03 +03:00
Sebastian Dröge b4cb81cd56 Run everything through latest rustfmt-nightly 2017-09-10 15:21:26 +03:00
Philippe Normand facaae6be9 examples: Quartz support for the gtkvideooverlay example
Fixes https://github.com/sdroege/gstreamer-rs/pull/31
2017-08-30 18:08:00 +03:00
Sebastian Dröge da1a0c31d8 Add video overlay example, using GTK and only support Unix/X11 for now 2017-08-29 15:44:33 +03:00