Commit graph

4237 commits

Author SHA1 Message Date
Mark Nauwelaerts
e12044c359 h264parse: avoid additional NAL parsing if no AU collection is needed 2011-11-18 17:20:03 +01:00
Mark Nauwelaerts
9db239e1ec h264parse: some more get_caps tweaking
... by having it use sink template rather than src template, and not
passing an downstream parsed(=true) to upstream.
2011-11-18 17:20:00 +01:00
Sebastian Dröge
d746cd7d67 mpeg4videoparse: Change rank to PRIMARY+1 2011-11-16 10:57:55 -08:00
Sebastian Dröge
ec089662de mpeg4videoparse: Don't require parsed=false on the sinkpad caps 2011-11-16 10:57:24 -08:00
Sebastian Dröge
f3f9e4b978 h264parse: Implement ::sink_get_caps to allow stream-format conversion again
Just proxying the downstream caps will prevent h264parse from
accepting a different stream-format than what is supported
downstream, although it could convert to a different stream-format.
2011-11-16 10:39:40 -08:00
Edward Hervey
e500ec524c tsdemux: Add notes on synchronization and scheduling 2011-11-16 12:47:58 +01:00
Jonas Larsson
5099ff23af h264parse: outgoing byte stream prefix always has size 4
Fixes #664123.
2011-11-16 10:57:30 +01:00
David King
92f07e3898 camerabin: Document requirement for PLAYING state
As described in GNOME bug 663998, the element must be in the PLAYING
state before calling capture-start.

https://bugzilla.gnome.org/show_bug.cgi?id=664048
2011-11-14 23:28:29 -03:00
Thiago Santos
1d5b324e7d camerabin2: Also reset audio elements when video capture finishes
Audio elements also need to be reset after each capture, do it
together with the video elements' reset
2011-11-14 17:48:52 -03:00
Thiago Santos
aab3a73ccd camerabin2: Add one debug line about camerabin2 being idle 2011-11-14 13:06:29 -03:00
Thiago Santos
54351a0129 camerabin2: Remove video elements' state clearing from start-capture
Reduce start-capture workload by moving the elements' state reseting to the
finishing steps of the capture. This reduces the time start-capture takes to
actually start a capture and return to its caller, improving user experience.

As the elements' state reset is now triggered from the message handling
function, it needs to spawn a new thread, changing state from the pad's
task would cause a deadlock.
2011-11-14 13:06:29 -03:00
Thiago Santos
c635e4bc3b camerabin2: keep track of video recording state
Adds a new variable to keep track of the state of the video
recording in camerabin2. This allows start-capture to reject
new video recording requests when one is already ongoing. This
fixes one of check tests.
2011-11-14 13:06:28 -03:00
Matej Knopp
a08b3bfa23 mpegvideoparse: add support for progressive frames
https://bugzilla.gnome.org/show_bug.cgi?id=663782
2011-11-10 19:58:13 -03:00
Thiago Santos
c7db5db632 camerabin2: protect image location list with mutex
Rename the image taglists' mutex into image capture mutex and
use it also for the image capture list to prevent concurrent
access from different threads (application and capture threads).
2011-11-09 12:30:58 -03:00
Thiago Santos
27e01e02a4 camerabin2: Handle null taglists for images
Add NULL and check for them to the image capture taglist list, representing
that a capture has no application tags set.
2011-11-09 12:30:58 -03:00
Thiago Santos
9ab6406f23 camerabin2: Don't store preview location if preview isn't requested
Do not store preview location is post-previews is false, this would
mess up preview naming in case application switches between enabling
and disabling previews
2011-11-09 12:30:33 -03:00
Lasse Laukkanen
5ca3c9477e camerabin2: Avoid blocking in start-capture and send application tags later
Tags are currently sent from start-capture, which is run in the
application thread. For images we can delay the tags pushing to the
buffer probe and push the tags with the location event and reduce
start-capture time.
2011-11-09 11:45:55 -03:00
Thijs Vermeir
8529526c54 dtmf: fix compiler warning for uninitialized values 2011-11-09 11:56:07 +01:00
Olivier Crête
d937da4c0c dtmfsrc: Reject start/stop requests that come out of order 2011-11-08 17:45:48 -05:00
Olivier Crête
d15d524fec dtmf: Post messages when starting to send/receive DTMF
This way, the UI can display the DTMF events as they as being sent.
2011-11-08 17:45:48 -05:00
Thiago Santos
74df06d8c6 camerabin2: Decrement processing counter when message handling finishes
Some messages might be interesting to applications, so we can only
decrement the processing counter and send the idle notification
when those messages are posted on the pipline's bus
2011-11-08 08:13:20 -03:00
Lasse Laukkanen
ad1ddaf53a camerabin2: change post-previews property default value as false
Generating and posting preview image always comes with a performance
penalty so set default value as false. The preview-caps property that
defines the preview image format is also NULL by default, so instead
of generating preview image of unspecified format by default explicit
action from application should be required for enabling preview image
posting feature.

