mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-27 03:02:49 +01:00
shaderir: Add StructMember
This commit is contained in:
parent
8a6140a92f
commit
dbbe4ee09c
@ -193,6 +193,8 @@ func (p *Program) glslBlock(b *Block, level int, localVarIndex int) []string {
|
|||||||
switch e.Variable.Type {
|
switch e.Variable.Type {
|
||||||
case Uniform:
|
case Uniform:
|
||||||
return fmt.Sprintf("U%d", e.Variable.Index)
|
return fmt.Sprintf("U%d", e.Variable.Index)
|
||||||
|
case StructMember:
|
||||||
|
return fmt.Sprintf("M%d", e.Variable.Index)
|
||||||
case Local:
|
case Local:
|
||||||
idx := e.Variable.Index
|
idx := e.Variable.Index
|
||||||
switch b {
|
switch b {
|
||||||
|
@ -119,6 +119,7 @@ type VariableType int
|
|||||||
|
|
||||||
const (
|
const (
|
||||||
Uniform VariableType = iota
|
Uniform VariableType = iota
|
||||||
|
StructMember
|
||||||
Local
|
Local
|
||||||
)
|
)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user