Open GoogleCodeExporter opened 9 years ago
The little guy and the coins are drawn directly as images, thus not affected by
the bug
Original comment by alexande...@gmail.com
on 17 Jul 2012 at 9:09
It works in the SurfaceTest in playn/tests/core. Can you try running that app
on your device and see if the surface tests shows a pattern or shows garbage?
final Pattern pattern = assets().getImage("images/tile.png").toPattern();
addTest("fillRect/Triangles with pattern", 180, 10, 120, 220, new ImmediateLayer.Renderer() {
public void render (Surface surf) {
// fill some shapes with patterns
surf.setFillPattern(pattern).fillRect(10, 0, 100, 100);
// use same fill pattern for the triangles
surf.translate(0, 160);
surf.fillTriangles(verts, indices);
}
});
Or perhaps you're rendering to an off-screen buffer rather than to the main
framebuffer?
Original comment by m...@samskivert.com
on 17 Jul 2012 at 7:45
There was a bug if you tiled a non-power-of-two image to a surface. That bug is
fixed in trunk, if you want to give that a shot and see if it works. Though the
bug was such that it should have failed in the Java backend as well, so I'm not
sure whether this is your issue.
Original comment by m...@samskivert.com
on 17 Jul 2012 at 8:16
The difference between the test and my case is that I am using a clipped
immediate layer. This make all the difference.
Original comment by alexande...@gmail.com
on 18 Jul 2012 at 5:00
Changing the test to a clipped layer breaks the test as well...
Original comment by alexande...@gmail.com
on 18 Jul 2012 at 5:15
I added a test that fills a pattern inside a clipped immediate layer and it
works fine on my Android device (with my latest fix). Try the latest code in
trunk and see if it solves your problem.
If it doesn't, then this is a ICS versus JellyBean problem.
Original comment by m...@samskivert.com
on 18 Jul 2012 at 4:22
I still have problems with this, same issue. Did you try this on Galaxy Nexus
or another ICS device?
Original comment by alexande...@gmail.com
on 19 Jul 2012 at 4:23
Original issue reported on code.google.com by
alexande...@gmail.com
on 17 Jul 2012 at 9:09Attachments: