Wind Yuan [Wed, 30 Jan 2013 05:23:03 +0000 (13:23 +0800)]
h264: fix reference list count less than num_ref
Sometimes RefPicListX_count may be less than num_ref_idx_lX.
There's not enough reference pictures in dpb.
Wind Yuan [Fri, 30 Nov 2012 05:09:40 +0000 (13:09 +0800)]
h264: clear buffers on GST_EVENT_FLUSH_STOP
Change-Id: I4a9978a50bc6f6011f3ca037b9b9e8b295369b86
Wind Yuan [Wed, 5 Dec 2012 07:04:25 +0000 (15:04 +0800)]
mpeg2: clear buffers and PTSGenerator on GST_EVENT_FLUSH_STOP
Change-Id: I7f7561805f9efd1513d5f1a04308c2b39ce986c8
Wind Yuan [Fri, 30 Nov 2012 05:06:10 +0000 (13:06 +0800)]
vaapidecode: support seek actions
vaapidecode need clear all decoder's buffers when
GST_EVENT_FLUSH_STOP/GST_EVENT_NEWSEGMENT happened
Change-Id: I83606f6b619c4501b43bf868bc92787b670fab88
Gwenole Beauchesne [Tue, 5 Feb 2013 13:03:39 +0000 (14:03 +0100)]
codecparsers: update to gst-vaapi-branch commit b8efe57.
b8efe57 mpeg2: add helpers to convert quantization matrices
f8c2672 mpeg2: store quantization matrices in zigzag-order
Wind Yuan [Wed, 23 Jan 2013 02:31:30 +0000 (10:31 +0800)]
rate_control: compatible with old libva versions
Zhong Cong [Wed, 16 Jan 2013 06:17:50 +0000 (14:17 +0800)]
vaapipostproc: warn when framerate failed to be parsed.
Zhong Cong [Mon, 24 Dec 2012 06:28:45 +0000 (14:28 +0800)]
modify the DEBUG function name "vaapi_encoder_dump_bytes" to "gst_vaapi_encoder_dump_bytes",because only symbols with the gst-vaapi_* prefix will be exported
Wind Yuan [Mon, 5 Nov 2012 07:34:24 +0000 (15:34 +0800)]
encoders: h263, mpeg4 change bitrate attributes to unit kbps
Wind Yuan [Mon, 5 Nov 2012 07:22:28 +0000 (15:22 +0800)]
h264encoder: implement bitrate control for CBR and VBR
Wind Yuan [Mon, 12 Nov 2012 09:04:07 +0000 (17:04 +0800)]
decoder context: rate_control unset to GST_VAAPI_RATECONTROL_NONE
Wind Yuan [Wed, 14 Nov 2012 08:35:48 +0000 (16:35 +0800)]
h264encoder: add rate-control attribute
encoder create context with special rate-control config
Wind Yuan [Fri, 2 Nov 2012 08:55:13 +0000 (16:55 +0800)]
vaapicontext: support rate-control attribute
encoder need rate-control on context creation
Wind Yuan [Thu, 1 Nov 2012 07:27:32 +0000 (15:27 +0800)]
encoder: h264 support multiple slices
Wind Yuan [Thu, 18 Oct 2012 09:58:04 +0000 (17:58 +0800)]
encoder: PVR only need seq paramerter set once
Wind Yuan [Tue, 25 Sep 2012 07:37:43 +0000 (15:37 +0800)]
configure.ac: check old/new h264 encoder API
Wind Yuan [Tue, 25 Sep 2012 05:31:51 +0000 (13:31 +0800)]
encoder: h264 compatible with old libva by macro HAVE_OLD_H264_ENCODER
Wind Yuan [Fri, 21 Sep 2012 09:03:35 +0000 (17:03 +0800)]
encoder: align formats to gstreamer code style
Wind Yuan [Thu, 20 Sep 2012 06:41:53 +0000 (14:41 +0800)]
encoder: reduce function parameters and change variable names
Wind Yuan [Thu, 2 Aug 2012 07:29:05 +0000 (03:29 -0400)]
encoders: remove encoders image upload and simplify parts code
Wind Yuan [Mon, 30 Jul 2012 07:34:55 +0000 (03:34 -0400)]
h264 encoder: worked in staging branch
Wind Yuan [Mon, 30 Jul 2012 02:03:08 +0000 (22:03 -0400)]
h264 encoder: compiling passed with libva staging branch
Wind Yuan [Fri, 20 Jul 2012 07:27:57 +0000 (03:27 -0400)]
encoder(h264,h263,mpeg4): changed styles, names
current h264 encoder works in branch of 'vaapiext' of libva/intel-driver in GEN platform.
other encoders(h263,mpeg4) only tested in pvr long ago.
encoder need be configured with '--enable-encoders' explicitly.
Wind Yuan [Thu, 21 Jun 2012 06:46:43 +0000 (14:46 +0800)]
h264encoder: auto-detect stream-format: avc/byte-stream by next linked-pad's caps
Wind Yuan [Wed, 18 Jan 2012 11:02:43 +0000 (19:02 +0800)]
fix compile issue after rebase
Wind Yuan [Thu, 22 Dec 2011 13:02:10 +0000 (21:02 +0800)]
add Intel Copyright
Wind Yuan [Thu, 22 Dec 2011 06:42:40 +0000 (14:42 +0800)]
compiling passed in for new vaapiencode
Wind Yuan [Tue, 29 Nov 2011 02:31:44 +0000 (10:31 +0800)]
change encoder log output format, support GST log
Wind Yuan [Mon, 28 Nov 2011 06:17:52 +0000 (01:17 -0500)]
support B frames
Wind Yuan [Wed, 23 Nov 2011 07:04:42 +0000 (02:04 -0500)]
Support h264encoder on SandyBridge platform(lots libva h264 encoding parameters changed)
Wind Yuan [Thu, 20 Oct 2011 07:24:30 +0000 (15:24 +0800)]
supports mpeg4 encoder
Wind Yuan [Thu, 13 Oct 2011 07:32:22 +0000 (15:32 +0800)]
change h264encoder.x to gstvaapih264encoder.x
Wind Yuan [Thu, 13 Oct 2011 07:17:54 +0000 (15:17 +0800)]
support h263 encoder(vah263encode) in mrst "gst-launch videotestsrc num-buffers=100 pattern=18 ! video/x-raw-yuv,format='(fourcc)'NV12,width=640,height=480,framerate=30/1 ! vaapiconvert ! vah263encode ! qtmux faststart=true ! filesink location=263.mp4"
Wind Yuan [Mon, 10 Oct 2011 02:24:02 +0000 (10:24 +0800)]
extract vaapiencoder structure to make other encoders possible
Wind Yuan [Fri, 30 Sep 2011 06:33:44 +0000 (14:33 +0800)]
support multiple h264 slices, auto calculate bitrate(=w*h*fps/4) add properties : min-qp, slice-num
Wind Yuan [Thu, 29 Sep 2011 14:08:26 +0000 (22:08 +0800)]
add properties in gsth264encode; profile, level,bitrate, intra-period, init-qp
Wind Yuan [Tue, 27 Sep 2011 05:24:05 +0000 (13:24 +0800)]
vah264encode co-work with vaapiconvert passed "gst-launch videotestsrc ! video/x-raw-yuv,format='(fourcc)'NV12,width=1280,height=720,framerate=30/1 ! vaapiconvert ! vah264encode ! fakesink"
Wind Yuan [Mon, 19 Sep 2011 01:47:36 +0000 (09:47 +0800)]
change h264encoder
Wind Yuan [Thu, 5 Jan 2012 03:17:33 +0000 (11:17 +0800)]
vaapiconvert: change direct-rendering=0 to vaPutImage and support YUY2 colorspace to vaImage
Wind Yuan [Thu, 22 Dec 2011 13:02:10 +0000 (21:02 +0800)]
add Intel Copyright
Wind Yuan [Thu, 22 Dec 2011 06:42:40 +0000 (14:42 +0800)]
compiling passed in 3.0 for vaapiencode
Wind Yuan [Thu, 22 Dec 2011 06:41:42 +0000 (14:41 +0800)]
vaapiconvert support multiple YUV colorspace
Wind Yuan [Fri, 9 Dec 2011 07:55:01 +0000 (15:55 +0800)]
Add FPS log print in vaapiencode
Wind Yuan [Wed, 7 Dec 2011 04:58:10 +0000 (12:58 +0800)]
Use config.h to vaapiencode
Wind Yuan [Tue, 6 Dec 2011 01:19:56 +0000 (20:19 -0500)]
add fps caculation macro
Wind Yuan [Mon, 5 Dec 2011 06:23:10 +0000 (01:23 -0500)]
support YUY2 convert to surface
Wind Yuan [Thu, 1 Dec 2011 18:07:31 +0000 (13:07 -0500)]
vaapiconvert: try directly copy buffer to derived surface first
Wind Yuan [Tue, 29 Nov 2011 02:31:44 +0000 (10:31 +0800)]
change encoder log output format, support GST log
Wind Yuan [Tue, 29 Nov 2011 02:31:02 +0000 (10:31 +0800)]
support multiple threads for vaapivideopool
Wind Yuan [Thu, 24 Nov 2011 08:35:09 +0000 (03:35 -0500)]
support raw-buffer directly converted to surface in vaapiconvert
Wind Yuan [Wed, 23 Nov 2011 07:01:30 +0000 (02:01 -0500)]
Add context API <gst_vaapi_context_get_surface_pool>
Wind Yuan [Mon, 19 Sep 2011 01:47:36 +0000 (09:47 +0800)]
add h264encoder
Wind Yuan [Wed, 12 Sep 2012 08:58:06 +0000 (04:58 -0400)]
caps: vaapi doesn't need framerate
Zhao,Halley [Mon, 22 Oct 2012 16:56:45 +0000 (00:56 +0800)]
fix typo do not create color-balance filter when not needed
Zhao Halley [Mon, 17 Sep 2012 08:25:52 +0000 (16:25 +0800)]
remove _get_caps for postproc srcpad caps will retrieve from pad template, suppress a gst warning
Zhao Halley [Fri, 14 Sep 2012 09:49:43 +0000 (17:49 +0800)]
add color balance support in vpp
hue/brightness/contrast/saturation
auto-brightness/auto-contrast/auto-saturation
Zhao Halley [Fri, 14 Sep 2012 09:44:20 +0000 (17:44 +0800)]
share property operation code between GstVaapiPostproc and GstVaapiPostprocess
Zhao Halley [Fri, 31 Aug 2012 09:13:25 +0000 (17:13 +0800)]
add vpp process in gstvaapipostproc
Zhao Halley [Wed, 12 Sep 2012 09:08:31 +0000 (17:08 +0800)]
add vpp process in gstvaapipostprocess
denoise, deinterlace, surface fromat conversion, scaling
Zhao Halley [Fri, 31 Aug 2012 07:57:44 +0000 (15:57 +0800)]
check vpp support in configure.ac
Zhao Halley [Wed, 12 Sep 2012 09:05:29 +0000 (17:05 +0800)]
Add new object GstVaapiPostProcess for post-processing
separate some enum from gstvaapipostproc to gstvaapipostprocess
Zhao Halley [Fri, 31 Aug 2012 06:59:48 +0000 (14:59 +0800)]
add fourcc for GstVaapiSurface
surface creation with dedicate fourcc is supported after VA API 0.34
legacy interface still works on lower version VA API
Zhao Halley [Tue, 8 Jan 2013 21:40:46 +0000 (05:40 +0800)]
h264: reset got_{sps,pps} when corrupted SPS/PPS headers are parsed.
Reset got_{sps,pps} when corrupted SPS/PPS headers are parsed. This means
that no frame will be decoded until valid SPS/PPS headers are parsed again.
This also prevents from parsing slice headers with invalid data, and avoids
potential crashes.
https://bugs.freedesktop.org/show_bug.cgi?id=57902
Gwenole Beauchesne [Wed, 23 Jan 2013 10:11:25 +0000 (11:11 +0100)]
vc1: handle CLOSED_ENTRY.
When CLOSED_ENTRY == 0, and if the B pictures that follow an entry-point
lack a reference anchor picture, these B pictures shall be discarded.
https://bugs.freedesktop.org/show_bug.cgi?id=59505
Wind Yuan [Fri, 11 Jan 2013 09:08:00 +0000 (17:08 +0800)]
vc1: fix decoding of WMV3 videos in AVI format.
The AVI demuxer (avidemux) does not set a proper "format" attribute
to the generated caps. So, try to recover the video codec format from
the "wmvversion" property instead.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Gwenole Beauchesne [Tue, 22 Jan 2013 12:28:13 +0000 (13:28 +0100)]
vc1: review and report errors accordingly.
Use GST_ERROR() to report real errors instead of hiding them into
GST_DEBUG().
Gwenole Beauchesne [Wed, 23 Jan 2013 09:25:52 +0000 (10:25 +0100)]
vc1: cope with latest codecparser changes.
Fix build with newer VC-1 codecparser where dqsbedge was renamed to
dqbedge, and now represents either DQSBEDGE or DQDBEDGE depending on
the actual value of DQPROFILE.
Gwenole Beauchesne [Fri, 25 Jan 2013 09:40:18 +0000 (10:40 +0100)]
codecparsers: update to gst-vaapi-branch commit 35053b8.
aeb898b vc1: fix bitplanes decoding (DIFF6 or NORM6 residual bytes)
63e3344 vc1: fix bitplanes decoding (DIFF6 or NORM6)
b0a9372 vc1: add API to parse slice headers
773f3d1 vc1: fix bitplanes decoding
870e083 vc1: simplify GstVC1VopDquant structure
bc0d65e vc1: fix VOPDQUANT parser for DQUANT == 2
dcd3abd vc1: fix calculation of ALTPQUANT
73ca0b7 vc1: fix parser for DQPROFILE in VOPDQUANT
8840c2d h264: zero-initialize SPS VUI parameters
Gwenole Beauchesne [Mon, 14 Jan 2013 15:06:54 +0000 (16:06 +0100)]
codecparsers: update to gst-vaapi-rebased commit b47983a.
b47983a h264: add inferred value for slice_beta_offset_div2
Gwenole Beauchesne [Tue, 18 Dec 2012 09:32:20 +0000 (10:32 +0100)]
Bump version for development.
Gwenole Beauchesne [Tue, 18 Dec 2012 09:31:52 +0000 (10:31 +0100)]
0.4.2.
Gwenole Beauchesne [Mon, 17 Dec 2012 13:57:44 +0000 (14:57 +0100)]
NEWS: updates.
Gwenole Beauchesne [Tue, 20 Nov 2012 13:36:29 +0000 (14:36 +0100)]
image: fix GstVaapiImage map and unmap.
Fix gst_vaapi_image_map() to return TRUE and the GstVaapiImageRaw
structure correctly filled in if the image was already mapped.
Likewise, make gst_vaapi_image_unmap() return TRUE if the image
was already unmapped.
Wind Yuan [Fri, 12 Oct 2012 08:50:09 +0000 (16:50 +0800)]
mpeg4: fix decoding at end-of-stream.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Wind Yuan [Fri, 12 Oct 2012 08:44:05 +0000 (16:44 +0800)]
mpeg4: fix size argument to gst_adapter_flush().
Flush only consumed_size bytes from the GstAdapter.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Gwenole Beauchesne [Mon, 17 Dec 2012 10:51:17 +0000 (02:51 -0800)]
tests: add test for MPEG-4:2 decoding.
Gwenole Beauchesne [Mon, 17 Dec 2012 12:42:29 +0000 (04:42 -0800)]
h264: initialize VA context before allocating the first slice.
Fix decode_slice() to ensure a VA context exists prior to creating a
new GstVaapiSliceH264, which invokes vaCreateBuffer() with some VA
context ID. i.e. the latter was not initialized, thus causing failures
on Cedar Trail for example.
Zhao Halley [Wed, 5 Dec 2012 01:15:32 +0000 (09:15 +0800)]
configure: install plugin elements in GST_PLUGIN_PATH, if set.
If GST_PLUGIN_PATH environment variable exists and points to a valid
directory, then use it as the system installation path for gst-vaapi
plugin elements.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Gwenole Beauchesne [Mon, 17 Dec 2012 12:15:53 +0000 (04:15 -0800)]
libs: only export gst_vaapi_*() symbols.
This fixes symbol clashes between the gst-vaapi built-in codecparsers/
library and the system-provided one, mainly used by videoparses/. Now,
only symbols with the gst_vaapi_* prefix will be exported, if they are
not marked as "hidden" to libgstvaapi.
Gwenole Beauchesne [Mon, 17 Dec 2012 08:41:24 +0000 (09:41 +0100)]
libs: fix compatibility with glib 2.28.
Always prefer non deprecated APIs by default and provide compatibility
glue for older glib versions when necessary.
Gwenole Beauchesne [Mon, 17 Dec 2012 09:10:55 +0000 (10:10 +0100)]
libs: use glib >= 2.32 semantics for mutexes.
Use glib >= 2.32 semantics for GMutex and GRecMutex wrt. initialization
and termination. Basically, the new mutex objects can be used as static
mutex objects from the deprecated APIs, e.g. GStaticMutex and GStaticRecMutex.
Rob Bradford [Thu, 4 Oct 2012 16:39:53 +0000 (17:39 +0100)]
vaapidecode: adopt non-deprecrated glib locking primitive pattern.
The use of heap allocated GMutex/GCond is deprecated. Instead place them
inside the structure they are locking.
These changes switch to use g_mutex_init/g_cond_init rather than the heap
allocation functions.
Because we cannot test for a NULL pointer for the GMutex/GCond we must
initialise inside the GObject _init function and clear inside the _finalize
which is guaranteed to only be called once and after the object is no longer
in use.
Wind Yuan [Tue, 30 Oct 2012 05:15:45 +0000 (13:15 +0800)]
videobuffer: fix memory leak for surface and image.
Fix reference leak of surface and image in GstVaapiVideoBuffer wrapper,
thus resulting on actual memory leak of GstVaapiImage when using them
for downloads/uploads from VA surfaces and more specifically surfaces
when the pipeline is shutdown. i.e. vaTerminate() was never called
because the resources were not unreferenced, and thus not deallocated
in the end.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Gwenole Beauchesne [Tue, 27 Nov 2012 08:56:08 +0000 (09:56 +0100)]
Bump version for development.
Gwenole Beauchesne [Tue, 27 Nov 2012 08:55:31 +0000 (09:55 +0100)]
Mark release.
Gwenole Beauchesne [Tue, 27 Nov 2012 08:40:11 +0000 (09:40 +0100)]
0.4.1.
Gwenole Beauchesne [Mon, 19 Nov 2012 09:04:52 +0000 (10:04 +0100)]
NEWS: updates.
Rob Bradford [Fri, 2 Nov 2012 18:18:37 +0000 (18:18 +0000)]
wayland: port to 1.0 version of the protocol.
This patch updates to relect the 1.0 version of the protocol. The main
changes are the switch to wl_registry for global object notifications
and the way that the event queue and file descriptor is processed.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Gwenole Beauchesne [Fri, 16 Nov 2012 17:00:10 +0000 (18:00 +0100)]
h264: fix picture size in macroblocks.
The picture size signalled by sps->{width,height} is the actual size with
cropping applied, not the original size derived from pic_width_in_mbs_minus1
and pic_height_in_map_units_minus1. VA driver expects that original size,
uncropped.
There is another issue pending: frame cropping information needs to be
taken care of.
Gwenole Beauchesne [Wed, 14 Nov 2012 17:40:47 +0000 (18:40 +0100)]
h264: start decoding slices after first SPS/PPS activation.
Only start decoding slices when at least one SPS and PPS got activated.
This fixes cases when a source represents a substream of another stream
and no SPS and PPS was inserted before the first slice of the generated
substream.
Gwenole Beauchesne [Wed, 14 Nov 2012 13:25:34 +0000 (14:25 +0100)]
h264: fix VAPictureParameterBufferH264.ReferenceFrames[] construction.
... for interlaced streams. The short_ref[] and long_ref[] arrays may
contain up to 32 fields but VA ReferenceFrames[] array expects up to
16 reference frames, thus including both fields.
Gwenole Beauchesne [Wed, 14 Nov 2012 09:27:12 +0000 (10:27 +0100)]
h264: fix interlaced stream decoding with MMCO.
Fix decoding of interlaced streams when adaptive_ref_pic_marking_mode_flag
is equal to 1, i.e. when memory management control operations are used. In
particular, when field_pic_flag is set to 0, the new reference flags shall
be applied to both fields.
Gwenole Beauchesne [Tue, 13 Nov 2012 16:14:39 +0000 (17:14 +0100)]
h264: add initial support for interlaced streams.
Decoded frames are only output when they are complete, i.e. when both
fields are decoded. This also means that the "interlaced" caps is not
propagated to vaapipostproc or vaapisink elements. Another limitation
is that interlaced bitstreams with MMCO are unlikely to work.
Gwenole Beauchesne [Tue, 13 Nov 2012 15:35:30 +0000 (16:35 +0100)]
h264: split remove_reference_at() into finer units.
Split remove_reference_at() into a function that actually removes the
specified entry from the short-term or long-term reference picture array,
and a function that sets reference flags to the desired value, possibly
zero. The latters marks the picture as "unused for reference".
Gwenole Beauchesne [Tue, 23 Oct 2012 12:04:22 +0000 (14:04 +0200)]
decoder: fix gst_vaapi_picture_new_field() object type.
Fix gst_vaapi_picture_new_field() to preserve the original picture type.
e.g. gst_vaapi_picture_new_field() with a GstVaapiPictureH264 argument
shall generate a GstVaapiPictureH264 object.
Gwenole Beauchesne [Tue, 13 Nov 2012 13:04:31 +0000 (14:04 +0100)]
h264: add picture structure for reference picture marking process.
Introduce new `structure' field to the H.264 specific picture structure
so that to simplify the reference picture marking process. That local
picture structure is derived from the original picture structure, as
defined by the syntax elements field_pic_flag and bottom_field_flag.
Gwenole Beauchesne [Fri, 2 Nov 2012 14:14:58 +0000 (15:14 +0100)]
h264: introduce new frame store structure.
The frame store represents a Decoded Picture Buffer entry, which can
hold up to two fields. So far, the frame store is only used to hold
full frames.
Gwenole Beauchesne [Wed, 31 Oct 2012 15:37:14 +0000 (16:37 +0100)]
h264: minor clean-ups.
Move DPB flush up if the current picture to decode is an IDR. Besides,
don't bother to check for IDR pictures in dpb_add() function since an
explicit DPB flush was already performed in this case.
Gwenole Beauchesne [Wed, 31 Oct 2012 13:24:09 +0000 (14:24 +0100)]
h264: simplify reference picture marking process.
... to build the short_ref[] and long_ref[] lists from the DPB, instead
of maintaining them separately. This avoids refs/unrefs while making it
possible to generate the list based on the actual picture structure.
This also ensures that the list of generated ReferenceFrames[] actually
matches what reference frames are available in the DPB. i.e. short_ref[]
and long_ref[] entries are implied from the DPB, so there is no risk of
having "dangling" references.
Gwenole Beauchesne [Wed, 31 Oct 2012 10:52:03 +0000 (11:52 +0100)]
h264: introduce per-field POC in GstVaapiPictureH264.
Use the POC member available in the GstVaapiPicture base class and
get rid of the dependency on the local VAPictureH264 TopFieldOrderCnt
and BottomFieldOrderCnt. Rather, use a simple field_poc[] array
initialized to INT_MAX, so that to simplify picture POC calculation
for non frame pictures.