Commit graph

214 commits

Author SHA1 Message Date
Olivier Crête
0a24137100 basertpaudiopayload: Add extra frame for non-complete frame lengths
Some payloaders like rtpg729pay can add a shorter frame at the end of a
RTP packet. We need to count it like a full frame for timestamps.

https://bugzilla.gnome.org/show_bug.cgi?id=618324
2010-05-13 11:03:12 +02:00
Olivier Crête
8a2b81a576 basertpaudiopayload: Set duration on buffers
Set the duration of the buffers from their size
2010-05-13 10:54:08 +02:00
Mark Nauwelaerts
ed71d802fc basertpdepayload: ensure writable metadata 2010-04-30 19:38:40 +02:00
Olivier Crête
66cc2faba7 audiopayload: use ptime-multiple
Based on patch by Olivier Crête <olivier.crete@collabora.co.uk>

Fixes #613248
2010-04-09 16:17:31 +02:00
Wim Taymans
1fa171d396 audiopayload: add property to control packet duration
Add a property to specify that the amount of data in a packet should be a
multiple of ptime-multiple.

See #613248
2010-04-09 16:17:31 +02:00
Vincent Untz
764c899215 libs: point gobject-introspection scanner to .la files
Point g-ir-scanner to the .la file of our library, which hopefully
makes it find the right dependencies in all cases (ie. our locally
built libgstreamer and not the system-installed one). This is also
how it's done in Gtk+ and how it's documented in the wiki, see
http://live.gnome.org/GObjectIntrospection/AutotoolsIntegration

Fixes #603710.
2010-04-03 14:03:45 +01:00
Tim-Philipp Müller
b37c993e4e gst-libs: more gobject-introspection fixes
Use right .pc file variable for compiler includes this time:
g-ir-compiler wants the girdirs not the typelibdirs as includes.
2010-03-30 23:46:10 +01:00
Tim-Philipp Müller
64cfa6bf73 gst-libs: fix up gobject-introspection some more
Use new girdir and typlibdir from core .pc files, so we can figure
out the right includes to pass to the gobject-introspection tools,
whether core is installed in the same prefix as gobject-introspection
or in a different prefix or uninstalled. This also keeps us from adding
bogus paths to the includes that only work if core is uninstalled.

Also add some missing includes/pkgs where needed.
2010-03-30 19:56:56 +01:00
Benjamin Otte
90f24667d7 Constify some strings in the API
Needed by plugins-good
2010-03-19 22:34:36 +01:00
Tim-Philipp Müller
e836151009 docs: more helper libraries docs fixes
Quieten gtk-doc a bit more.
2010-03-16 00:44:50 +00:00
Sebastian Dröge
d5a4ca9962 build: Make some more rules silent if requested 2010-03-09 21:01:38 +00:00
Wim Taymans
92a474b18c basedepay: clarify some documentation 2010-03-08 12:11:01 +01:00
Olivier Crête
6c6d0e32cf basertppayload: ptime/maxptime should be unsigned
https://bugzilla.gnome.org/show_bug.cgi?id=607403
2010-01-21 10:46:31 +01:00
Olivier Crête
8d2ac0b2ec basertppayload: ptime should be in nanoseconds
https://bugzilla.gnome.org/show_bug.cgi?id=607403
2010-01-21 10:46:17 +01:00
Olivier Crête
ad399c8069 basertppayload: Reject empty caps
https://bugzilla.gnome.org/show_bug.cgi?id=607353
2010-01-19 13:29:19 +01:00
Wim Taymans
73d5ae1107 audiopayload: add support for buffer-lists 2010-01-06 13:39:14 +01:00
Olivier Crête
bc6179952b basertpaudiopayload: Respect ptime if it is given
If the ptime is given in the caps, respect it and force the minimum
and maximum sizes to be exactly the requested ptime.

https://bugzilla.gnome.org/show_bug.cgi?id=606050
2010-01-05 13:20:49 -05:00
Olivier Crête
a4b0f2a1bd rtpbasepayload: Store ptime from caps
https://bugzilla.gnome.org/show_bug.cgi?id=606050
2010-01-05 13:20:49 -05:00
Olivier Crête
21151ba940 basertppayload: Accept maxptime from caps
https://bugzilla.gnome.org/show_bug.cgi?id=606050
2010-01-05 13:20:49 -05:00
Wim Taymans
f7070b6bc6 rtcpbuffer: add helper functions for SDES types
Add functions to convert SDES names to their types and back. Will be used later
to set SDES items using a GstStructure.

See #595265
2009-12-22 20:15:28 +01:00
Stefan Kost
f3db4e01b5 rtp: dump packets which we reject 2009-10-28 11:30:58 +02:00
Tim-Philipp Müller
6f4c1ac583 Remove GST_DEBUG_FUNCPTR where they're pointless
There's not much point in using GST_DEBUG_FUNCPTR with GObject
virtual functions such as get_property, set_propery, finalize and
dispose, since they'll never be used by anyone anyway. Saves a
few bytes and possibly a sixteenth of a polar bear.
2009-10-28 00:59:35 +00:00
Olivier Crête
e27c24b200 rtpaudiopayload: Only sent exact multiple of the frame size
Also align the maximum size with the frame size, not only the minimum
2009-10-23 13:56:05 +03:00
Wim Taymans
a87811f49a basertppayload: small comment fix 2009-10-16 10:59:39 +02:00
Peter Kjellerstedt
7bca2a0019 rtp: Correct timestamping of buffers when buffer_lists are used
The timestamping of buffers when buffer_lists are used failed if
a buffer did not have both a timestamp and an offset.
2009-10-16 10:51:22 +02:00
Sebastian Dröge
df9b8b57b3 introspection: Build pkgconfig before all libraries and set PKG_CONFIG_PATH
This way g-ir-scanner can find the gstreamer-*-0.10 pkg-config files.
2009-09-13 11:19:50 +02:00
Wim Taymans
e2e7ae0129 basertppay: don't print RTP timestamps as clocktime
Don't try to print the RTP timestamp as a GstClockTime, it's just a guint32.

