Information on reading the softimage .hrc format:
From: clintchester chua
To: "J.P.Lewis"
(March 03)
Here is what I did in detail and that includes what is written
below.
- Under U_DIR
-noPoints is the number of control points in the U direction
-order is 4 = cubic is the same in OpenGL so use 4 in OpenGL
-closed (7th token from U_DIR) state that it is closed (periodic)
-noKnots is the number of knot points that follows
- Under V_DIR
-noPoints is the number of control points in the V direction
-order is 4 = cubic is the same in OpenGL so use 4 in OpenGL
-not_closed (7th token form V_DIR) state that it is NON periodic
-noKnots is the number of knot points that follows
-I repeated the first and last knot point in the V_DIR
-I increase the knot points from 26 to 32 by incrementing the uniform knot values
-Then i changed the control points from column major to row major
-Then i copied the first 3 strips of the u direction and appended it to the end
The model originally had
uknots 26
vknots 47
control points 1125 (column major)
The resulting model after my transfrom
uknots 32
vknots 49
control points 1260 (row major)
OpenGL calculates the number of control points implicity via the
equation
(uknots-uOrder)x(vknots-vOrder) = total control points
you will need to match the # of control points to this equation
and you will see that it works out
(32-4)x(49-4) = 1260 (correct)
if I forgot anything I can email him my "undocumented" program
to him hehehe :) I hope that helps!!
Clint