Sharper mipmapping using shader based supersampling (2019)
bgolus.medium.com
bgolus.medium.com
One thing I think that’s under appreciated when people talk about blurriness and sharpness is that a slight amount of visible blurriness can be much better for the overall clarity of an image than erring on the side of sharpness. I learned this accidentally many years ago doing a Siggraph video on VHS tape, you know, with the old 480i 60 fields per second with alternating odd/even fields. Certainly there’s a little nuance there that is different than 1080p LCD pixels, but I found out that over-blurring a little vertically fixed all the interlace tearing and made the image so much more clear. A friend who’d written papers on antialiasing called me to ask how I’d done it, why it was so clear, and was as surprised as I was to hear that it was blurrier than expected. Ever since then whenever I see someone trying to squeeze the last bit of sharpness out of their filter, it almost always seem to come at the cost of seeing pixels and damaging clarity. Experts will say that a Gaussian filter is too soft and you can get sharper, but for high quality filtering, I haven’t found anything else that will reliably hide the pixels and leave you looking only at the image rather than the sampling.
> Warning: this page has about 72MB of Gifs! Medium also has a tendency to not load them properly, so if there’s a large gap or overly blurry image, try reloading the page. Ad blockers may cause problems, no script may make it better. It’s also broken in the official Medium app. Sorry, Medium is just weird.
There may be a fix: vote with your choice, stop publishing on Medium, publish elsewhere?
This content is worth it.
Engineer solution: Spend hours hacking a small amount of mip LOD biasing, and forcing anisotropic filtering on for that texture.
Designer solution: Lose the sign. Problem avoided, hours saved.
I would expect/hope that the designer asked both the artist and engineer if the sign could be fixed (and at what cost) before spending the time to re-design an alternative. Designers will often spend huge amounts of time doing tasks that could be greatly simplified if they only asked the relevant engineer (and vice-versa).
How much would it help?
There is probably some quality improvement, but there is a fairly large cost. Would be interesting to see what the results look like.
Hard to say how much it would help the visual quality, but it’s easy to calculate the costs, which are largely memory. A map map consumes 1/3rd more memory than a texture. If you add a 2nd set of points starting at 75% zoom, then I think (napkin math) it’ll bring your memory consumption closer to 2x the original texture. https://en.wikipedia.org/wiki/Mipmap#Mechanism
On a related note, there is a technique called summed area tables, which allows for the rapid evaluation of the total value of all pixels in any axis aligned rectangle, with only a few additions and subtractions. AFAIK this never really caught on though, because it required the storage of much larger numbers than GPU textures could historically support.
The point of selecting a higher definition video stream can be to circumvent bandwidth limitation, if the platform happens to compress too much what it sends by default.
Fortunately, that’s not how video players normally resize the videos they play. At the very least, players are using bilinear sampling. For the exact 50% downsampling of 4k into 1080p, this means the GPU averages 2x2 quad of the source video texture into one output pixel. This averaging step hides substantial amount of codec artifacts. That bilinear sampling is even borderline free on GPUs: they have tons of VRAM bandwidth, and texture samplers are dedicated fixed-function pieces of hardware.
If you’re using Windows and Media Player Classic, the player has a preference to switch resizing algorithm, Options, Playback, Output, “Resizer” combobox.
In a less imperfect world, if you're watching video on a 1080p display, watching a video that is encoded at 1080p will give you the best quality for any given bitrate in any given codec.
Ideally youtube would give three setting choices: codec, (ie, if your device supports decoding VP9 in hardware, it will do that, and fall back to successively worse codecs) resolution, and high quality vs low bandwidth. But that would mean 1) encoding every video twice as many times and using about twice as much total storage. I can understand why they've combined these two separate tunable settings into one resolution+quality knob.
They do separate out codec though; afaik most videos will be available in VP9, h265, and h264. Possibly others.