Re: [Libva] [PATCH][G45][3/4] Fix vaGetImage() for YV12 format (round 2)

2010-07-12 Thread Gwenole Beauchesne
Le 13 juil. 10 à 01:29, Gwenole Beauchesne a écrit : This patches fixes YV12 format for vaGetImage(). The components need to follow the VA image order whereas source is always I420. This reminds me the function ought to be called get_image_i420(). New patch attached to cope with new vaGetIm

Re: [Libva] [PATCH][G45][2/4] Simplify vaGetImage() (round 2)

2010-07-12 Thread Gwenole Beauchesne
Hi, Le 13 juil. 10 à 04:07, Xiang, Haihao a écrit : This patch factors out code for get_image_{yv12,nv12}(). A new memcpy_pic() function is introduced and the net result is fewer source code lines. 1. This patch uses rect->y to calculate address for U/V, however the original function uses

Re: [Libva] [PATCH][G45][2/4] Simplify vaGetImage()

2010-07-12 Thread Xiang, Haihao
On Tue, 2010-07-13 at 07:20 +0800, Gwenole Beauchesne wrote: > Hi, > > This patch factors out code for get_image_{yv12,nv12}(). A new > memcpy_pic() function is introduced and the net result is fewer source > code lines. 1. This patch uses rect->y to calculate address for U/V, however the ori

[Libva] [PATCH][G45][4/4] None ;-)

2010-07-12 Thread Gwenole Beauchesne
Hi, I planed 4 patches but just noticed one was totally useless. Basically I was using STRIDE(obj_surface->width) but surface width was already aligned to 16 pixels. So, finally, no patch is needed. Regards, Gwenole. ___ Libva mailing list Libva@l

[Libva] [PATCH][G45][3/4] Fix vaGetImage() for YV12 format

2010-07-12 Thread Gwenole Beauchesne
Hi, This patches fixes YV12 format for vaGetImage(). The components need to follow the VA image order whereas source is always I420. This reminds me the function ought to be called get_image_i420(). Regards, Gwenole. 0402-G45-Fix-vaGetImage-for-YV12-format.patch Description: Binary data

[Libva] [PATCH][G45][2/4] Simplify vaGetImage()

2010-07-12 Thread Gwenole Beauchesne
Hi, This patch factors out code for get_image_{yv12,nv12}(). A new memcpy_pic() function is introduced and the net result is fewer source code lines. Regards, Gwenole. 0401-G45-Simplify-vaGetImage.patch Description: Binary data ___ Libva mail

[Libva] [PATCH][G45][1/4] Fix vaGetImage() to commit pending commands to the HW

2010-07-12 Thread Gwenole Beauchesne
Hi, This patch flushes the batchbuffer prior to reading pixels from the VA surface. This actually fixes vaGetImage() with MPEG-2 decoded surfaces in I420 format. Regards, Gwenole. 0400-G45-Fix-vaGetImage-to-wait-for-pending-operations-to.patch Description: Binary data _

[Libva] [PATCH][G45][0/4] vaGetImage() fixes

2010-07-12 Thread Gwenole Beauchesne
Hi, Here is a new series of patches, that assumes the NV12 format patch is applied first. intel_batchbuffer_flush() is now called in vaGetImage() to commit the pending commands. After this series, VLC works correctly with both MPEG-2 and H.264 videos. Also tested with hwdecode-demos -- get

Re: [Libva] [PATCH] Fix detection of ATI driver (fglrx) (round 2)

2010-07-12 Thread Gwenole Beauchesne
Hi, On Sun, 11 Jul 2010, Gwenole Beauchesne wrote: This patch fixes detection of the ATI fglrx driver. They decided to mess around with their own version of libdrm, so we no longer can rely on the system library to find it out. Besides, the ATIFGLEXTENSION I used before is obsolete and ADL (A

Re: [Libva] [PATCH][G45][07/10] Add NV12 image format

2010-07-12 Thread Gwenole Beauchesne
Hi, On Mon, 12 Jul 2010, Xiang, Haihao wrote: Note: it should be possible to write an NV12->I420 shader program for non H.264 surfaces, but I don't know how. :) So, I am currently returning an error if the source surface is not used for H.264 decoding. Failed to apply this patch. New patch

Re: [Libva] [PATCH][G45] Fix vaGetImage() bounds checking code

2010-07-12 Thread Xiang, Haihao
On Mon, 2010-07-12 at 14:39 +0800, Gwenole Beauchesne wrote: > Hi, > > This patch fixes some bounds checking logic. I could cope with out-of- > bounds by modying the local `rect' accordingly but I prefer returning > an error because this generally implies an application programming > error. >

Re: [Libva] [PATCH][G45][10/10] Move initialization of render_state->interleaved_uv to vaCreateContext()

2010-07-12 Thread Xiang, Haihao
On Mon, 2010-07-12 at 14:22 +0800, Gwenole Beauchesne wrote: > Hi, > > Le 12 juil. 10 à 07:56, Xiang, Haihao a écrit : > > > On Sun, 2010-07-11 at 23:58 +0800, Gwenole Beauchesne wrote: > >> Hi, > >> > >> This patches move initialization of render_state->interleaved_uv > >> earlier, e.g. in vaCre

Re: [Libva] [PATCH][G45][08/10] Fix out-of-source builds

2010-07-12 Thread Xiang, Haihao
On Mon, 2010-07-12 at 14:21 +0800, Gwenole Beauchesne wrote: > Le 12 juil. 10 à 07:55, Xiang, Haihao a écrit : > > >> This patch fixes libva build with --enable-i965-driver in another > >> directory than the source directory. > >> > > Failed to apply this patch. > > New patch attached. Thanks. Ap

Re: [Libva] [PATCH][G45][06/10] Add I420 image format

2010-07-12 Thread Xiang, Haihao
On Mon, 2010-07-12 at 14:20 +0800, Gwenole Beauchesne wrote: > Le 12 juil. 10 à 07:52, Xiang, Haihao a écrit : > > >> This patch adds I420 image format. This actually is the native > >> surface > >> format for MPEG-2 decoding. > >> > > Fail to apply this patch. > > New patch attached. Thanks. A

Re: [Libva] [PATCH][G45][07/10] Add NV12 image format

2010-07-12 Thread Xiang, Haihao
On Mon, 2010-07-12 at 14:21 +0800, Gwenole Beauchesne wrote: > Le 12 juil. 10 à 07:54, Xiang, Haihao a écrit : > > >> This patch adds NV12 image format. This is the native surface format > >> for H.264 decoding. Tested with VLC. > >> > >> Note: it should be possible to write an NV12->I420 shader p