summaryrefslogtreecommitdiff
path: root/src/gallium/state_trackers/vdpau
AgeCommit message (Collapse)AuthorFilesLines
2014-02-14st/vdpau: add support for DEINTERLACE_TEMPORALGrigori Goronzy3-4/+73
Reviewed-by: Christian König <christian.koenig@amd.com>
2014-02-11st/vdpau: automake: export only PUBLIC symbolsEmil Velikov1-0/+1
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Matt Turner <mattst88@gmail.com> Reviewed-by: Christian König <christian.koenig@amd.com>
2014-02-11st/vdpau: do not export VdpPresentationQueueTargetCreateX11Emil Velikov2-2/+4
The function pointer is retrieved via VdpGetProcAddress just like all the other vdpau functions and should not be exported. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Matt Turner <mattst88@gmail.com> Reviewed-by: Christian König <christian.koenig@amd.com>
2014-02-06vdpau: flush the context before exporting the surface v2Marek Olšák1-0/+1
Bugzilla (bug needs XBMC changes as well): https://bugs.freedesktop.org/show_bug.cgi?id=73191 When VL uploads vertex buffers, it uses PIPE_TRANSFER_DONTBLOCK, which always flushes the context in the winsys if the buffer being mapped is busy. Since I added handling of DISCARD_RANGE, DONTBLOCK has had no effect when combined with DISCARD_RANGE and I think the context isn't flushed anywhere else, so no commands are submitted to the GPU until the IB is full, which takes a lot of frames. Using DISCARD_RANGE is not the only way to trigger this bug. The other way is to reallocate the vertex buffer before every upload. BTW, I'm not sure if this is the right place for flushing, but it does fix the bug. v2 (chk): move the flush to the right place. Signed-off-by: Christian König <christian.koenig@amd.com> Tested-by: StrangeNoises (rachel@strangenoises.org)
2014-02-06gallium: remove PIPE_USAGE_STATICMarek Olšák2-2/+2
Reviewed-by: Brian Paul <brianp@vmware.com>
2014-01-20st/vdpau: s/surface/resource/ to fix compiler warningBrian Paul1-1/+1
Reviewed-by: Christian König <christian.koenig@amd.com>
2014-01-19st/vdpau: check surface params before creating surfacesIlia Mirkin3-0/+21
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Christian König <christian.koenig@amd.com>
2014-01-19st/vdpau: fix bogus error handling in output/bitmap creationIlia Mirkin2-34/+35
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Christian König <christian.koenig@amd.com>
2014-01-19st/vdpau: don't return a device if the screen doesn't support NPOTIlia Mirkin1-0/+5
NV3x cards don't support NPOT textures. Technically this restriction could be worked around, but since it also doesn't expose any video decoding hw, just turn it off entirely. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Cc: 10.0 <mesa-stable@lists.freedesktop.org> Reviewed-by: Christian König <christian.koenig@amd.com>
2014-01-17s/Tungsten Graphics/VMware/José Fonseca12-12/+12
Tungsten Graphics Inc. was acquired by VMware Inc. in 2008. Leaving the old copyright name is creating unnecessary confusion, hence this change. This was the sed script I used: $ cat tg2vmw.sed # Run as: # # git reset --hard HEAD && find include scons src -type f -not -name 'sed*' -print0 | xargs -0 sed -i -f tg2vmw.sed # # Rename copyrights s/Tungsten Gra\(ph\|hp\)ics,\? [iI]nc\.\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./g /Copyright/s/Tungsten Graphics\(,\? [iI]nc\.\)\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./ s/TUNGSTEN GRAPHICS/VMWARE/g # Rename emails s/alanh@tungstengraphics.com/alanh@vmware.com/ s/jens@tungstengraphics.com/jowen@vmware.com/g s/jrfonseca-at-tungstengraphics-dot-com/jfonseca-at-vmware-dot-com/ s/jrfonseca\?@tungstengraphics.com/jfonseca@vmware.com/g s/keithw\?@tungstengraphics.com/keithw@vmware.com/g s/michel@tungstengraphics.com/daenzer@vmware.com/g s/thomas-at-tungstengraphics-dot-com/thellstom-at-vmware-dot-com/ s/zack@tungstengraphics.com/zackr@vmware.com/ # Remove dead links s@Tungsten Graphics (http://www.tungstengraphics.com)@Tungsten Graphics@g # C string src/gallium/state_trackers/vega/api_misc.c s/"Tungsten Graphics, Inc"/"VMware, Inc"/ Reviewed-by: Brian Paul <brianp@vmware.com>
2013-12-23st/vdpau: Destroy context when initialization failsAaron Watry1-0/+1
Prevents a potential memory leak found when tracking down something else. Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Tom Stellard <thomas.stellard@amd.com> CC: "10.0" <mesa-stable@lists.freedesktop.org>
2013-12-13swrast* (gallium, classic): add MESA_copy_sub_buffer support (v3)Dave Airlie1-1/+1
This patches add MESA_copy_sub_buffer support to the dri sw loader and then to gallium state tracker, llvmpipe, softpipe and other bits. It reuses the dri1 driver extension interface, and it updates the swrast loader interface for a new putimage which can take a stride. I've tested this with gnome-shell with a cogl hacked to reenable sub copies for llvmpipe and the one piglit test. I could probably split this patch up as well. v2: pass a pipe_box, to reduce the entrypoints, as per Jose's review, add to p_screen doc comments. v3: finish off winsys interfaces, add swrast classic support as well. Reviewed-by: Jose Fonseca <jfonseca@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com> swrast: add support for copy_sub_buffer
2013-11-06st/vdpau: resolve delayed rendering for GL interop v2Grigori Goronzy1-0/+4
Otherwise OutputSurface interop has funny results sometimes. This fixes interop with the mpv media player. v2 (chk): add proper locking Signed-off-by: Christian König <christian.koenig@amd.com>
2013-10-28vl/h264: split fields into SPS/PPSChristian König1-21/+26
Add alot of missing fields as well. Signed-off-by: Christian König <christian.koenig@amd.com>
2013-10-26implement NV_vdpau_interop v7Christian König4-8/+61
v2: Actually implement interop between the gallium state tracker and the VDPAU backend. v3: Make it also available in non legacy contexts, fix video buffer sharing. v4: deny interop if we don't have the same screen object v5: rebased on upstream changes v6: implemented VDPAUGetSurfaceivNV, improved error handling, unregister all surfaces in VDPAUFiniNV v7: squash merge with Mareks changes Signed-off-by: Christian König <christian.koenig@amd.com>
2013-10-13st/vdpau: add format conversions for GetBitsYCbCrGrigori Goronzy1-8/+117
Add simple plain C routines for NV12<->YV12 and YUYV<->UYVY conversions. The NV12->YV12 conversion is commonly used, for instance by VLC. Reviewed-by: Christian König <christian.koenig@amd.com>
2013-10-09st/vdpau: really block until surface is idleGrigori Goronzy1-1/+2
pipe_screen::fence_finish with zero timeout returns quickly and doesn't wait at all. Fix that, and also delete the fence afterwards, so that QuerySurfaceStatus returns the right state later. Addresses: https://trac.videolan.org/vlc/ticket/9281 https://bugs.freedesktop.org/show_bug.cgi?id=68792 Reviewed-by: Christian König <christian.koenig@amd.com>
2013-10-09st/vdpau: add new formats to OutputSurface renderingGrigori Goronzy2-1/+24
OutputSurfaces have simple YCbCr rendering functionality built in, but so far only 4:2:0 subsampling worked correctly. This fixes 4:2:2 and 4:4:4 formats. Reviewed-by: Christian König <christian.koenig@amd.com>
2013-10-09st/vdpau: fix GenerateCSCMatrix with NULL procampGrigori Goronzy1-9/+12
As per API specification, it is legal to supply a NULL procamp. In this case, a CSC matrix according to the colorspace should be generated, but no further adjustments are made. Addresses: https://trac.videolan.org/vlc/ticket/9281 https://bugs.freedesktop.org/show_bug.cgi?id=68792 Reviewed-by: Christian König <christian.koenig@amd.com>
2013-10-01st/vdpau: consolidate C sources list into Makefile.sourcesEmil Velikov2-12/+14
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Tom Stellard <thomas.stellard@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
2013-09-30st/vdpau: Include u_surface.h for u_copy_rect.Vinson Lee2-0/+2
Fix build errors. CC surface.lo surface.c: In function 'vlVdpVideoSurfaceGetBitsYCbCr': surface.c:247:10: error: implicit declaration of function 'util_copy_rect' [-Werror=implicit-function-declaration] CC output.lo output.c: In function 'vlVdpOutputSurfaceGetBitsNative': output.c:216:4: error: implicit declaration of function 'util_copy_rect' [-Werror=implicit-function-declaration] Signed-off-by: Vinson Lee <vlee@freedesktop.org>
2013-09-30st/vdpau: Include u_format.h for util_format_description.Vinson Lee1-0/+1
Fix build error. CC device.lo device.c: In function 'vlVdpDefaultSamplerViewTemplate': device.c:251:4: error: implicit declaration of function 'util_format_description' [-Werror=implicit-function-declaration] device.c:251:9: warning: assignment makes pointer from integer without a cast [enabled by default] device.c:252:12: error: dereferencing pointer to incomplete type device.c:252:28: error: 'UTIL_FORMAT_SWIZZLE_0' undeclared (first use in this function) device.c:252:28: note: each undeclared identifier is reported only once for each function it appears in device.c:254:12: error: dereferencing pointer to incomplete type device.c:256:12: error: dereferencing pointer to incomplete type device.c:258:12: error: dereferencing pointer to incomplete type Signed-off-by: Vinson Lee <vlee@freedesktop.org>
2013-09-25st/vdpau: use a separate lock per decoderChristian König2-9/+12
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-09-25st/vdpau: use new vlc function to serach for VC-1 start codesChristian König1-2/+1
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-09-15vdpau/decode: Check max width and max height.Rico Schüller1-0/+20
Reviewed-by: Christian König <christian.koenig@amd.com>
2013-08-21vdpau/decode: Fix comment.Rico Schüller1-1/+1
Reviewed-by: Christian König <christian.koenig@amd.com>
2013-08-21vl/query: Only support VDP_CHROMA_TYPE_420 for 12 bit formats.Rico Schüller1-1/+6
Reviewed-by: Christian König <christian.koenig@amd.com>
2013-08-19st/vdpau: drop unnecessary variable profEmil Velikov2-6/+8
Any decent compiler will do this for us, although doing this will make grepping through the code alot easier. v2: In both mixer and query interface v3: rebase Reviewed-by: Christian König <christian.koenig@amd.com> [v1] Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2013-08-19st/vdpau: don't try to create video buffer when the format is FORMAT_NONEEmil Velikov1-1/+4
Not seen in the wild yet, but seems like a reasonable thing to do. [suggested by Christian] Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Christian König <christian.koenig@amd.com>
2013-08-19vdpau/vl 422 chroma width/height mix upAndy Furniss1-1/+1
I was looking into some minor 422 issues/discrepencies I noticed long ago using vdpau on my rv790. I noticed that there is code that is halving height rather than width - 422 is full height AFAIK. Making the changes below doesn't actually make any noticable difference to what I was looking into. Maybe there are more but here's three I've found so far Reviewed-by: Christian König <christian.koenig@amd.com>
2013-08-19vl: add entrypoint to is_video_format_supportedChristian König2-3/+6
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-08-19vl: add entrypoint to get_video_paramChristian König4-12/+25
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-08-19vl: rename pipe_video_decoder to pipe_video_codecChristian König2-5/+5
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-08-19vl: rename enum pipe_video_codec to pipe_video_formatChristian König1-4/+4
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-08-19vl: use a template for create_video_decoderChristian König1-12/+11
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-08-14vl: Add support for max level query v2Rico Schüller1-2/+2
This patch adds the level query support to the video decoders and uses some more reasonable defaults. v2: (ck) add commit message Reviewed-by: Christian König <christian.koenig@amd.com>
2013-05-27st/vdpau: destroy handle table only when it's emptyChristian König1-1/+1
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-05-27st/vdpau: remove vlCreateHTAB from surface functionsChristian König1-9/+0
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-05-27st/vdpau: invalidate the handles on destructionChristian König3-0/+4
Fixes a problem with xbmc when switching channels. Signed-off-by: Christian König <christian.koenig@amd.com>
2013-05-14vl/vdpau: fix PresentationQueueQuerySurfaceStatusChristian König2-17/+19
The last queued surface always keeps displaying. Fixing a problem with XBMC. Signed-off-by: Christian König <christian.koenig@amd.com>
2013-05-01st/vdpau: fix background handling in the mixerChristian König1-9/+10
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-05-01vl/buffer: use 2D_ARRAY instead of 3D texturesChristian König1-4/+4
Signed-off-by: Christian König <christian.koenig@amd.com>
2013-05-01vl/compositor: cleanup background clearingChristian König4-11/+7
Add an extra parameter to specify if we should clear the render target. Signed-off-by: Christian König <christian.koenig@amd.com>
2013-04-09st/vdpau: fix subtitle related bug v2Christian König1-0/+4
Drawing subtitles didn't increased the dirty area of the surface. Reported and tested by freeedrich on irc. v2: don't clear the surface Signed-off-by: Christian König <christian.koenig@amd.com>
2013-02-22st/vdpau: Fix memory leak in vlVdpBitmapSurfaceCreate.Vinson Lee1-0/+1
Fixes resource leak defect reported by Coverity. Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Christian König <christian.koenig@amd.com>
2013-02-22st/vdpau: Fix memory leak in vlVdpOutputSurfaceCreate.Vinson Lee1-0/+1
Fixes resource leak defect reported by Coverity. Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Christian König <christian.koenig@amd.com>
2013-01-13Remove hacks for static MakefilesMatt Turner1-6/+0
v2: Andreas Boll <andreas.boll.dev@gmail.com> - don't remove compatibility with scripts for the old build system v3: Andreas Boll <andreas.boll.dev@gmail.com> - remove more obsolete hacks v4: Andreas Boll <andreas.boll.dev@gmail.com> - add a previously removed TOP variable to fix vgapi build
2013-01-10Clean up .gitignore filesMatt Turner1-1/+0
2013-01-10state_trackers/vdpau: Convert to automakeMatt Turner3-26/+56
2013-01-04gallium: extend pipe_context::flush for it to accept an END_OF_FRAME flagMarek Olšák2-2/+2
Usage with pipe_context: pipe->flush(pipe, NULL, PIPE_FLUSH_END_OF_FRAME); Usage with st_context_iface: st->flush(st, ST_FLUSH_END_OF_FRAME, NULL); The flag is only a hint for drivers. Radeon will use it for buffer eviction heuristics in the kernel (e.g. for queries like how many frames have passed since a buffer was used). The flag is currently only generated by st/dri on SwapBuffers. Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>