Application also has to add custom code to be able
to handle preview messages on its message handling function anyway.
2011-11-08 07:09:41 -03:00
Vincent Penquerc'h
d0443cfb65 colorspace: fix r210 writing only half a scanline
https://bugzilla.gnome.org/show_bug.cgi?id=663203
2011-11-07 17:15:14 +00:00
Vincent Penquerc'h
0ff703b520 adpcm: add more consts, espcially for static const data 2011-11-07 16:41:42 +00:00
Vincent Penquerc'h
9674c5aefa autoconvert: merge caps instead of using union
It's a lot faster, and preserves caps ordering.

https://bugzilla.gnome.org/show_bug.cgi?id=663346
2011-11-07 12:16:37 +00:00
Vincent Penquerc'h
4275a70cb5 mpegdemux: catch section lengths extending past the buffer length
This is probably the cause for an occasional crash while streaming
MPEG. Blind fix after staring at the code and following logic, so
may or may not fix the issue, I cannot test.
2011-11-07 11:59:12 +00:00
Vincent Penquerc'h
b3d751667d mpegpsdemux: fix zero length packet handling
https://bugzilla.gnome.org/show_bug.cgi?id=631416
2011-11-07 11:17:00 +00:00
Reynaldo H. Verdejo Pinochet
506f97a975 Fix missing sources on bayer's buildsystem androgenizer call 2011-11-04 18:06:51 -03:00
Thiago Santos
d4105d4b56 camerabin2: On capture error, skip previews
When the camera source fails to do some capture, skip the next
preview and decrement processing counter.
2011-11-01 11:49:17 -03:00
Lasse Laukkanen
37aa6a9c71 camerabin2: track also preview images with processing counter
Makes camerabin2 only signal that it is idle after all previews have
been generated, images are captured and saved, and videos have
been finished properly.
2011-11-01 11:49:17 -03:00
Robert Swain
e3b7cb8899 fieldanalysis: Don't reset the context on DISCONT
On discont, the queue of frames was being cleared, but also the
context reset. We only need to clear the queue.
2011-10-31 18:20:32 +01:00
Tim-Philipp Müller
4060056ce6 assrender, nuvdemux: unref buffers with gst_buffer_unref() 2011-10-18 14:41:48 +01:00
Sreerenj Balachandran
f8239ff692 h264parse: correct debug message and remove some dead code
See #661113.
2011-10-17 11:17:50 +02:00
Sreerenj Balachandran
0a478db7dd h264parse: correct parsing of "numberOfPictureParameterSets"
See #661113.
2011-10-17 11:17:47 +02:00
Thiago Santos
61a7e6bf38 camerabin2: Check before acessing preview location list
Only access the preview location if it exists, to avoid acessing
a NULL variable. If the preview location list doesn't exist, it is
likely because the source has posted a preview message after camerabin2
has been put to READY.
2011-10-12 12:19:13 -03:00
Thiago Santos
e90e041e52 camerabin2: Add a mutex to avoid concurrent access of preview filename lists
The preview filename list is acessed whenever a new capture is started, when
camera-source posts a new preview message or on state changes. All of those can
occur simultaneously, so add a mutex to prevent concurrent access.
2011-10-11 23:13:00 -03:00
Thiago Santos
17a00123a4 camerabin: Reset audiosrc timestamping
Reset audiosrc's timestamping data by setting
it to NULL to reset the ringbuffer and then re-seting
the clock that camerabin might not redistribute
2011-10-11 18:48:07 -03:00
Thiago Santos
0f99118141 camerabin: Prevent audio source from providing clock
camerabin's audio source might be put to NULL during its
use, so the clock would be lost. Better not allow it to
provide a clock at all.
2011-10-11 16:27:07 -03:00
Thibault Saunier
f94236078c h264parse: Make proper use of the h264parser lib in parse_chain
Minor debugging logs fixes
2011-10-06 12:49:19 -03:00
Mark Nauwelaerts
9c221f492d h264parse: properly interpret baseparse draining state
... which means the input data has reached the end, but need not exclude
many separate frames may still need parsing.

