We help IT Professionals succeed at work.

JavaFX2: Differences between Stage, Group, Scene?

Gregg
Gregg used Ask the Experts™
on
Hello Java Experts,

Can you please explain the differences and/or relationship between a JavaFx 2.0 Stage, Scene, and group? I am reading up on FX2 using API, blogs and tutorials. I have been working with the demo applications as well. However, i am still quite unclear on the purpose of each.

I believe i understand that the stage is the application window (like a JFrame). However i get confused when a JavaFX 2 application extends Application. Can i have multiple scenes? And why would I?

In regards to the Scene, I see tutorials that reference the Scene Graph. Am i correct in thinking the Scene Graph is the structure of a specific scene? And the graph starts with the root node and branches downwards with leaf and branch nodes? I just dont understand the purpose of the Scene and its relationship or purpose.

Examples of when to use each would be appreciated (if not clearly obvious). I need help putting the relationships together.

Your thoughts are appreciated! Gregg
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

Author

Commented:
Thanks! Article looks familiar, i must have seen it at some point. Just what i needed.