the Twarchive

This is a record of a twitter thread, originally posted in 2018

Thew
@AmazingThew

More progress on realtime X-ray simulation shaders for @LevelExGameDev

Much better math + real-world units and constants; to the *current* extent of my knowledge this is (mostly) physically correct for human bone and a 70KeV X-ray source

Thew
@AmazingThew

Also added a very aggressive high-pass filter, which results in the characteristic sharpening/fringing artifacts around edges

Real machines also do this, but I don't have numbers for frequency ranges etc so this is just eyeballed based on reference images right now

Thew
@AmazingThew

Also the mapping from "voltage striking detector" to "pixel intensity on a monitor" is just linear right now, and I suspect real machines do a great deal of curving/processing at this stage. Haven't found real numbers to work with yet though