[gl2ps] Showing hidden lines

Sergi Diaz sergi at mcneel.com
Mon Jul 2 11:44:00 CEST 2007


Hi all,

I was able to find a solution without tinkering with gl2ps itself. I explain
it here, it could be useful to anybody.
Using glDepthRange call, I rendered my scene using glDepthRange(0.1, 1).
Later, I render the lines using a stipple patern with glDepthRange(0, 0.09).
This way, the stippled lines are always rendered because they're actually
nearer to the camera by the depth buffer definition of near. The visual
effect is the same :).

Cheers,

--
Sergi Diaz
Penguin Development Team
McNeel Europe
www.penguin3d.com
www.rhino3d.com


----------------------------------------------------------------------

> Message: 1
> Date: Thu, 28 Jun 2007 17:37:02 +0200
> From: Sergi Diaz<sergi at mcneel.com>
> Subject: Re: [gl2ps] Showing hidden lines
> To: <gl2ps at geuz.org>
> Message-ID: <LDEHJAHEAHJGIFNHMEHOMEFKDOAA.sergi at mcneel.com>
> Content-Type: text/plain;	charset="us-ascii"
>
> I hadn't tried, thanks.
> I've done it now, and it's still the same. It seems that gl2ps doesn't
take
> a look at glDepthFunc values or DEPTH_TEST being disabled. I can
understand
> that, it's not trivial, but it would have been nice for me.
>
> Oh well, I'll have to do it myself. Changing gl2ps code to support that
will
> be a nightmare, I suppose. Wish me luck.
>
> Cheers,
> -Sergi
>
> P.S: Mmm, maybe I could do something using glDepthRange... I'll try that
first.