Java-Gaming.org
Play Revenge of the Titans! The situation is critical. We need fancy commanders to defend Earth, the moon, Mars!
Featured games (78)
games approved by the League of Dukes
Games in Showcase (406)
games submitted by our members
Games in WIP (290)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Java3D Mixed-mode rendering problems  (Read 702 times)
0 Members and 1 Guest are viewing this topic.
Offline modelsmith

Senior Newbie




"Never stop three feet short."


« Posted 2006-05-05 10:40:18 »

At the moment, I let the Java3D renderer do a lot of my rendering, I use the GeometryUpdater.updateData to change vertex data in real-time.

However, I do want to also render arbitrary shapes in real-time. I've extended Canvas3D and am using the preRender, renderField, and postRender methods to do this.

This is where I run into trouble. If I first draw, for example a LineArray with the flags: COORDINATES | COLOR_4,
and then immediately render a QuadArray with the flags: COORDINATES | NORMALS,

 The quad is rendered as though it has per-vertex coloring  Huh.
In fact, if I am cycling the vertex colors in the line array (different color for each vert),
 the entire quad seems to be rendered in one of the colors.

 I have had other trouble with trying to render a textured quad. Like rendering the FPS at the top of the screen.
All of my shapes in the scenegraph (rendered by the Java3D pipe, not in immediate mode) which did not have a texture assigned to them would render with the texture on them.
Suddenly, all of my white and gray quads on screen had my FPS text (all stretched and contorted) all over them.

 I have tried calling flush(true) and flush(false) all over the place. Calling clear() was no good as it cleared everything  Shocked Roll Eyes.
Is there a configuration set somewhere that needs to be reset?

 I'm sure I can somehow get around this and do it in pure-retained mode.
However, if there is a better way, I'm all for it.

 Thanks for any help. Sorry if this is an obvious one.
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

Play Revenge of the Titans! The situation is critical. We need fancy commanders to defend Earth, the moon, Mars!
 
Get high quality music tracks for your game!

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

The invasion has landed! On Mars! And you're there to beat 'em!
cubemaster21 (62 views)
2013-05-17 21:29:12

alaslipknot (71 views)
2013-05-16 21:24:48

gouessej (102 views)
2013-05-16 00:53:38

gouessej (99 views)
2013-05-16 00:17:58

theagentd (108 views)
2013-05-15 15:01:13

theagentd (98 views)
2013-05-15 15:00:54

StreetDoggy (144 views)
2013-05-14 15:56:26

kutucuk (167 views)
2013-05-12 17:10:36

kutucuk (166 views)
2013-05-12 15:36:09

UnluckyDevil (175 views)
2013-05-12 05:09:57
Complex number cookbook
by Roquen
2013-04-24 12:47:31

2D Dynamic Lighting
by Oskuro
2013-04-17 16:46:12

2D Dynamic Lighting
by Oskuro
2013-04-17 16:45:57

2D Dynamic Lighting
by Oskuro
2013-04-17 16:23:20

Noise (bandpassed white)
by Roquen
2013-04-05 17:36:01

Noise (bandpassed white)
by Roquen
2013-04-03 16:17:38

Java Data structures
by Roquen
2013-03-29 13:21:12

Topic Request
by kutucuk
2013-03-22 21:42:01
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!
Page created in 0.07 seconds with 21 queries.