Fixes #594757
2009-09-10 18:21:08 +02:00
Havard Graff
f710bec408 basertpdepayload: fix event forwarding 2009-09-08 15:10:59 +02:00
Havard Graff
f0f72088bc rtcpbuffer: add missing break in handling of GST_RTCP_TYPE_PSFB
Fixes #594258
2009-09-08 13:03:21 +02:00
Sebastian Dröge
7e90e0846c introspection: Strip Gst prefix from all types/functions 2009-09-05 12:31:47 +02:00
Sebastian Dröge
7794caf9f8 introspection: Fix build if gir-repository is not installed 2009-09-05 11:49:41 +02:00
Sebastian Dröge
8001b380b1 rtp: Add gobject-introspection support 2009-09-05 11:25:42 +02:00
Wim Taymans
7a7663476f audiortppay: add some debugging 2009-09-03 18:53:19 +02:00
Wim Taymans
c1db9ebb20 audiortppay: handle gaps
Add various conversion functions between time<->bytes<->rtptime that will be
used later on.
Refactor the min/max packet length code so that it can be used for both
sample/frame based payloaders. Cache the returned values.
code cleanups.
When we discover a DISCONT buffer, make the outgoing RTP timestamps have the
same gap as the GStreamer timestamps gap.
2009-09-03 17:59:00 +02:00
Wim Taymans
3a3c6f309c audiortppay: fix frame duration calculations
Fix the calculation of the frame duration and rtp timestamps.
Add some debugging
2009-09-03 17:59:00 +02:00
Wim Taymans
bfc19462bb rtppay: add some debugging 2009-09-03 17:59:00 +02:00
Wim Taymans
bb91a7b47c audiortppay: use offsets for RTP timestamps
Have a custom sample/frame function to generate an offset that the base class
will use for generating RTP timestamps. This results in perfect RTP timestamps
on the output buffers.
Refactor setting metadata on output buffers.
Add some more functionality to _flush().
Handle DISCONT on the input buffers and set the marker bit and DISCONT flag on
the next outgoing buffer.
Flush the pending data on EOS.
2009-09-03 17:58:59 +02:00
Wim Taymans
c1ae0a2003 audiortppay: move function around 2009-09-03 17:58:59 +02:00
Wim Taymans
5808041f44 audiortppay: fix sample duration calculation 2009-09-03 17:58:59 +02:00
Wim Taymans
299ab7be0e audiortppay: more refactoring
Unify the sample/frame buffer handling code by making the functions plugable.
2009-09-03 17:58:59 +02:00
Wim Taymans
fb5037f727 audiortppayload: refactor some more
Refactor getting the packet min/max size and alignment code.
Refactor converting bytes to time.
change some variable to something shorter.
2009-09-03 17:58:59 +02:00
Wim Taymans
1c6b71af03 audiortppayload: refactor and cleanup
Always use the adapter when we need to fragment the incomming buffer. Use more
modern adapter functions to avoid malloc and memcpy. The overall result is that
the code looks cleaner while it should be equally fast and in some case avoid a
memcpy and malloc.
Use the adapter timestamping functions for more precise timestamps in case of
weird disconts.
Cache some values instead of recalculating them.
Add gst_base_rtp_audio_payload_flush() to flush a certain amount of bytes from
the internal adapter.

API: GstBaseRTPAudioPayload::gst_base_rtp_audio_payload_flush()
2009-09-03 17:58:59 +02:00
Wim Taymans
50b9640d01 basertppay: add property to disable perfect RTP time
Add a property to disable the generation of perfect RTP timestamps. By default
it is active.

API: GstBaseRTPPayload::perfect-rtptime
2009-09-03 11:29:23 +02:00
Wim Taymans
3a4edea56d basertppay: allow subclasses to influence RTP time
Allow subclasses to use the OFFSET field on RTP buffers to influence the way in
which RTP timestamps are generated. Usually timestamps are created from the
GStreamer timestamps on the buffer, which could result in imperfect RTP
timestamps.
2009-09-03 11:15:20 +02:00
Wim Taymans
5a479669d4 basertppay: add macro to cast 2009-09-03 11:15:20 +02:00
Wim Taymans
bc3c8a1564 audiopayload: code cleanups 2009-09-03 11:15:20 +02:00
Wim Taymans
3c29efa692 audiortppayload: don't check adapter
the adapter is never NULL so we don't need to check it.
Use _scale functions to avoid overflows.
2009-09-03 11:15:20 +02:00
Jonas Holmberg
ec91d508af basertppayload: Make instance init faster by not reading /dev/urandom 3 times
... which is the default seed when creating a new GRand. Because
GLib in older versions used buffered IO this would take a lot of time.

Instead use the global GRand for getting random numbers and keep the
three instance GRand for backward compatibility with a simple seed.

Fixes bug #593284.
2009-09-01 10:39:52 +02:00
Wim Taymans
e40b262ab7 basertppayload: whitespace fixes. 2009-08-28 14:09:02 +02:00
Edward Hervey
9329b8be72 gst-libs: Remove dead assignments and resulting unused variables. 2009-08-08 15:54:57 +02:00