internal/grphicsdriver/opengl: bug fix: wrong consntant was used for blend operations

Updates #2382
This commit is contained in:
Hajime Hoshi 2022-10-17 00:21:08 +09:00
parent b79495761e
commit 06c53c1445

View File

@ -36,7 +36,7 @@ const (
type blendOperation int
const (
glAdd blendOperation = 0x104
glFuncAdd blendOperation = 0x8006
)
func convertBlendFactor(f graphicsdriver.BlendFactor) blendFactor {
@ -63,7 +63,7 @@ func convertBlendFactor(f graphicsdriver.BlendFactor) blendFactor {
func convertBlendOperation(o graphicsdriver.BlendOperation) blendOperation {
switch o {
case graphicsdriver.BlendOperationAdd:
return glAdd
return glFuncAdd
default:
panic(fmt.Sprintf("opengl: invalid blend operation %d", o))
}