mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:27:44 +00:00
LibSoftGPU: Allow arbitrary render target sizes
With the RASTERIZER_BLOCK_SIZE gone we can now render to any size, even odd ones. We have to be careful to not generate out of bounds accesses when calculating the render target and depth buffer pointers. Thus we check the coverage mask and generate nullptrs for pixels that will not be updated. This also masks out pixels that would touch the triangle but are outside the render target/scissor rect bounds.
This commit is contained in:
parent
21cad22535
commit
57215d0e1f
2 changed files with 27 additions and 37 deletions
|
@ -15,7 +15,6 @@
|
|||
namespace SoftGPU {
|
||||
|
||||
static constexpr bool ENABLE_STATISTICS_OVERLAY = false;
|
||||
static constexpr int RASTERIZER_BLOCK_SIZE = 8;
|
||||
static constexpr int NUM_SAMPLERS = 32;
|
||||
static constexpr int SUBPIXEL_BITS = 5;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue