What are differences between ZDoom's software rendering and the original rendering by ID software
-
prosto
- Posts: 4
- Joined: Thu Jan 16, 2025 8:47 pm
What are differences between ZDoom's software rendering and the original rendering by ID software
Hello. I'm curious, how different is ZDoom's family software rendering from the original rendering. I know that it doesn't have restrictions on PolyObjects that were in the original Hexen engine, I guess it also supports 3D floors, portals, voxels. So instead of BSP it uses a different sorting method? Does it use raycasting?
-
phantombeta
- Posts: 2215
- Joined: Thu May 02, 2013 1:27 am
- Operating System Version (Optional): Windows 10
- Graphics Processor: nVidia with Vulkan support
- Location: Brazil
Re: What are differences between ZDoom's software rendering and the original rendering by ID software
The rendering still works largely the same as the original one, just with features added on. The BSP is still fully used, and is in fact also used by the hardware rendering in GZDoom/UZDoom.
The polyobject rendering issues in Hexen were a restriction of how their BSP was handled by the engine, that was solved by handling said BSP in a different way.
I believe this involved handling their BSP dynamically and as a whole object, it uses something called "MiniBSP" internally. (Interestingly, this is also how Quake handles moving brushes, they're their own little BSPs embedded inside the level)
Portals aren't actually super special, rendering-wise. You just need to transform the rendering point based on the portal lines, and progress through the BSP as if it had started at the other end of the portal. This is also how it works in the hardware renderer. (There's actually a hacky trick to do visual-only portal in vanilla by editing the BSP nodes if I'm not mistaken)
The hard part of portals is handling them in the game code and having audio pass through them correctly.
Voxels are "bolted on" and rendered as a later pass just like sprites, if I recall correctly using the voxel code from Build.
The polyobject rendering issues in Hexen were a restriction of how their BSP was handled by the engine, that was solved by handling said BSP in a different way.
I believe this involved handling their BSP dynamically and as a whole object, it uses something called "MiniBSP" internally. (Interestingly, this is also how Quake handles moving brushes, they're their own little BSPs embedded inside the level)
Portals aren't actually super special, rendering-wise. You just need to transform the rendering point based on the portal lines, and progress through the BSP as if it had started at the other end of the portal. This is also how it works in the hardware renderer. (There's actually a hacky trick to do visual-only portal in vanilla by editing the BSP nodes if I'm not mistaken)
The hard part of portals is handling them in the game code and having audio pass through them correctly.
Voxels are "bolted on" and rendered as a later pass just like sprites, if I recall correctly using the voxel code from Build.
-
prosto
- Posts: 4
- Joined: Thu Jan 16, 2025 8:47 pm
Re: What are differences between ZDoom's software rendering and the original rendering by ID software
Hm, it's interesting. I didn't expect that the original code is used so extensively
> if I recall correctly using the voxel code from Build.
Less likely, because Build has non commercial pseudo open source license. I prefer calling such projects just closed source.
> if I recall correctly using the voxel code from Build.
Less likely, because Build has non commercial pseudo open source license. I prefer calling such projects just closed source.
-
Rachael
- Posts: 13988
- Joined: Tue Jan 13, 2004 1:31 pm
- Preferred Pronouns: She/Her
Re: What are differences between ZDoom's software rendering and the original rendering by ID software
An exception in the license was granted for that particular block of code.
-
Chris
- Posts: 3000
- Joined: Thu Jul 17, 2003 12:07 am
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
Re: What are differences between ZDoom's software rendering and the original rendering by ID software
Another notable difference is ZDoom can draw the HUD elements (player weapon sprites, status bar, and text) on a separate truecolor/32-bit color buffer, that's blended on top of the main scene. Original ZDoom would use DirectDraw to combine them, while GZDoom changed it to use OpenGL, which allowed non-paletted HUD elements and blending with the software renderer.