Home Overview FAQ Documentation Download Mailing List Geomview For Windows? Support Users Development Bug Reporting Contributing Contact Us Sponsors
|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Update REQ 6062]: loading lines/points
> I am looking for assistance with the loading of these lines into Geomview. > I have come to the conclusion that I probably want to create a .vect file > specifying the vertices of all the lines. Yes, that's probably best. Would an example VECT file help? Here's a simple one, containing two "polylines" (two polygonal curves, one with three points, the other with four points, with no colors specified): VECT 2 7 0 # We have two polylines, with a total of 7 points, no colors 3 4 # First polyline has 3 points, second polyline has 4 points 0 0 # First polyline has no colors, so does the second # Now we specify all the X Y Z vertex positions for all the polylines, # which appear in the same order as mentioned in the header, # i.e. first the three vertices for the first polyline, then the # four vertices for the second. There's nothing to mark which vertices # go with which polyline. We add an extra blank line for clarity, # but the software doesn't care. 0 1 0 0 1.5 1 1 1.5 1 -.5 1 1 -.5 1.5 1 .5 .5 .5 1 1 0 # Now, if we had specified any colors, they'd appear here. # Since there aren't any, the lines will appear black by default, # but this can be changed via geomview's "Edge color" controls # on the appearance panel. In general, if you have a bunch of polygonal curves, you just write out all their vertex positions in sequence, preceded by a header like: VECT <npolylines> <totalvertices> <totalcolors> <nvertices-for-polyline-1> <nvertices-for-polyline-2> ... <nverts-for-polyline-n> <colors-for-polyline-1> <colors-for-polyline-2> ... <nverts-for-polyline-n> Line breaks aren't significant -- they're separators just as blanks are -- so you could write the above example's header just as well as VECT 2 7 0 3 4 0 0 or equivalently as VECT 2 7 0 3 4 0 0 For a more elaborate example which does use colors, see the VECT section in the file "doc/oogltour". Stuart Levy, Geometry Center
|
||
Home | Overview | FAQ | Documentation | Support | Download | Mailing List Windows? | Development | Bug Reporting | Contributing | Contact Us | Sponsors |
|||
site hosted by |