Looks like I started a good conversation. Thanks for the replies.
I believe that using POLYGON_LINE will result in showing the edges of all
the interior triangles, won't it?
I use a LineStripArray to draw just the outside border.
I haven't been using the same GeometryInfo to create the filled and border
polygons. Is that possible? Will I save much?
Daniel
> -----Original Message-----
> From: Doug Gehringer [mailto:[EMAIL PROTECTED]]
> Sent: Friday, September 29, 2000 1:12 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [JAVA3D] FW: [JAVA3D] border on polygons
>
>
> > From: "Andrew R. Thomas-Cramer" <[EMAIL PROTECTED]>
> >
> > I can confirm this approach works. I implemented it to
> display a surface graph
> > with both colors and wire-frame.
> > To be more specific about the Z value, you'd need to set
> the polygon offset
> for
> > the wire-frame _less_ than that for the filled polygons.
> For the wire-frame's
> > appearance:
> >
> > PolygonAttributes attrPolygon = new PolygonAttributes();
> > attrPolygon.setPolygonMode(
> PolygonAttributes.POLYGON_LINE );
> > attrPolygon.setPolygonOffset( -1 ); // Nudge
> toward viewer.
> >
> > Also, I agree with Mark. We shouldn't have to have two
> separate Shape3Ds to
> > produce a single visual object that's both filled and
> wire-framed. Memory
> > requirements might be drastically reduced if a single
> Shape3D could be both
> > filled and wire-framed.
>
> If both Shape3Ds use the same Geometry, then the memory
> requirements are pretty
> small-- just the different attributes. If you need indiviual
> control over the
> edges, then you'll need to use a separate Geometry (i.e. a
> LineStripArray).
>
> Earlier APIs have had individual polygon edge flags which the
> application could
> use to control the edges. These saved memory, but my
> experience was that these
> were much slower than storing and drawing the edges as lines.
> A classic
> memory/speed tradeoff.
>
> > However, wouldn't a little more be required than just
> changing the polygon
> mode
> > to a bitwise-OR? How would the color of the wire-frame be specified
> > independently of the color of the fill? (If they had the
> same coloring,
> there'd
> > be no point -- or rather, no lines. :P )
>
> Exactly. By using two shapes you have control over the
> appearance of both
> primitives. If edges were built in to a single Shape then
> there would have to
> be separate edge attributes.
>
>
> Doug
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".