ebiten: Android GeoM transform issue on mobile phones with GPU Adreno 305
I was trying to setup a unscaled pixel fitted screen on mobile and saw a glitch. It should render a rotating pulsing image.
On Android there is a glitch:
On Desktop works as it should:
Project is here: https://github.com/egonelbre/ebiten-basic
It uses multiple transformations in a sequence and I think it is what why it’s wasn’t noticed before (https://github.com/egonelbre/ebiten-basic/blob/master/basic/single.go#L29):
op := &ebiten.DrawImageOptions{}
op.CompositeMode = ebiten.CompositeModeSourceOver
op.GeoM.Translate(imgsz.Scale(0.5).Neg().Float64())
op.GeoM.Rotate(float64(scene.Rotation))
op.GeoM.Scale(imgsz.Inv().Float64())
s := scene.Scale * 100
op.GeoM.Scale(float64(s), float64(s))
op.GeoM.Translate(frame.Screen.Size.Scale(0.5).Float64())
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 24 (24 by maintainers)
Commits related to this issue
- graphics: Bug fix: Wrong vertices values on ARM 32bit (#329) — committed to hajimehoshi/ebiten by hajimehoshi 7 years ago
- graphics: Remove nop: Use Go 1.8.1 (#329) — committed to hajimehoshi/ebiten by hajimehoshi 7 years ago
Reported https://github.com/golang/go/issues/19403
Great news: This can be reproduced on ZenFone Go!