NullPointerExceptions when updating images
kirill.prazdnikov at oracle.com
Mon Dec 26 02:52:46 PST 2011
We understand you issue and working on the solution.
Most probably it will be solved in 2.1 release.
On 21-Dec-11 19:25, Adam Granger wrote:
> Hi, wondering if anyone can help with this issue I've just raised. Perhaps
> some kind of workaround? Thanks.
> NullPointerException seen in rendering loop. This stops the screen
> updating after running for a minute or so.
> (in javafx 2.0.1)
> (in javafx 2.0.2)
> at com.sun.prism.impl.BaseGraphics.drawTextureVO(BaseGraphics.java:365)
> ...See attachments for full trace.
> - Code to reproduce problem attached. Note this is a highly simplified
> version of what I'm doing - I know a moving red rectangle can be done more
> easily/robustly in native JavaFX !
> - App was run with following options "-Djavafx.verbose=true
> -Dprism.verbose=true -Xmx1200M"
> - Seems to be memory related - if I allocate a decent chunk of memory
> upfront - say 400M then problem occurs almost instantly.
> - A slightly different exception seen after upgrade to javaFX 2.0.2 =>
> Console outputs for both versions attached.
> - also attached DxDiag.exe output in case direct X related.
> Background (why am I doing this!)
> We need to display constantly changing pixel data at around 1280 x 400
> resolution, changing at rates of 4Hz or so.
> This was previously achieved in previous Swing systems using
> JPanel.paintComponent() + a buffered image .
> There is no "nice" way to do this in JavaFX, so updating via
> impl_fromExternalImage() is used.
> If anyone can come up with a more robust way of doing the same thing
> please let me know
More information about the openjfx-dev