Closed cadin closed 6 years ago
Actually, I was wrong; autoClear(true)
and graphics().clear()
only seem to solve the issue if using a black fill. Running the same code above with a red fill still gives unexpected results in all cases.
This seems to be at least partially a problem with PGraphics itself in Processing 3.
This seems to be a Processing issue, not a Hype issue:
https://github.com/processing/processing/issues/3391
Thanks for reading!
When using
autoClear(false)
on HCanvas, HDrawables with an alpha set seem to display at about half of the specified alpha value.This simple sketch demonstrates the issue:
If you sample the rect color on screen you can see it's 25% gray instead of the expected 50%. Setting
autoClear(true)
works as expected.One workaround I found is to explicitly clear the PGraphics (see commented line above).
This wasn't a problem in Processing 2.x using the old PDE-based Hype. I've only noticed it since moving to Processing 3 and the lib-staging distro.
(I'm running Processing 3.3.7 on OS X)