Skip to content

Mirrored/inverted coordinates using PGraphics and LiveWallpaper #357

Closed
@danieltorrer

Description

@danieltorrer

I came across a a bug in Live Wallpaper mode:

If you use PGraphics and draw it using image the result is a image with the coordinates mirrored.

Code:

PGraphics canvas;

void setup() {
  //fullScreen(P3D);
  size(540, 960, P3D);
  canvas = createGraphics(width/2, height/2, P3D);
}

void draw() {
  background(#D403FF);
  
  canvas.beginDraw();
  canvas.background(#36FFCB);
  canvas.sphere(100);
  //canvas.ellipse( 30, 30, 100, 100);
  canvas.endDraw();
  
  image(canvas, 50, 50);
}

Using Java Mode (default) :
Imgur

Live Wallpaper:
Imgur

Processing: 3.3.5
Processing-android: 4.0-beta9 (Android Mode 0262)
OS X: 10.10.5
Android: 6.0.1 (Tested in a MotoX Play and a Alcatel Pop 4 Plus)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions