[Mesa-dev] RFC: Fixing XBMC crash with NV_vdpau_interop

Brian Paul brian.e.paul at gmail.com
Sat Mar 22 15:33:48 PDT 2014


On Sat, Mar 22, 2014 at 2:49 PM, Christian König <deathsimple at vodafone.de>wrote:

> Hi guys,
>
> recently some XBMC users complained about crashes with the relatively new
> NV_vdpau_interop support.
>
> That turned out to be a problem with how st_atom_texture.c caches the
> sampler view for a texture. Since the texture in question is shared between
> two GLX contexts the pipe object the sampler view was originally created
> for doesn't necessary match the pipe object it is used with.
>
> Now my question is am I missing something or is this case really not
> correctly supported? Where is the check if a texture is used in more than
> one context? The attached patch fixes the issue, but I'm not sure if it is
> the right approach.
>

I've run into this too.  I think the best thing to do (short of removing
the sampler view from the st_texture_object) is to walk over all the
textures in the share group at context-destroy time, looking for sampler
views belonging to the context being destroyed, then free those sampler
views.

I could probably whip up a patch next week.

-Brian
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20140322/2de37dd3/attachment.html>


More information about the mesa-dev mailing list