-
Bug
-
Resolution: Unresolved
-
P3
-
7u6, 8, 9
-
b116, Windows 7 x 64
WritableImage is not immutable object so when it is passed to Canvas GraphicsContext.drawImage() method its value could be different from what it contains when actual drawing is executed.
See the attached sample. It draws a serie of WritableImage in a loop. When the same WritableImage instance is reused on each iteration, the resulting canvas contains just last image drawn multiple times which results in a completely red canvas. When new WritableImage is created on each loop iteration, result is a nice gradient from black to red.
I believe at least javadoc of drawImage should be improved to cover these cases.
See the attached sample. It draws a serie of WritableImage in a loop. When the same WritableImage instance is reused on each iteration, the resulting canvas contains just last image drawn multiple times which results in a completely red canvas. When new WritableImage is created on each loop iteration, result is a nice gradient from black to red.
I believe at least javadoc of drawImage should be improved to cover these cases.