removed the alpha tex clear
This commit is contained in:
parent
1b94cf0703
commit
7830bb2cc5
1 changed files with 6 additions and 4 deletions
|
@ -175,6 +175,12 @@ func (b *GoGLBackend) FillImageMask(style *backendbase.FillStyle, mask *image.Al
|
|||
off := y * mask.Stride
|
||||
gl.TexSubImage2D(gl.TEXTURE_2D, 0, 0, int32(alphaTexSize-1-y), int32(w), 1, gl.ALPHA, gl.UNSIGNED_BYTE, gl.Ptr(&mask.Pix[off]))
|
||||
}
|
||||
if h < alphaTexSize {
|
||||
gl.TexSubImage2D(gl.TEXTURE_2D, 0, 0, int32(alphaTexSize-1-h), int32(w), 1, gl.ALPHA, gl.UNSIGNED_BYTE, gl.Ptr(&zeroes[0]))
|
||||
}
|
||||
if w < alphaTexSize {
|
||||
gl.TexSubImage2D(gl.TEXTURE_2D, 0, int32(w), int32(alphaTexSize-1-h), 1, int32(h), gl.ALPHA, gl.UNSIGNED_BYTE, gl.Ptr(&zeroes[0]))
|
||||
}
|
||||
|
||||
if style.Blur > 0 {
|
||||
b.offscr1.alpha = true
|
||||
|
@ -215,10 +221,6 @@ func (b *GoGLBackend) FillImageMask(style *backendbase.FillStyle, mask *image.Al
|
|||
|
||||
gl.StencilFunc(gl.ALWAYS, 0, 0xFF)
|
||||
|
||||
for y := 0; y < h; y++ {
|
||||
gl.TexSubImage2D(gl.TEXTURE_2D, 0, 0, int32(alphaTexSize-1-y), int32(w), 1, gl.ALPHA, gl.UNSIGNED_BYTE, gl.Ptr(&zeroes[0]))
|
||||
}
|
||||
|
||||
gl.ActiveTexture(gl.TEXTURE0)
|
||||
|
||||
if style.Blur > 0 {
|
||||
|
|
Loading…
Reference in a new issue