summaryrefslogtreecommitdiff
path: root/src/sna/sna_video_sprite.c
AgeCommit message (Collapse)Author
2014-06-11sna: Silence compiler warnings for discarding const Region pointsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-04-29sna/video: Initialise pitch before queryChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-04-23sna/video: Show sprites across all outputsChris Wilson
If an overlay video (using the sprite interface) is visible on multiple outputs, we have to create and show a sprite for each. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=77802 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-04-18sna/video: Only try to set the color key onceChris Wilson
So that we only report the error to the user a single time, and not every frame. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-02-13sna: Extend native rotation support to spritesChris Wilson
The sprite plane can be independently rotated to the CRTC primary plane. To rotate the sprite plane, we just set a property on the plane similar to how we rotate the CRTC, so we can refactor them together to use the same routines. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-11-25sna: Handle failure to disable old plane when switching CRTCsZdenek Kabelac
If we fail to disable the old plane, abort the PutImage and report the error. Signed-off-by: Zdenek Kabelac <zkabelac@redhat.com>
2013-09-29sna/video: Don't allow caching of yuv scanoutsChris Wilson
We only want scanouts capable of being used for the front buffer in our cache, so make sure that YUV formatted fb are destroyed upon release. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-09-23sna/video: Add always-on-top to the list of Xv attributesChris Wilson
Otherwise it goes unknown, and not reported by xvinfo. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-27sna/video: Copy the ClipRegion for the spriteChris Wilson
A cut'n'paste error dropped the clip region copy, resulting in the port not being set on the window instead. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-27sna/video: Update sprite destination colorkey commandChris Wilson
The final version that was upstreamed differed from the original version we implemented. The final version allows for both destination/source colorkeying, but left the ddx out of date. Reported-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-25sna: Add a few more checks for a hosted Xserver before walking CRTC listsChris Wilson
If we are hosted, we do not own the CRTC configuration, and deferencing the private data structures believing them to be ours, only leads to disaster. Based on patches by Christopher James Halse Rogers. Reported-by: Christopher James Halse Rogers <raof@ubuntu.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-23sna/video: Disable the existing sprite when switching CRTCsChris Wilson
After starting a new video on another CRTC, disable the old one as we currently only track the single video port. However, showing a video split across multiple CRTCs would be a useful extension in the future. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-16sna/video: Turn off passthrough if given a zero nameChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-16sna/video: Keep a ref to the passthrough overlay boChris Wilson
Otherwise we will destroy it at the end of the frame whilst it is still meant to be shown. Not normally an issue as the next frame is show before it vanishes, but is if the image is shown for an extended period of time. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-16sna/video: Mark the sprite color key as changed when disablingChris Wilson
Otherwise we will forgot to send the command to turn off the colorkey. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-16sna/video: YUV420 is not supported by sprites, replace it with a RGB passthroughChris Wilson
As YUV420 is not supported by any of the current sprite implementations drop it. Instead implement some RGB passthroughs. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-16sna/video: Expose an attribute to keep the overlay always on topChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-16sna/video: Don't assert on a client error, return BadAllocChris Wilson
If the client sends a BO that is too small to satifsy the PutImage, then reject with BadAlloc rather than die with an assert. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-09intel: Disable incompatible features whilst hostedChris Wilson
Start adding the infrastructure to disable direct hardware access if X is being run under a system compositor (aka "hosted"). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-08-04sna/trapezoids: Some minor DBG to investigate threaded renderingChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-07-30Suppress a bunch of compiler warnings for using constant stringsChris Wilson
We want these allocated in ro memory even if the antique API complains. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-06-06sna/video: Fixup formats to select visualsChris Wilson
Fixes regression from commit 195a51353c3af7bd253227da5f759f06cea01f73 [2.21.8] Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue Apr 9 19:13:46 2013 +0100 sna/video: Convert to a pure Xv backend Reported-by: Edward Sheldrake <ejsheldrake@gmail.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=65479 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-05-21sna/video: Convert to a pure Xv backendChris Wilson
This is to enable feature work which requires access to Client state. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-04-09sna/video: Expand passthrough support for overlay planesChris Wilson
The passthrough is actually a generic, albeit private, mechanism that anything can use to pass along a GEM handle for use with Xv. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-12-18sna/video: Fix presentation of cropped spritesChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-12-09sna/sprite: Add a DBG to report whether the kernel supports spritesChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-11-30Convert generation counter to octalChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-11-12sna: Compile against ancient libdrmChris Wilson
We need to trim the sprite video overlays if the prototypes are not known. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-10-23sna: Only disallow hw sprite scaling on HaswellChris Wilson
Earlier chips (Ironlake, Sandybridge and Ivybridge) have integrated sprite scalers. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-10-17sna/overlay: Move bo out of GTT domain after binding to overlay planeChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-09-05sna/video: Use the scanout flag and FB id for sprite framebuffersChris Wilson
So that we can use the same teardown path as normal scanouts. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-07-14sna: Aim for consistency and use stdbool except for core X APIsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-07-09sna: Simplify the DBG incarnationChris Wilson
It was only ever used in conjunction with HAS_DEBUG_FULL. For debug purposes it is as easy to redefine DBG locally. By simplifying the DBG macro we can create it consistently and so reduce the number of compiler warnings. Long term, this has to be dynamic. Sigh. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-05-30sna/sprite: Restore another xf86drm.hChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-05-24Unify options handling between UXA and SNAEugeni Dodonov
Unifies available options for both UXA and SNA drivers, and moves them into a common header file, intel_opts.h. Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-04-14sna: Avoid leaking the plane resources when determining sprite planesChris Wilson
Fixes the tiny, one-off leak: ==1407== 8 bytes in 1 blocks are definitely lost in loss record 48 of 527 ==1407== at 0x402894D: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) ==1407== by 0x8580BE8: drmMalloc (xf86drm.c:147) ==1407== by 0x8583D54: drmAllocCpy (xf86drmMode.c:73) ==1407== by 0x8585265: drmModeGetPlaneResources (xf86drmMode.c:955) ==1407== by 0x8A1BCE9: sna_video_sprite_setup (sna_video_sprite.c:367) ==1407== by 0x8A1A0A3: sna_video_init (sna_video.c:523) ==1407== by 0x89FD4E0: sna_screen_init (sna_driver.c:935) ==1407== by 0x15AD80: AddScreen (dispatch.c:3909) ==1407== by 0x19A2DB: InitOutput (xf86Init.c:817) ==1407== by 0x14981C: main (main.c:204) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2012-03-28sna: Add video sprite support for ILK+Chris Wilson
Based on the work by Jesse Barnes. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>