Fixed magic number

This commit is contained in:
Zyko 2024-04-10 18:59:21 +02:00
parent 55f1a5d32e
commit c9eb30d66f
2 changed files with 2 additions and 1 deletions

View File

@ -23,6 +23,7 @@ const (
BLEND = 0x0BE2 BLEND = 0x0BE2
CLAMP_TO_EDGE = 0x812F CLAMP_TO_EDGE = 0x812F
COLOR_ATTACHMENT0 = 0x8CE0 COLOR_ATTACHMENT0 = 0x8CE0
COLOR_BUFFER_BIT = 0x4000
COMPILE_STATUS = 0x8B81 COMPILE_STATUS = 0x8B81
DECR_WRAP = 0x8508 DECR_WRAP = 0x8508
DEPTH24_STENCIL8 = 0x88F0 DEPTH24_STENCIL8 = 0x88F0

View File

@ -242,7 +242,7 @@ func (g *Graphics) DrawTriangles(dstIDs [graphics.ShaderDstImageCount]graphicsdr
// Reset color attachments // Reset color attachments
if s := g.context.ctx.CheckFramebufferStatus(gl.FRAMEBUFFER); s == gl.FRAMEBUFFER_COMPLETE { if s := g.context.ctx.CheckFramebufferStatus(gl.FRAMEBUFFER); s == gl.FRAMEBUFFER_COMPLETE {
g.context.ctx.Clear(16384 | gl.STENCIL_BUFFER_BIT) g.context.ctx.Clear(gl.COLOR_BUFFER_BIT | gl.STENCIL_BUFFER_BIT)
} }
for i, dst := range dsts { for i, dst := range dsts {
if dst == nil { if dst == nil {