Skip to content

Instantly share code, notes, and snippets.

@igv
igv / SSimDownscaler.glsl
Last active Jul 3, 2020
Tuned for use with dscale=mitchell and linear-downscaling=no. Localities are the main parameter to control sharpening strength, lower - sharper.
View SSimDownscaler.glsl
// SSimDownscaler by Shiandow
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 3.0 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
@kageru
kageru / README.md
Last active Jul 8, 2020
Standalone script using Vapoursynth to determine the original resolution of scaled images or videos.
View README.md

This version is deprecated

I’ve stopped updating this a while ago because some people made a proper respository with a few necessary fixes and changes. Just get this version from now on: https://github.com/Infiziert90/getnative

View kagefunc.py
"""
This project was moved to https://github.com/kageru/Irrational-Encoding-Wizardry.
Don't expect this gist to be updated regularly.
"""
import vapoursynth as vs
import mvsfunc as mvf
import fvsfunc as fvf
from functools import partial
@igv
igv / KrigBilateral.glsl
Last active Jun 21, 2020
Good test pattern: https://www.rtings.com/images/test-materials/2017/chroma-444.png (Compress it with any lossy codec first, for example jpeg. You can do it with mpv, only add screenshot-jpeg-source-chroma=no to mpv.conf). Usage: glsl-shader="~~/KrigBilateral.glsl"
View KrigBilateral.glsl
// KrigBilateral by Shiandow
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 3.0 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
@igv
igv / adaptive-sharpen.glsl
Last active Jul 13, 2020
Requires sigmoid-upscaling=no. To use it on-demand add the following line to input.conf: n change-list glsl-shaders toggle "~~/adaptive-sharpen.glsl"
View adaptive-sharpen.glsl
// Copyright (c) 2015-2018, bacondither
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions
// are met:
// 1. Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer
// in this position and unchanged.
// 2. Redistributions in binary form must reproduce the above copyright
You can’t perform that action at this time.