Saying that I think this is product is kinda dead on arrival.
420 karma · joined June 2, 2011
Saying that I think this is product is kinda dead on arrival.
- i = min(floor(f * 256), 255) (from float to uint8)
- f = i / 255 (from uint8 to float)
Basically a mix of the 2 approaches mentioned in the article.
For all integers between [0,255], if I do uint8 -> float -> uint8 conversion, I will get the same result.
--
edit: I wondered what's the maximum jitter amount that I can introduce to the float and get the same uint8 value. And also these 0->0.0 and 255->1.0 should map properly.
With my approach at the top, the jitter margin that I can introduce is 1/65280.
But with the article's approach
- i = floor(f * 255 + 0.5)
- f = i / 255
maximum jitter margin is 1/510 (which is better).
And I use Claude, Gemini, GLM, Qwen to double check my math, my code and to get practical information to make my path tracer more efficient. Claude and Gemini failed me more than a couple of times with wrong, misleading and unnecessary information but on the other hand Qwen always gave me proper, practical and correct information. I’ve almost stopped using Claude and Gemini to not to waste my time anymore.
Claude code may shine developing web applications, backends and simple games but it's definitely not for me. And this is the story of my specific use case.
Also I gave that blog post to Claude Code and asked to implement the API and it made terrible terrible mistakes. Just saying.
Also I can highly recommend using version managers (e.g. nvm, jenv, pyenv, gvm, etc..) for these languages to quickly install and manage different versions.
I'm using typst[1] for my writing journey.
But also I can also suggest another interesting option: GB Studio - https://www.gbstudio.dev It's a quick and easy to use drag and drop retro game creator for game boy. It also supports visual scripting.
I've started with the Vangoa EWI-100, which is an affordable, silent, and good enough MIDI EWI (electronic wind instrument) device. I have also been learning some of the technical details of MIDI. I sometimes use it alone, and sometimes with a Cocos Reaper with free VSTs. I have only been doing this for 4 days, but I am already enjoying it a lot.
If I continue to play it, most probably I will upgrade to a better EWI.