We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Hmm. I'm trying to save a PGraphics object as a PNG file, which I am rendering as a PDF. But when I try the usual pg.save("output.png")
it throws an error: "No save() for PGraphicsPDF"
.
Another try, but also doesn't work: PImage img = pg.get()
throws the error "No get() for PGraphicsPDF"
. A search of the PGraphics listing in the Javadoc didn't turn anything up.
Help?
Answers
Whoa, forum auto-posting freakout - sorry for the double post!
PDF records what's being rendered on-the-fly via beginRecord() & endRecord().
Then saves it to a pre-defined file. Below's a simple example:
GoToLoop, I fear that again you throw in hastily some code not directly related to the question.
Here is one way to draw in two different PGraphics: