It is currently 24 Apr 2014, 11:41

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 9 posts ] 
Author Message
 Post subject: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:04 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
I made a quick ICE Topology tutorial and posted it at the Area and XSI Base. I promise I would post it here too so here it is.


Our first ICE topology mesh is the unit cube. I have created two versions: one with the first vertex located at position 0,0,0 (which make it centered at 0.5, 0.5, 0.5) and the second with its center at position 0,0,0 similar to other SI primitives.

As an example, below is the ICE Tree topology for the first cube.


Attachments:
ICE_Tree_Topo_Cube.jpg
ICE_Tree_Topo_Cube.jpg [ 64.77 KiB | Viewed 1677 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:06 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
The next figure shows details of the String of vertices feeding the vertex position and the String of vertex ordering (CCW) defining the polygonal description of the cube. I created the vertices and the faces in the same order as the existing SI cube.

To create the vertex / edge / face structure of the cube, I used the Half Edge Data structure (the Half edge data structure is a subset of the Winged Edge data structure which also include the Quad Edge data structure). I found my little sketch handy when coding data structures for geometry in Softimage, it helps to visualize the structure.


Attachments:
halfedge.jpg
halfedge.jpg [ 57.48 KiB | Viewed 1676 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:07 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
Each face quad is terminated by the negative -2 indicating to Softimage that the quad definition for that face is complete and the next set of vertex indices defines the next face quad of the cube. You can change this to be triangle if you wish following the same process.

With headlight turned on, we check that all the faces are oriented correctly with their normals facing outward.


Attachments:
ICE_Tree_Topo_Cube_HL.jpg
ICE_Tree_Topo_Cube_HL.jpg [ 65.26 KiB | Viewed 1676 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:09 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
Feeding the vertex via a string node is cool but not very intuitive. The next step is to build the cube dynamically by feeding it with three scalar inputs: Length, Height and Width.

Using scalar and, scalar to 3D vector nodes, we can control the size of our cube interactively in length, width and height.

The first figure is the cube ICE Tree with the first vertex at position 0,0,0.


Attachments:
ICE_Tree_Topo_Cube_v2.jpg
ICE_Tree_Topo_Cube_v2.jpg [ 147.29 KiB | Viewed 1676 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:10 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
And another example, this time we drive all the parameters x,y,z (I like it better that way, although it make a mess of the ICE Tree). The cube is now centered at the world coordinate much like the Softimage primitives.


Attachments:
ICE_Tree_Topo_Cube_v2b.jpg
ICE_Tree_Topo_Cube_v2b.jpg [ 236.44 KiB | Viewed 1675 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:12 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
So far so good. We now have a cube that we can scale at will in length, width or height.

The cube is a very useful primitive. I use the cube often as a container for simulation or as an object to compare and scale other objects.

One thing is missing: real world measurement. With ICE, this is easy to add.

We can create a small compound using a multiply by scalar node and modifying the Factor input properties with a combo box or when we create the final compound, take care of the input factor the same way (although be aware of repetitive work unfortunately. You will have to do it for each factor inputs; somehow Softimage does not copy the input of the combo box. You way not want to expose these inputs to casual users anyway).

The next figure below shows the process by creating a small compound called Units that provides various conversion factors for our purpose.

The conversion factors entered in the combo box are based on the SI_Unit being 1 decimetre (10 centimetres):

- SI_Units = 1
- Metres = 10
- Centimetres = 0.1
- Millimetres = 0.01
- Kilometres = 10000
- Decimal_Feet = 3.048
- Inches = 0.254
- Yards = 9.144 and
- Miles = 16093.44

To create the combo box, right click the exposed port in the left area of the compound and choose property. Enter in the combo string field the unit name and in the combo value field the value of that unit. Click add combo, repeat until you’re done.

Don’t forget to export your compound! And voila, real world measurement at your finger tips!


Attachments:
Units_compound2.jpg
Units_compound2.jpg [ 64.81 KiB | Viewed 1675 times ]
Units_compound.jpg
Units_compound.jpg [ 80.28 KiB | Viewed 1675 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:13 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
Using the newly create Units compound, I modified the second Cube ICE Tree as below.


Attachments:
ICE_Tree_Topo_Cube_v3.jpg
ICE_Tree_Topo_Cube_v3.jpg [ 232.41 KiB | Viewed 1675 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 03:21 
Offline
User avatar

Joined: 19 Mar 2010, 00:38
Posts: 628
Location: St. Thomas, Ontario
You can now create a cube at any size in various real world units.

If you want, you can clean up the mess and expose only what you need.

Next step, adding subdivisions (U,V base) to our cube.

Until next time, Happy Coding!

DB


Attachments:
ICE_Tree_Topo_Cube_v3b.jpg
ICE_Tree_Topo_Cube_v3b.jpg [ 157.16 KiB | Viewed 1675 times ]

_________________
$ifndef "Softimage"
set "Softimage" "true"
$endif
Top
 Profile  
 
 Post subject: Re: ICE Topology Cube Tutorial
PostPosted: 12 May 2011, 12:44 
Offline
User avatar

Joined: 09 Jun 2009, 14:49
Posts: 412
Location: London, UK
splendid! :D many thanks for taking the time to do this, am looking forward to the sphere!

_________________
Gossip is what no one claims to like, but everybody enjoys.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group