mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-24 18:58:54 +01:00
parent
2453f8f0df
commit
47bfd0db9e
@ -20,7 +20,7 @@ import (
|
|||||||
"github.com/hajimehoshi/ebiten/v2/internal/graphicsdriver"
|
"github.com/hajimehoshi/ebiten/v2/internal/graphicsdriver"
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/graphicsdriver/metal/mtl"
|
"github.com/hajimehoshi/ebiten/v2/internal/graphicsdriver/metal/mtl"
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shaderir"
|
"github.com/hajimehoshi/ebiten/v2/internal/shaderir"
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/metal"
|
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/msl"
|
||||||
)
|
)
|
||||||
|
|
||||||
type shaderRpsKey struct {
|
type shaderRpsKey struct {
|
||||||
|
@ -26,7 +26,7 @@ import (
|
|||||||
|
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shader"
|
"github.com/hajimehoshi/ebiten/v2/internal/shader"
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/glsl"
|
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/glsl"
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/metal"
|
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/msl"
|
||||||
)
|
)
|
||||||
|
|
||||||
func glslVertexNormalize(str string) string {
|
func glslVertexNormalize(str string) string {
|
||||||
|
@ -20,7 +20,7 @@ import (
|
|||||||
|
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shaderir"
|
"github.com/hajimehoshi/ebiten/v2/internal/shaderir"
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/glsl"
|
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/glsl"
|
||||||
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/metal"
|
"github.com/hajimehoshi/ebiten/v2/internal/shaderir/msl"
|
||||||
)
|
)
|
||||||
|
|
||||||
func block(localVars []shaderir.Type, offset int, stmts ...shaderir.Stmt) *shaderir.Block {
|
func block(localVars []shaderir.Type, offset int, stmts ...shaderir.Stmt) *shaderir.Block {
|
||||||
|
@ -36,7 +36,7 @@ type compileContext struct {
|
|||||||
|
|
||||||
func (c *compileContext) structName(p *shaderir.Program, t *shaderir.Type) string {
|
func (c *compileContext) structName(p *shaderir.Program, t *shaderir.Type) string {
|
||||||
if t.Main != shaderir.Struct {
|
if t.Main != shaderir.Struct {
|
||||||
panic("metal: the given type at structName must be a struct")
|
panic("msl: the given type at structName must be a struct")
|
||||||
}
|
}
|
||||||
s := t.String()
|
s := t.String()
|
||||||
if n, ok := c.structNames[s]; ok {
|
if n, ok := c.structNames[s]; ok {
|
@ -30,7 +30,7 @@ func typeString(t *shaderir.Type, packed bool, ref bool) string {
|
|||||||
}
|
}
|
||||||
return t
|
return t
|
||||||
case shaderir.Struct:
|
case shaderir.Struct:
|
||||||
panic("metal: a struct is not implemented")
|
panic("msl: a struct is not implemented")
|
||||||
default:
|
default:
|
||||||
t := basicTypeString(t.Main, packed)
|
t := basicTypeString(t.Main, packed)
|
||||||
if ref {
|
if ref {
|
Loading…
Reference in New Issue
Block a user