mirror of https://github.com/ErsatzTV/ErsatzTV.git
3 changed files with 24 additions and 7 deletions
@ -1,13 +1,16 @@ |
|||||||
|
using ErsatzTV.FFmpeg.Format; |
||||||
|
|
||||||
namespace ErsatzTV.FFmpeg.Filter.Vaapi; |
namespace ErsatzTV.FFmpeg.Filter.Vaapi; |
||||||
|
|
||||||
public class TonemapVaapiFilter(FFmpegState ffmpegState) : BaseFilter |
public class TonemapVaapiFilter(FFmpegState ffmpegState) : BaseFilter |
||||||
{ |
{ |
||||||
public override string Filter => |
public override string Filter => |
||||||
$"hwupload=derive_device=vaapi,hwmap=derive_device=opencl,tonemap_opencl=tonemap={ffmpegState.TonemapAlgorithm},hwmap=derive_device=vaapi:reverse=1"; |
$"hwupload=derive_device=vaapi,hwmap=derive_device=opencl,tonemap_opencl=tonemap={ffmpegState.TonemapAlgorithm},hwmap=derive_device=vaapi:reverse=1,scale_vaapi=format=p010le"; |
||||||
|
|
||||||
public override FrameState NextState(FrameState currentState) => |
public override FrameState NextState(FrameState currentState) => |
||||||
currentState with |
currentState with |
||||||
{ |
{ |
||||||
FrameDataLocation = FrameDataLocation.Hardware |
FrameDataLocation = FrameDataLocation.Hardware, |
||||||
|
PixelFormat = new PixelFormatVaapi(PixelFormat.YUV420P10LE) |
||||||
}; |
}; |
||||||
} |
} |
||||||
|
Loading…
Reference in new issue