Fixes merging NALs into AU.
2011-10-06 12:26:23 +02:00
Sreerenj Balachandran
3129ea29b1 h264parse: correct the size argument of gst_h264_parser_identify_nalu_avc() 2011-10-06 11:59:41 +02:00
Sreerenj Balachandran
bbc30f3644 h264parse: minimum size of parsable avcC data should be 8 2011-10-06 11:59:38 +02:00
Sebastian Dröge
8e2c5833f1 videoparsers: Only fail to initialize the plugin if all parsers can't be registered 2011-10-04 12:31:05 +02:00
Sebastian Dröge
24241b809e rtpvp8pay: Fix typo 2011-10-03 12:06:27 +02:00
Youness Alaoui
f5abb2c647 rtpvp8: Update the pay/depay to the ietf-draft-01 spec 2011-10-03 11:32:46 +02:00
Vincent Penquerc'h
e4856a2965 mpegtsdemux: fix scanning stopping too early
https://bugzilla.gnome.org/show_bug.cgi?id=648245
2011-10-03 11:15:16 +02:00
Vincent Penquerc'h
46dd7941f3 mpegpsdemux: take into account SCR offset when seeking
Since the seeking byte offset is chosen by linear interpolation
from SCR values, we need to take that first SCR into account
to end up near the correct offset. Otherwise, as the code does
a linear search after that first seek, it will take a LOOOOOONG
time to get there for streams which don't start at zero.

https://bugzilla.gnome.org/show_bug.cgi?id=659485
2011-09-30 15:15:06 +01:00
Vincent Penquerc'h
49d1121101 mpegdemux: answer position query with a stream time position
https://bugzilla.gnome.org/show_bug.cgi?id=659485
2011-09-30 15:11:12 +01:00
Vincent Penquerc'h
71f28c44a0 mpegpsdemux: remove unused field
https://bugzilla.gnome.org/show_bug.cgi?id=659485
2011-09-30 15:05:31 +01:00
Thiago Santos
379670e036 camerabin2: add location to preview image messages
Makes camerabin2 intercept preview-image messages and add
the filename corresponding to the message structure in the
'location' field.

Makes easier for applications to track preview images
2011-09-29 18:21:06 -03:00
Robert Swain
6446cc4ae9 camerabin2: Fix potential loss of EOS event
Setting the audio source to NULL just after pushing the EOS event
on it could potentially cause loss of said EOS event. Instead, we
can set the audio source to NULL when ready-for-capture is
signalled and the boolean value is true as this indicates we are
not currently capturing video.
2011-09-29 16:22:00 +02:00
Robert Swain
f4e744ff49 camerabin2: Stop the audio source between captures
Move the audio source setting of state to NULL to _stop_capture () to
avoid the audio source running between captures.
2011-09-26 17:23:41 +02:00
Thibault Saunier
2c928aba19 codecparsers: Declare the new APIs as unstable for the time being 2011-09-26 08:11:45 -03:00
Vincent Penquerc'h
38cdb54112 mpegtsdemux: keep CRC table in .rodata
https://bugzilla.gnome.org/show_bug.cgi?id=660118
2011-09-26 13:00:03 +02:00
Mark Nauwelaerts
e615cf15a9 irtspparse: add Interleaved RTSP parser element 2011-09-26 12:20:35 +02:00
Tim-Philipp Müller
ad1883f54d psmux: fix writing of system header, which makes VLC not skip the adjacent PSM and play embedded H.264 streams
header_length contains the length in bytes after the header_length
field, excluding the 6 byte start code and header_length field.

H.264 streams and some other formats need to be announced in the PSM.
VLC wouldn't play files created with mpegpsmux containing H.264 because
we claim the system header is larger than it actually is, which makes
VLC skip the program stream map which follows the system header, which
in turn makes it not recognise our H.264 video stream.
2011-09-22 20:11:21 +01:00
Mark Nauwelaerts
b142663ca5 h263parse: bring debug statements up to desired specs 2011-09-19 14:55:12 +02:00
Mark Nauwelaerts
66f644cfcc h264parse: bring debug statements up to desired specs 2011-09-19 14:55:09 +02:00
Vincent Penquerc'h
837500af07 rtpvp8: fix bitstream parsing using the wrong kind of bitreader
VP8 uses a probabilistic bool coder, not a straight bit coder.
This fixes parsing when error-resilient is set.

