[FFmpeg-devel] [PATCH] avutil/hwcontext_d3d11va: enable D3D11_RESOURCE_MISC_SHARED for texture

Wu, Tong1 tong1.wu at intel.com
Wed Apr 20 10:42:50 EEST 2022



> -----Original Message-----
> From: ffmpeg-devel <ffmpeg-devel-bounces at ffmpeg.org> On Behalf Of
> Hendrik Leppkes
> Sent: Wednesday, April 20, 2022 2:35 PM
> To: FFmpeg development discussions and patches <ffmpeg-
> devel at ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH] avutil/hwcontext_d3d11va: enable
> D3D11_RESOURCE_MISC_SHARED for texture
> 
> On Wed, Apr 20, 2022 at 6:11 AM Tong Wu
> <tong1.wu-at-intel.com at ffmpeg.org> wrote:
> >
> > Add D3D11_RESOURCE_MISC_SHARED flag for texture to make it shareable.
> > This can fix the green frames issue when mapping from d3d11va to opencl.
> > Sample command line: ffmpeg.exe -hwaccel d3d11va
> > -hwaccel_output_format
> > d3d11 -i input.264 -vf
> > "hwmap=derive_device=opencl,format=opencl,hwdownload,format=nv12"
> -c:v
> > libx264 output.mp4
> >
> 
> The flags are configurable, we should not force them for specific cases.
> Specifically, there is also two ways to share a texture, this flag and the
> D3D11_RESOURCE_MISC_SHARED_NTHANDLE flag (which is preferable for
> new code), which would conflict with each other, making it impossible to set
> it.
> 

Thanks for the review. Since the flags should not be set for those specific cases
like that, is there any feasible way to enable the share resource between d3d11 
and opencl and make the sample command line work?

> - Hendrik
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email ffmpeg-devel-request at ffmpeg.org
> with subject "unsubscribe".


More information about the ffmpeg-devel mailing list