| | |
Graphics + Threads = :(
![]() |
•
•
Join Date: Mar 2009
Posts: 58
Reputation:
Solved Threads: 3
Hey All
I'm working on a graphics project at the moment, and although the details themselves are a little tedious (I won't bore you with them all) I am having some problems. My app was working beautifully, rendering my shapes with ease. But in an attempt to make it more efficient, I decided to make it multi threaded...
Well Now things are going less well. My code draws a number of polygons on screen (to represent the faces of a shape) and although in the non-threaded version, these are all drawn properly, in the multithreaded version many of my polygons just don't draw, instead throwing a ClassCastException. It says "sun.java2D.NullSurfaceData cannot be cast to sun.java2D.D3D.D3DSurfaceData"
Anybody else had this problem? Any advice?
Thanks in advance
M
I'm working on a graphics project at the moment, and although the details themselves are a little tedious (I won't bore you with them all) I am having some problems. My app was working beautifully, rendering my shapes with ease. But in an attempt to make it more efficient, I decided to make it multi threaded...
Well Now things are going less well. My code draws a number of polygons on screen (to represent the faces of a shape) and although in the non-threaded version, these are all drawn properly, in the multithreaded version many of my polygons just don't draw, instead throwing a ClassCastException. It says "sun.java2D.NullSurfaceData cannot be cast to sun.java2D.D3D.D3DSurfaceData"
Anybody else had this problem? Any advice?
Thanks in advance
M
Whether you think you can, or think you can't, you're right.
•
•
Join Date: Nov 2008
Posts: 332
Reputation:
Solved Threads: 53
0
#2 26 Days Ago
Active Rendering
http://www.gamedev.net/reference/pro...er/default.asp
Thread Pools
http://www.brackeen.com/javagamebook/
Threads
http://java.sun.com/products/jfc/tsc.../threads1.html
http://www.gamedev.net/reference/pro...er/default.asp
Thread Pools
http://www.brackeen.com/javagamebook/
Threads
http://java.sun.com/products/jfc/tsc.../threads1.html
Last edited by quuba; 26 Days Ago at 9:29 am.
![]() |
Other Threads in the Java Forum
- Previous Thread: How to input and output from/or to a file?!
- Next Thread: loading milkshape model in J2ME
| Thread Tools | Search this Thread |






