On Mon, 2010-01-11 at 11:14 -0800, Brian Paul wrote:
> Keith Whitwell wrote:
> > Module: Mesa
> > Branch: gallium-fb-dimensions
> > Commit: 609b043d442c99e48d5310244e648ea8a6cc2e8a
> > URL:    
> > http://cgit.freedesktop.org/mesa/mesa/commit/?id=609b043d442c99e48d5310244e648ea8a6cc2e8a
> > 
> > Author: Keith Whitwell <kei...@vmware.com>
> > Date:   Mon Jan 11 11:03:44 2010 +0000
> > 
> > gallium: doc tweaks for bypass_vs_clip_and_viewport
> > 
> > ---
> > 
> >  src/gallium/docs/source/cso/rasterizer.rst |   10 +++++++---
> >  1 files changed, 7 insertions(+), 3 deletions(-)
> > 
> > diff --git a/src/gallium/docs/source/cso/rasterizer.rst 
> > b/src/gallium/docs/source/cso/rasterizer.rst
> > index 4d8e170..2ca9b64 100644
> > --- a/src/gallium/docs/source/cso/rasterizer.rst
> > +++ b/src/gallium/docs/source/cso/rasterizer.rst
> > @@ -133,9 +133,13 @@ implementation-dependent, but will usually be Gourard 
> > for most hardware.
> >  bypass_vs_clip_and_viewport
> >  ^^^^^^^^^^^^^^^^^^^^^^^^^^^
> >  
> > -When set, this implies that vertices are pre-transformed for the viewport, 
> > and
> > -will not be run through the vertex shader. Note that implementations may 
> > still
> > -clip away vertices that are not visible.
> > +When set, this implies that vertices are pre-transformed for the
> > +viewport, and will not be run through the vertex shader. Note that
> > +these vertices will fall outside the conventional unit-cube clip
> > +space.  Implementations are expected to discard pixels which fall
> > +outside the viewport (XXX: how is the viewport defined in this case),
> > +and may if desired choose to subject these vertices to clipping after
> > +appropriate transformation to the clipping cube.
> 
> The viewport doesn't describe a clipping rect.  It just happens that 
> tris clipped to the NDC cube lie fully inside the viewport.  Wide 
> lines and points will generate vertices and fragments outside the 
> viewport.

OK, I didn't think of that case.

> Do we really want to require that the viewport do fragment clipping too?

No.  What I was trying to do (fairly poorly) is figure out what actually
are the semantics of the bypass_vs_clip_and_viewport flag, and word it
in such a way that it could be implemented even on hardware that doesn't
allow you to turn off the vertex shader or clipping -- ie permit an
implementation where we squeeze the incoming vertices down to the
clipping cube and then puff them back out with the viewport afterwards.

> I'd say it's up to the user to also set up a scissor rect if he really 
> doesn't want to see any fragments outside the viewport.

Yeah.  I wasn't really trying to introduce new behaviours.

I often feel life would be easier without bypass_vs_clip_viewport, but
it is also quite convenient for state trackers and blitters to have this
mode available.

Keith


------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Mesa3d-dev mailing list
Mesa3d-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev

Reply via email to