This commit includes a copy of libvpx's bool coder, BSD licensed.

https://bugzilla.gnome.org/show_bug.cgi?id=652694
2011-09-19 11:33:34 +02:00
Thiago Santos
b8f9c3b39d camerabin2: Adding 2 more log messages 2011-09-16 00:52:53 -03:00
Vincent Penquerc'h
25c3ce9a7a camerabin2: replace deprecated g_atomic_int_exchange_and_add
It was replaced by g_atomic_int_add, which now returns the
old value.

https://bugzilla.gnome.org/show_bug.cgi?id=659061
2011-09-16 00:52:53 -03:00
Thiago Santos
cc27a7fe3a camerabin2: Reset last state change result on state-locked elements
An element stores the result for the last state change it did and
GstBin's state change handler will use this last result for state
locked elements to decide if its state change was successfull or not.

In camerabin2, the filesinks have their state locked and when they
fail switching states, this last failure will be used if the application
tries to change camerabin2's state, causing any state change to fail.

This patch makes camerabin2 reset this last change failure, avoiding
that camerabin2 fails on its next state changes.
2011-09-16 00:52:53 -03:00
Thibault Saunier
df551c0af4 mpegvideoparse: Handle properly frame detection
Handle the case where we have buffers containing no startcode
in the middle of a frame properly.
2011-09-14 12:13:19 -03:00
Mark Nauwelaerts
a31d541f07 mpegvideoparse: send a video-codec tag
https://bugzilla.gnome.org/show_bug.cgi?id=569305
2011-09-14 16:14:54 +02:00
Thiago Santos
00e635e786 camerabin2: Check zoom notify callback from camera-source
Camerabin2 has a zoom property that is simply proxied to its
internal camera-source element. This patch makes camerabin2 listen
to 'notify' signals from it so it can update its zoom property value
when camera-source changes its zoom as a side-effect of another operation
or because the user set the zoom directly to it, instead of doing
it from camerabin2.
2011-09-12 17:49:25 -03:00
Alessandro Decina
6e9873038b mpegvideoparse: fix compiler warnings 2011-09-12 10:23:36 +02:00
Thibault Saunier
404c18ab18 h264parse: Make use of the h264_nal_parser_free function 2011-09-09 15:02:35 -03:00
Sebastian Dröge
24517ba784 hlsdemux: Fix merge mistake from last commit 2011-09-09 12:27:57 +02:00
Youness Alaoui
55e4206159 hlsdemux: Report the correct timestamp for live streams
Buffers would always start with timestamp 0 and we'd start streaming
from the first buffer, but live streams always start streaming from
the last fragment - 3 fragments in the playlist, which makes its
timestamp, as returned by get_next_fragment, be whatever position
they had in the playlist. This makes sure the position correctly
reports the position of the buffer in the playlist, and added a shifting
variable to allow seeking in the middle of fragments.
2011-09-09 12:21:36 +02:00
Youness Alaoui
894ac8f493 hlsdemux/tsdemux: Add HP copyright on work done on HLS 2011-09-09 12:12:12 +02:00
Youness Alaoui
609bdd6642 hlsdemux: set playlist to NULL after unreffing it to avoid a double-unref in the dispose 2011-09-09 12:11:42 +02:00
Youness Alaoui
84e67767a3 hlsdemux: Do not lock the mutex of the fetcher during EOS
The fetch_location might call stop_fetcher which could generate an EOS
and cause a deadlock
2011-09-09 12:10:56 +02:00
Youness Alaoui
baf875b928 hlsdemux: Do not join the task from the task's thread itself. join it only in the state change 2011-09-07 22:26:47 +02:00
Vincent Penquerc'h
1a6dbe1e27 mpegvideoparse: make this build with older glib
g_list_free_full is a new convenience function.
Replace it with g_list_foreach and g_list_free.

