Sebastian Dröge
160df421ea
vtdec: Register a hardware-only vtdec_hw on OSX and give it a higher rank
...
while having the default vtdec at secondary rank. This allows decodebin/playbin
to prefer the hardware based decoders, and if that fails to initialize because
hardware resources are busy to fall back to e.g. the libav based h264 decoder
instead of the software based vtdec (which is slower), and only fall back to
the software based vtdec if there is no higher ranked decoder available.
2015-03-07 10:31:26 +01:00
Matthew Waters
c873c57430
vtdec: only attempt use of the texture cache with GLMemory caps features
...
Otherwise we send rectangle textures to glimagesink
2015-02-25 00:03:34 +11:00
Alessandro Decina
052e4804eb
vtdec: fix texture sharing on iOS
...
Move GLES calls to the context thread. Fix
CVOpenGLESTextureCacheCreateTextureFromImage usage on iOS.
2015-02-09 21:18:24 +11:00
Sebastian Dröge
dac3e4ca06
vtdec: Don't dereference NULL frames when draining/flushing
2015-02-03 15:38:40 +01:00
Alessandro Decina
f577b52e5d
applemedia: rework GL texture sharing
...
Use YUV instead of RGB textures, then convert using the new apple specific
shader in GstGLColorConvert. Also use GLMemory directly instead of using the
GL upload meta, avoiding an extra texture copy we used to have before.
2015-01-30 00:34:08 +11:00
Alessandro Decina
77d48abfab
applemedia: vtdec: fix CMBlockBufferRef leak
...
Fix huge leak that went unnoticed for too long. Oops.
2015-01-30 00:34:08 +11:00
Alessandro Decina
e91989136a
applemedia: corevideobuffer: make mapping the CVPixelBuffer in CPU optional
...
Mapping is not necessary and impacts performance when doing texture sharing with
downstream
2015-01-30 00:34:08 +11:00
Alessandro Decina
d95a12e185
vtdec: implement the GL texture upload meta
2015-01-15 14:10:43 +11:00
Alessandro Decina
d0ce9a6f7c
vtdec: disable the reorder queue for baseline streams
2014-11-20 16:06:46 +01:00
Sebastian Dröge
6e2e8ec0ac
vtdec: Fix divide by zero in the picture buffer length calculation
2014-11-20 09:42:24 +01:00
Sebastian Dröge
3cead041f6
vtdec: Set reorder length to 0 if we can't calculate it
...
Instead of leaving it at whatever value it had before.
2014-10-14 09:19:59 +02:00
Sebastian Dröge
de9b0be86d
vtdec: Fix compilation
2014-09-18 10:30:04 +03:00
Sebastian Dröge
e653068bc2
vtdec: Handle 0/1 framerates correctly by not calculating their frame duration
2014-09-18 09:47:06 +03:00
Sebastian Dröge
e4563ce6cf
vtdec: Properly scale timestamps for the API and set invalid values
2014-09-17 14:54:39 +03:00
Sebastian Dröge
3a52f6b757
vtdec: Fix compiler warnings
...
values of type 'OSStatus' should not be used as format arguments; add an explicit cast to 'int' instead [-Wformat]
2014-09-16 15:48:11 +03:00
Sebastian Dröge
0f0a50c119
vtdec: No need to set kVTVideoDecoderSpecification_EnableHardwareAcceleratedVideoDecoder on iOS
2014-09-15 15:42:41 +03:00
Sebastian Dröge
c82fa4f845
applemedia: Don't include VideoToolbox on iOS < 8.0
...
It's private API and does not work without a jailbroken device.
2014-09-15 15:12:31 +03:00
Sebastian Dröge
0b34cde46e
vtdec: Fix compilation on iOS 8.0
2014-09-13 20:49:16 +03:00
Thiago Santos
92dbcf2bf9
vtdec: avoid segfault when output isn't configured
...
This can help when the callback is called during/after videodecoder
base class shut down
https://bugzilla.gnome.org/show_bug.cgi?id=728435
2014-07-02 06:19:58 -03:00
Thiago Santos
f75f860ff3
vtdec: ignore the dropped flag if buffer was received
...
Apparently there is some issue with VT that makes it mark the dropped
flag even though the buffer was decoded.
https://bugzilla.gnome.org/show_bug.cgi?id=728435
2014-07-02 05:48:32 -03:00
Alessandro Decina
a75ddf446b
applemedia: vtdec: remove silly stride requirement
...
This is legacy from the 0.10 times, and it isn't clear how it was useful back
then also.'
2013-12-19 08:59:39 +01:00
Davide Bertola
72e989f2da
applemedia: vtdec: Enable hardware accelerated decoding on 10.9
2013-12-18 10:28:17 +01:00
Alessandro Decina
d5eccb2285
applemedia: vtdec: handle level 3 in get_dpb_max_mb_s_from_level. oops.
2013-12-14 19:18:41 +01:00
Alessandro Decina
de60453a33
applemedia: vtdec: fix compiler warning (uninitialized variable)
2013-12-11 18:52:53 +01:00
Alessandro Decina
00392a6d16
applemedia: vtdec: rename reorder_queue_frame_delay to reorder_queue_length
2013-12-11 08:12:37 +01:00
Alessandro Decina
596aa8e05a
applemedia: vtdec: report latency
2013-12-11 08:12:36 +01:00
Alessandro Decina
733a780e9d
applemedia: vtdec: set reorder queue length to the max DPB length
...
Set reorder_queue_frame_delay from the DPB size (in frames). Still not optimal,
as the DPB size is larger than the max bframe forward prediction length, but I
don't know how to compute the latter without parsing every group of pictures.
2013-12-11 08:12:36 +01:00
Alessandro Decina
7dffa2e1f2
applemedia: vtdec: set the correct video format in the video meta
...
Fixes all kinds of weird bugs when videoconvert is used with the decoder.
2013-12-10 11:12:56 +01:00
Alessandro Decina
839970e07c
applemedia: vtdec: fix mpeg2 video support
2013-12-08 15:31:09 +01:00
Alessandro Decina
938ce6a23d
applemedia: vtdec: make jpeg decoding actually work
2013-12-08 15:25:27 +01:00
Alessandro Decina
1cd62000f5
applemedia: vtdec: fail gracefully when not negotiated
2013-12-08 15:24:58 +01:00
Alessandro Decina
b1a756fda7
applemedia: rewrite VideoToolbox decoder based on GstVideoDecoder
2013-12-08 15:13:26 +01:00
Andoni Morales Alastruey
bab2bf3f11
applemedia: fix release of null pointer
2013-06-18 13:33:14 +02:00
Andoni Morales Alastruey
5f4ac8c58f
vtdec: simplify caps setting
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
2f36ffb7d0
applemedia: fix H264 streams with b-frames
...
The decoder output frames in DTS order, even with the flag
kVTDecodeFrame_EnableTemporalProcessing. We store a internal
queue of the decoded frames and push them PTS order.
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
3b249f6761
applemedia: fix segfault with dropped frames
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
d9db0c2d4a
applemedia: improve usage of the VT API
...
Add timing information to CV samples and pass the GstBuffer
as extra data in the decode function
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
db49a77682
applemedia: add support for MPEG-1 too
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
9645d1df2d
applemedia: add support for MPEG-2 decoding
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
5e09d61638
applemedia: use the best colorformat on each platform
...
This saves a colorspace conversion before the sink in OS X
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
c69f41d299
applemedia: replace private function with its public variant
...
FigVideoFormatDescriptionCreateWithSampleDescriptionExtensionAtom
is an un-documented private function which might change its signature
as it already did in the past. Replace it with
CMVideoFormatDescriptionCreate and the also un-documented Extensions
dictionary.
2013-05-20 13:31:02 +02:00
Andoni Morales Alastruey
97bb1edf6c
applemedia: don't use the dynamic API for public frameworks
...
Public frameworks don't need to build the API dynamically, we instead
use the framework directly.
The exception is for VideoToolbox which went public in the 10.8 SDK,
but it's still private in older version of the SDK and iOS. This allow
building the plugin against SDK's where it's not a public framework.
2013-05-20 13:31:02 +02:00
Ole André Vadla Ravnås
519cefdeee
applemedia: update contact information
2013-02-16 02:51:52 +01:00
Ole André Vadla Ravnås
bace18bacc
applemedia: replace usage of deprecated gst_pad_set_caps() in vtdec
2013-02-16 02:51:51 +01:00
Ole André Vadla Ravnås
af6df7292c
applemedia: port vtapi to run on OS X 10.8
2013-02-16 02:51:51 +01:00
Tim-Philipp Müller
9e1b75fda3
Fix FSF address
...
https://bugzilla.gnome.org/show_bug.cgi?id=687520
2012-11-04 00:09:59 +00:00
Mark Nauwelaerts
9cb0cc216d
applemedia: init videoinfo
2012-09-18 13:19:37 +02:00
Alessandro Decina
8546458617
applemedia: port vtdec
2012-03-03 19:04:36 +01:00
Ole André Vadla Ravnås
f3d8e3920d
applemedia: only enqueue buffers in the VideoToolbox callbacks
...
These callbacks may fire from any thread, hence we should only enqueue
buffers and let the streaming thread take care of the rest as soon as
the blocking encode or decode operation has finished.
2010-12-10 04:07:05 +01:00
Ole André Vadla Ravnås
ebd2a6d6e9
applemedia: don't push synchronously from callback
...
The codec that called us might be holding locks to shared resources, so
we should never push downstream from within its buffer callback.
Note that a GstBufferList is not used here because we need to preserve
the buffer metadata held by our GstBuffer subclasses.
2010-11-11 00:22:31 +01:00