Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
Home
Help
Search
Login
Register
www.jpct.net
»
jPCT - a 3d engine for Java
»
Support
»
Polyline in software-renderer
« previous
next »
Print
Pages: [
1
]
Go Down
Author
Topic: Polyline in software-renderer (Read 2334 times)
ecm
byte
Posts: 1
Polyline in software-renderer
«
on:
February 19, 2016, 02:18:46 pm »
Hi all,
I know that Polyline works in OpenGL, but I do not get any results with the software-renderer. Any workaround/fixes?
«
Last Edit: February 19, 2016, 02:29:49 pm by EgonOlsen
»
Logged
EgonOlsen
Administrator
quad
Posts: 12298
Re: Polyline in software-renderer
«
Reply #1 on:
February 19, 2016, 02:29:37 pm »
No, it's not supported by the software renderer. Quote from the docs of the Polyline class:
Quote
This doesn't work for the software renderer.
You could try to implement your own solution by using
http://www.jpct.net/doc/com/threed/jpct/Interact2D.html#project3D2D(com.threed.jpct.Camera, com.threed.jpct.FrameBuffer, com.threed.jpct.SimpleVector)
and then draw the line via the normal Java2D methods on top of the rendered image, but this of course won't take the depth buffer into account and you would have to do the clipping at the near plane all by yourself.
What do you need this for? Maybe there's some other solution...
Edit: I fixed the thread's title, in case you are wondering why I edited your post.
Logged
AGP
quad
Posts: 1726
Re: Polyline in software-renderer
«
Reply #2 on:
February 19, 2016, 08:39:10 pm »
Why not just implement the Java2D way for the software renderer, Egon? Isn't best to keep both renderers as close as possible? And the software renderer is such a nice feature of jpct, really. I wouldn't want it to become obsolete.
Logged
EgonOlsen
Administrator
quad
Posts: 12298
Re: Polyline in software-renderer
«
Reply #3 on:
February 19, 2016, 08:48:43 pm »
Because it would ignore the depth buffer. The software renderer has line drawing capabilities, but they aren't exposed because they are simple 2D lines with no culling, clipping or depth. I can put it on the TODO list, but not with top priority.
Logged
Print
Pages: [
1
]
Go Up
« previous
next »
www.jpct.net
»
jPCT - a 3d engine for Java
»
Support
»
Polyline in software-renderer