Profile picture
Thew @AmazingThew
, 8 tweets, 2 min read Read on Twitter
Still working on X-ray sim shaders at @LevelExGameDev

Got variable beam energy working and it's pretty neat to see how it affects the image:
Ignore the extremely placeholder lungs lol

The actual anatomy is fairly approximate right now (bone has no marrow, heart is just a solid mass of muscle without internal details), but the materials and their interaction with the X-rays are real values: physics.nist.gov/PhysRefData/Xr…
Thing I have learned: At lower energies, material density is the main factor in X-ray attenuation, but at higher energies the rays are more heavily scattered, so eventually scattering outpaces absorption and materials start to all look the same
Thus on the left, the spine is darker than the heart and diaphragm, because it's much denser, but on the right the two materials have much more similar attenuation, and thus the heart appears darker than bone because it's physically larger
To be clear: There are a LOT of other factors at play here. As I mentioned the anatomy itself is approximate, and tonemapping from voltages to LDR pixels is ENTIRELY subjective and user-controlled

but it's really neat to see the math actually work out like the textbooks said
(also credit to @artofblake for the geometry here. It's still very WIP in case anyone with a medical background sees it and gets mad at us for weird lungs and missing muscles lol)
The cool thing with this X-ray stuff is it's still just radiation, which means it follows the exact same rules as visible light from a rendering standpoint. Reflection, absorption, scatter

They just don't really reflect off of much, so we make images by casting shadows with them
You shine X-ray light on a person, put a detector plate on the other side, and look at the shadow. Thus, simulating fluoroscopy on a GPU is the same problem as rendering shadows through participating media. Visible light passing through volumetric smoke etc
Missing some Tweet in this thread?
You can try to force a refresh.

Like this thread? Get email updates or save it to PDF!

Subscribe to Thew
Profile picture

Get real-time email alerts when new unrolls are available from this author!

This content may be removed anytime!

Twitter may remove this content at anytime, convert it as a PDF, save and print for later use!

Try unrolling a thread yourself!

how to unroll video

1) Follow Thread Reader App on Twitter so you can easily mention us!

2) Go to a Twitter thread (series of Tweets by the same owner) and mention us with a keyword "unroll" @threadreaderapp unroll

You can practice here first or read more on our help page!

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just three indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member and get exclusive features!

Premium member ($3.00/month or $30.00/year)

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!