Sebastian Dröge
4096869075
Update byte-slice-cast to 0.3
2019-05-24 13:26:49 +02:00
Sebastian Dröge
6cef32a4dd
Change various mini object references to references to the refcounted object
...
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/issues/204
2019-05-24 10:04:16 +00:00
Sebastian Dröge
a986914bad
Use Option<&T> instead of &Option<T> everywhere
...
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/issues/203
2019-05-22 23:27:13 +03:00
Sebastian Dröge
8618085d46
Port examples/tutorials to the explicit Option parameter changes
2019-04-15 19:19:19 +03:00
Sebastian Dröge
86a31b4139
Silence/fix various clippy warnings
2019-03-07 14:05:35 +02:00
Sebastian Dröge
8c39da4e5b
Update to Rust 1.31 linter-specific attributes
2019-03-04 15:16:01 +02:00
Víctor Manuel Jáquez Leal
066b22efc5
Fix examples and tutorial with GTK API updates
2019-02-28 12:02:51 +01:00
Sebastian Dröge
32e961d418
Update versions to 0.14.0
2019-02-22 13:04:56 +02:00
Sebastian Dröge
95f6844702
Fix various minor clippy warnings
2019-02-21 19:56:23 +02:00
Sebastian Dröge
b4ad105c1d
basic-tutorial-5: Stop using deprecated GTK API
...
Disabling double buffering is deprecated since quite a while.
2019-02-07 10:26:37 +02:00
Sebastian Dröge
de978bd115
Update gtk feature flags
...
The minimum supported version of GTK is now 3.14 so we don't have to
opt-in for 3.8/3.10 APIs anymore.
2019-02-07 09:49:07 +02:00
François Laignel
333d71f92b
Update functions returning bool to use Result<(), glib::BoolError>
...
See https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/issues/171
2019-01-17 23:13:44 +01:00
Sebastian Dröge
931c485150
Update manual code for glib API changes
2019-01-16 13:52:56 +02:00
François Laignel
948fb2ae4b
Replace XXXReturn with Result<XXXSuccess, XXXError>
...
... in function signatures.
These breaking changes aim at improving usability by allowing users
to take advantage of Rust error management features sur as `ok_or`,
`map_err`, `expect` and the `?` operator. See the `examples` and
`tutorials` to get an idea of the impacts.
2019-01-11 18:33:04 +01:00
Philippe Normand
bef6d741d3
Fix examples and tutorials for GString support
2019-01-03 22:01:41 +00:00
Sebastian Dröge
69af6a5975
bus: Add iter() and iter_timed() that return Iterators around the corresponding pop() functions
...
And make use of them in the examples where it makes sense.
2018-12-28 00:06:03 +02:00
Sebastian Dröge
e804ef4d76
Switch to Rust 1.31 as minimum supported version
...
Too many dependencies switched and we can't really keep everything at an
older version.
Commented out for now until stable becomes 1.32.
2018-12-19 12:45:57 +02:00
Jordan Petridis
02dc888a3a
Examples: Pin some dependencies to builda with rustc 1.28
...
These dependencies require rustc 1.31, which we can't yet use.
Since they are only affecting examples its not a big deal to pin
them to an earlier version.
2018-12-17 14:52:45 +02:00
Sebastian Dröge
890b47eef9
Fix up some error handling in basic-tutorial-12
...
And minor code cleanup
2018-12-04 11:14:03 +02:00
Tony Jinwoo Ahn
b9fa4870ad
Add basic-tutorial-12
...
Add basic-tutorial-12 from the GStreamer tutorials
2018-12-04 08:52:10 +00:00
Sebastian Dröge
8c9d1abe9d
Remove GitLab badge
...
It only works for gitlab.com currently
2018-11-26 16:16:26 +01:00
Sebastian Dröge
352f1c80d4
Run everything through rustfmt
2018-11-03 20:28:58 +02:00
Sebastian Dröge
f4a6aa4481
Change all references from GitHub to freedesktop.org GitLab
2018-11-03 20:08:42 +02:00
Charlie Turner
98c69609cc
Cturner/add tutorial 9 ( #142 )
...
Add basic-tutorial 9
2018-10-31 23:43:04 +02:00
Sebastian Dröge
eb0a804a50
Run everything through latest rustfmt
2018-10-08 15:02:23 +03:00
Sebastian Dröge
2c7dff3b45
Run everything through rustfmt again
2018-10-08 09:32:08 +03:00
Sebastian Dröge
33a6aab6d7
Run everything through latest rustfmt
2018-07-27 13:36:40 +03:00
Sebastian Dröge
8f9c0a72e0
Get rid of all usage of send-cell
2018-07-27 13:25:47 +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
Sebastian Dröge
694bcaa697
Fix all clippy warnings
...
Or silence the ones we don't care about.
2018-07-20 10:28:20 +03:00
Sebastian Dröge
8d0a0ee6b1
Directly use byte-slice-cast on the mapped buffer
...
No need to first get a byte slice from it anymore due to the buffer map
implementing AsRef/AsMut for byte slices
2018-06-01 11:55:13 +03:00
Sebastian Dröge
8ff9294f9d
Update to byte-slice-cast 0.2.0
2018-06-01 11:52:56 +03:00
Sebastian Dröge
2cefd9aea6
Re-run everything through rustfmt
2018-04-25 11:13:14 +03:00
Sebastian Dröge
492c3d656c
Run everything through rustfmt again
2018-04-01 11:57:58 +03:00
Sebastian Dröge
6d5f7337fc
Update version to 0.12.0
2018-03-20 12:37:24 +02:00
Sebastian Dröge
4117c01ff2
Run everything through latest rustfmt-nightly
2018-02-22 11:18:37 +01:00
François Laignel
c971727193
Query: allow concrete query instantiation
...
Allow instantiating and dereferencing concrete queries. The motivation
for this proposal is to allow the following usability enhancements:
- Concrete queries mutability guaranteed by the borrow checker,
including for generic functions:
``` rust
let mut p = Query::new_position(::Format::Time);
p.get_mut_structure().set("check_mut", &true);
```
- Concrete queries functions available in place:
``` rust
let mut q = gst::Query::new_duration(gst::Format::Time);
let duration = if pipeline.query(&mut q) {
Some(q.get_result())
} else {
None
};
```
2018-02-16 10:33:40 +02:00
fengalin
ce28fed070
Tutorials: 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
4a5987d03d
Update versions to 0.11.0
2017-12-22 15:06:06 +02:00
Sebastian Dröge
9b6efb2339
Fix various clippy warnings
2017-12-20 21:46:58 +02:00
Sebastian Dröge
e0dc84c10a
Run everything through rustfmt again
2017-12-20 19:30:14 +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
d7792a4fca
Fix calculation for buffer duration in basic-tutorial-8
...
We need to scale the number of samples, not the buffer size.
2017-12-09 14:03:18 +02:00
Sebastian Dröge
77d439338b
Fix build after Event/Message::get_structure() API change
2017-12-01 17:31:47 +02:00
Sebastian Dröge
b6d13272df
Fix some clippy warnings in examples/tutorials
2017-11-27 14:03:33 +02:00
Sebastian Dröge
f1e095eb0e
Update versions to 0.10.0
2017-11-26 18:33:12 +02:00
Sebastian Dröge
8014b387c4
Don't list versions for the glib/gtk/gio GIT repositories
2017-11-26 18:32:14 +02:00
Sebastian Dröge
483b40679a
Flush stdout after writing every * in basic-tutorial-8
2017-11-17 20:43:13 +02:00
Guillaume Desmottes
82681d2b24
Add basic-tutorial-8
...
Fixes https://github.com/sdroege/gstreamer-rs/pull/52
2017-11-17 20:43:08 +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