mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-12 03:58:55 +01:00
testing: Bug fix: Wrong attribute variables
This commit is contained in:
parent
6dc74d308b
commit
caad187cd3
@ -180,7 +180,7 @@ var (
|
|||||||
Exprs: []shaderir.Expr{
|
Exprs: []shaderir.Expr{
|
||||||
{
|
{
|
||||||
Type: shaderir.LocalVariable,
|
Type: shaderir.LocalVariable,
|
||||||
Index: 5, // the varying variable
|
Index: 4, // the varying variable
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Type: shaderir.LocalVariable,
|
Type: shaderir.LocalVariable,
|
||||||
@ -193,7 +193,7 @@ var (
|
|||||||
Exprs: []shaderir.Expr{
|
Exprs: []shaderir.Expr{
|
||||||
{
|
{
|
||||||
Type: shaderir.LocalVariable,
|
Type: shaderir.LocalVariable,
|
||||||
Index: 4, // gl_Position in GLSL
|
Index: 3, // gl_Position in GLSL
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
Type: shaderir.Binary,
|
Type: shaderir.Binary,
|
||||||
@ -216,7 +216,6 @@ func defaultProgram() shaderir.Program {
|
|||||||
{Main: shaderir.Vec2}, // Local var (0) in the vertex shader
|
{Main: shaderir.Vec2}, // Local var (0) in the vertex shader
|
||||||
{Main: shaderir.Vec2}, // Local var (1) in the vertex shader
|
{Main: shaderir.Vec2}, // Local var (1) in the vertex shader
|
||||||
{Main: shaderir.Vec4}, // Local var (2) in the vertex shader
|
{Main: shaderir.Vec4}, // Local var (2) in the vertex shader
|
||||||
{Main: shaderir.Vec4}, // Local var (3) in the vertex shader
|
|
||||||
},
|
},
|
||||||
Varyings: []shaderir.Type{
|
Varyings: []shaderir.Type{
|
||||||
{Main: shaderir.Vec2}, // Local var (4) in the vertex shader, (1) in the fragment shader
|
{Main: shaderir.Vec2}, // Local var (4) in the vertex shader, (1) in the fragment shader
|
||||||
@ -305,8 +304,6 @@ func ShaderProgramFill(r, g, b, a byte) shaderir.Program {
|
|||||||
//
|
//
|
||||||
// 0: the framebuffer size (Vec2)
|
// 0: the framebuffer size (Vec2)
|
||||||
//
|
//
|
||||||
// The first image's size and region are represented in attribute variables.
|
|
||||||
//
|
|
||||||
// The size and region values are actually not used in this shader so far.
|
// The size and region values are actually not used in this shader so far.
|
||||||
func ShaderProgramImages(imageNum int) shaderir.Program {
|
func ShaderProgramImages(imageNum int) shaderir.Program {
|
||||||
if imageNum <= 0 {
|
if imageNum <= 0 {
|
||||||
|
Loading…
Reference in New Issue
Block a user