https://bugzilla.gnome.org/show_bug.cgi?id=658450
2011-09-07 14:34:33 +02:00
Sebastian Dröge
724d7a3def videoparsers: Make the h263 and (new) mpeg video parser autopluggable 2011-09-07 13:47:51 +02:00
George Kiagiadakis
ddf32e2c49 h264parse: Fix IDR position marking when the IDR is split into several NALs 2011-09-07 13:36:12 +03:00
Sebastian Dröge
e86e66e86c h263parse: Add all always present fields to the src template caps 2011-09-07 11:29:37 +02:00
Sebastian Dröge
89aa5dae9d diracparse: Add all fields to the src template caps 2011-09-07 11:29:37 +02:00
Sebastian Dröge
2adf76eb52 videoparsers: Allow parsed streams to be passed through the parsers 2011-09-07 11:29:37 +02:00
Sebastian Dröge
d4147a2798 h264parse: Put stream-format and alignment into the src template caps
Also remove the parsed field from the sink template caps.
2011-09-07 11:29:37 +02:00
Sebastian Dröge
456335eab4 h264parse: Change rank to PRIMARY+1 to have h264parse autoplugged 2011-09-07 11:29:36 +02:00
Sebastian Dröge
29a358e8cd diracparse: Constify some arrays 2011-09-07 11:29:36 +02:00
Sebastian Dröge
cfb986b6bf h264parse: Add Converter to classification
This parser can convert between different alignments and stream-formats.
2011-09-06 13:21:28 +02:00
Youness Alaoui
473e71e1ca hlsdemux: If a fetch fails, decrement the sequence number 2011-09-03 09:09:02 +02:00
Youness Alaoui
5aa972eab2 hlsdemux: make hlsdemux lock/unlock the m3u8 client when it accesses it 2011-09-03 09:01:40 +02:00
Youness Alaoui
6133608789 hlsdemux: Add a get_target_duration and get_current_uri api to m3u8_client 2011-09-03 09:00:50 +02:00
Youness Alaoui
a252794a03 hlsdemux: Make the m3u8 client thread-safe 2011-09-03 09:00:35 +02:00
Sebastian Dröge
a82f92aed2 hlsdemux: Reset in PAUSED->READY after chaining up to the parent class
Otherwise there are possible race conditions with the streaming thread.
2011-09-02 19:45:21 +02:00
Thibault Saunier
b968f82b18 h264parse: Port to the new h.264 parsing library 2011-09-02 15:46:02 +02:00
Thibault Saunier
a983b29a49 mpegvideoparse: Port to the new mpeg parsing library 2011-09-02 15:46:02 +02:00
Sebastian Dröge
0561c3751c hlsdemux: Remove obsolete FIXME comment 2011-09-02 15:00:58 +02:00
Sebastian Dröge
82bbc76f15 hlsdemux: Reset the internal state going to/from READY instead of NULL
This theoretically allows reuse of the element when setting it to READY
instead of NULL.
2011-09-02 14:55:45 +02:00
Sebastian Dröge
445f626016 hlsdemux: Set playlist parsing helper object to NULL after freeing 2011-09-02 14:54:56 +02:00
Youness Alaoui
acacc251fa hlsdemux: Allow up to 3 consecutive failed downloads before erroring
In some networks, especiall in 3G, a fragment download or playlist
update may fail. We allow for up to 3 consecutive failures, while using
the rfc's specs for retry delays before considering that there was an
error on the stream.
2011-09-02 14:52:07 +02:00
Youness Alaoui
8889c5927c hlsdemux: remove unused argument 2011-09-02 14:51:11 +02:00
Robert Swain
db0739e54f camerabin2: Add a flag to disable image conversion elements
If we know that our camera source element produces buffers at the same
resolution and appropriate colourspace for the output, we don't need any
of the generic conversion elements in encodebin. This reduces caps
negotiation overheads among other things.
2011-09-01 15:57:50 +02:00
Thiago Santos
2ed3d1b309 camerabin2: Micro optimize encodebin pads linking
Reduce one check in encodebin pads linking on camerabin2 by
using the link_pads_full version
2011-08-31 15:45:18 -03:00
Thiago Santos
ac7fc0d357 camerabin2: Use explicit boolean literals to make gobject happy
gobject boolean properties are strict and only accept 1 or 0, otherwise
they throw an assertion.
2011-08-31 15:45:18 -03:00
Sebastian Dröge
cf8f00d57a hlsdemux: Just join the task
gst_task_join() will already stop the task, no need
to stop it additionally.
2011-08-31 14:48:47 +02:00
Sebastian Dröge
119771eaab hlsdemux: Join the task instead of just stopping it and not waiting for it to finish
Fixes interesting race conditions that cause crashes in decodebin2
because pads are added/removed from child elements although they
should be in READY state already.
2011-08-31 14:47:40 +02:00