Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (522)
Games in Android Showcase (127)
games submitted by our members
Games in WIP (589)
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  
  Why does it  (Read 3133 times)
0 Members and 1 Guest are viewing this topic.
Offline Java Cool Dude

Senior Devvie




Java forever


« Posted 2003-10-31 03:51:52 »

mad flicker when I try to use the function view.getTransform().lookAt(...) to move around my 3D world?
Besides when I change the location of the eye, the effect lasts even less than a second before it gets back to where it was + more flickering...
Grrrrrr Angry
Offline Java Cool Dude

Senior Devvie




Java forever


« Reply #1 - Posted 2003-10-31 05:27:37 »

lookAt(new , new , new) strangely fixed it... Roll Eyes
Offline Yuri Vl. Gushchin

Senior Devvie




Speak Java!


« Reply #2 - Posted 2003-10-31 06:55:14 »

Strange...

BTW, I had similar behavior when my changes to lookAt() were not synchronized with rendering thread, so the eye position was changing in the mid of rendering pass (your instance of View can be used for such sync).

Yuri

Yuri Vl. Gushchin
JProof Group
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline DavidYazel

Junior Devvie




Java games rock!


« Reply #3 - Posted 2003-11-03 17:51:01 »

He is right.

Lookat unfortunely modifies the input parameters.

David Yazel
Xith3D Project Founder
http://xith3d.dev.java.net

It may look complicated, but in the end it is just a bunch of triangles
Offline Java Cool Dude

Senior Devvie




Java forever


« Reply #4 - Posted 2003-11-03 18:10:02 »

Quote
He is right.

Lookat unfortunely modifies the input parameters.


Can you fix that Sir Smiley
Offline Yuri Vl. Gushchin

Senior Devvie




Speak Java!


« Reply #5 - Posted 2003-11-04 14:33:56 »

I even don't know [read: don't think] it should be fixed because of it will introduce synchronization calls in the rendering pass.

I believe it should be done on application level [at least for now].

Yuri

Yuri Vl. Gushchin
JProof Group
Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #6 - Posted 2003-11-06 02:40:57 »

Should thread local storage be used to avoid synchronzation?

Offline abies

Senior Devvie





« Reply #7 - Posted 2003-11-06 07:27:54 »

If this is synchronization issue, I think we should consider more strict rules about what can and what cannot be done at what point.

For me, calling ANY scenegraph method from anything other than rendering thread is major offense. This includes direct modification of values from AWT event thread. AWT listener should only enqueue actions/events which will be processed later by main rendering thread - be it in Behaviour, or just before/after renderOnce in main loop.

In java3d, it was possible to change scenegraph from event thread, because all access was done through synchronized messages, which where processes later by rendering thread. In xith3d, with direct access to everything, I think it should be the first big advice for any programmer - do not touch scenegraph from event thread.

Artur Biesiadowski
Offline kevglass

« JGO Spiffy Duke »


Medals: 195
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #8 - Posted 2003-11-06 07:50:13 »

Absolutely!

Could this be enforced this via some checking on the current Thread (compare to the rendering Thread). An assert would seem to be ideal here, assert if you're making modifications from any thread other than the rendering thread?

Kev

Offline Jens

Senior Devvie




Java for games!


« Reply #9 - Posted 2003-11-06 08:17:41 »

I completely agree here and will include this in the tutorials.

Xith3D Getting Started Guide (PDF,HTML,Source)
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline endolf

JGO Coder


Medals: 7
Exp: 15 years


Current project release date: sometime in 3003


« Reply #10 - Posted 2003-11-06 09:10:15 »

I agree, one of the things I learned from doing java3d was to use behaviors for *everything* that touched the scenegraph, I have a TransformGroupUpateBehavior (or something like that) so I can set a transform during a frame render and  it won't take effect untill the bahvior fires inbetween the next frames.

Endolf

Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

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

The first screenshot will be displayed as a thumbnail.

trollwarrior1 (27 views)
2014-11-22 12:13:56

xFryIx (69 views)
2014-11-13 12:34:49

digdugdiggy (48 views)
2014-11-12 21:11:50

digdugdiggy (42 views)
2014-11-12 21:10:15

digdugdiggy (36 views)
2014-11-12 21:09:33

kovacsa (60 views)
2014-11-07 19:57:14

TehJavaDev (64 views)
2014-11-03 22:04:50

BurntPizza (62 views)
2014-11-03 18:54:52

moogie (77 views)
2014-11-03 06:22:04

CopyableCougar4 (77 views)
2014-11-01 23:36:41
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
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!