Yea, it looks reasonably do-able. Although it might take you a while. This is my idea:
Code:
Create function(s) that will:
1. Load from the file, line by line
a. First get the "lengths" or sizes
b. Then use a for loop to get the vertecies, etc
c. Then use a switch/case to see what "type" it is
d. Save it into the appropriate array
2. Save to a file (those arrays)
a. First write the array lengths
b. Then a for loop to write the points
c. use format$ if you need to right justify the array indexes (unnecesary)
3. Thats it you are done!!
It will take you a while but isnt it worth it?? LOL.
This is what im thinking of:
Code:
Type udtVert
A as double
B as double
C as double
End Type
Type udtPt
X as double
Y as double
End Type
Type udtPoly
pt(3) as udtPt
vt(3) as udtVert
End Type
Type udtChannel
Vertecies() as udtVert
' the first 4 are the matrix so the length is UBound(Vertecies)-4
Polygons() as udtPoly
Matrix As Integer
End Type
Type udtRec
Version as string
Name as string
Author as string
Weight as Double
' [...]
Channels() as udtChannel
' [...]
End Type
And then in your actual code you will have to do alot of "ReDim" to those arrays according to the numbers you get back from files. It shouldnt be that hard really. Or is it? Get something started and post again if you get stuck on something more specific and ill be glad to help you out.
MoMad