This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

[HELP] Add more option To FSRCNNX
#2
Hybrid uses GLS resizing by using vs-placebo (https://github.com/Lypheo/vs-placebo) which has the following option in regard to using shaders:
placebo.Shader(clip clip, [string shader, int width, int height, int chroma_loc = 1, int matrix = 2, int trc = 1, string filter = "ewa_lanczos", float radius, float clamp, float taper, float blur, float param1, float param2, float antiring = 0.0, int lut_entries = 64, float cutoff = 0.001, bool sigmoidize = 1, bool linearize = 1, float sigmoid_center = 0.75, float sigmoid_slope = 6.5, string shader_s])
see: https://github.com/Lypheo/vs-placebo#pla...g-shader_s

The main part used during the resizing is:
# adjusting color space from YUV420P8 to YUV444P16 for VsGLSLResizer
clip = core.resize.Bicubic(clip=clip, format=vs.YUV444P16, range_s="limited")
# applying the shader
clip = core.placebo.Shader(clip=clip, shader="I:/Hybrid/64bit/vsfilters/ResizeFilter/GLSL/FSRCNNX_x2_8-0-4-1.glsl", width=1280, height=704)
core.std.LoadPlugin(path="I:/Hybrid/64bit/vsfilters/Support/libvs_placebo.dll")

In theory vs-placebo can probably be used to use other .glsl shaders in mpv syntax. I only tested a bunch of other shaders from Anime4k: https://github.com/bloc97/Anime4K/tree/master/glsl

But I have no clue what other shaders are out there an whether they could even be used using vs-placebo.
-> Without any details on what shader you want o apply to do what I can't really guess what you would need to write down in a custom section aside from:
core.std.LoadPlugin(path="I:/Hybrid/64bit/vsfilters/Support/libvs_placebo.dll") # only needed if the library isn't already loaded
clip = core.resize.Bicubic(clip=clip, format=vs.YUV444P16, range_s="limited") # this would need to be adjusted or left out to produce YUV44P16 from the current color space your script has at the point where the custom code gets applied.
# applying the shader
clip = core.placebo.Shader(clip=clip, shader=" PATH TO THE .glsl file", <whatever setting you placebo can/must send to your filter>)

Cu Selur
----
Dev versions are in the 'experimental'-folder of my GoogleDrive, which is linked on the download page.
Reply


Messages In This Thread
Add more option To FSRCNNX - by light - 25.02.2021, 16:03
RE: Add more option To FSRCNNX - by Selur - 25.02.2021, 17:03
RE: Add more option To FSRCNNX - by light - 25.02.2021, 19:30
RE: Add more option To FSRCNNX - by Selur - 25.02.2021, 19:33
RE: Add more option To FSRCNNX - by light - 25.02.2021, 19:37
RE: Add more option To FSRCNNX - by Selur - 25.02.2021, 20:01
RE: Add more option To FSRCNNX - by light - 25.02.2021, 20:22
RE: Add more option To FSRCNNX - by Selur - 25.02.2021, 20:33
RE: Add more option To FSRCNNX - by light - 25.02.2021, 20:54
RE: Add more option To FSRCNNX - by Selur - 25.02.2021, 20:51
RE: Add more option To FSRCNNX - by Selur - 25.02.2021, 21:14
RE: Add more option To FSRCNNX - by light - 25.02.2021, 21:16
RE: Add more option To FSRCNNX - by Selur - 26.02.2021, 06:14

Forum Jump:


Users browsing this thread: 1 Guest(s)