Rename CLIP_ALL_BITS to CLIP_FRUSTUM_BITS to reflect the fact that the value
only includes the 6 frustum bits, not the user-clip plane bit, nor the vertex cull bit.
This commit is contained in:
parent
f51a32e82a
commit
51faca1270
|
@ -245,7 +245,7 @@ static int test_cliptest_function( clip_func func, int np,
|
|||
ref->flags = 0;
|
||||
|
||||
dco = rco = 0;
|
||||
dca = rca = CLIP_ALL_BITS;
|
||||
dca = rca = CLIP_FRUSTUM_BITS;
|
||||
|
||||
ref_cliptest[psize]( source, ref, rm, &rco, &rca );
|
||||
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
/*
|
||||
* Mesa 3-D graphics library
|
||||
* Version: 6.1
|
||||
* Version: 6.5.1
|
||||
*
|
||||
* Copyright (C) 1999-2004 Brian Paul All Rights Reserved.
|
||||
* Copyright (C) 1999-2006 Brian Paul All Rights Reserved.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and associated documentation files (the "Software"),
|
||||
|
@ -99,7 +99,7 @@ _math_init_transformation(void);
|
|||
#define CLIP_FAR_BIT 0x20
|
||||
#define CLIP_USER_BIT 0x40
|
||||
#define CLIP_CULL_BIT 0x80
|
||||
#define CLIP_ALL_BITS 0x3f
|
||||
#define CLIP_FRUSTUM_BITS 0x3f
|
||||
|
||||
|
||||
typedef GLvector4f * (_XFORMAPIP clip_func)( GLvector4f *vClip,
|
||||
|
|
|
@ -1193,7 +1193,7 @@ do_ndc_cliptest(GLcontext *ctx, struct arb_vp_machine *m)
|
|||
* the clipmask.
|
||||
*/
|
||||
m->ormask = 0;
|
||||
m->andmask = CLIP_ALL_BITS;
|
||||
m->andmask = CLIP_FRUSTUM_BITS;
|
||||
|
||||
if (tnl->NeedNdcCoords) {
|
||||
VB->NdcPtr =
|
||||
|
|
|
@ -227,7 +227,7 @@ static GLboolean run_arb_vertex_shader (GLcontext *ctx, struct tnl_pipeline_stag
|
|||
vb->AttribPtr[_TNL_ATTRIB_POINTSIZE] = &store->outputs[VERT_RESULT_PSIZ];
|
||||
|
||||
store->ormask = 0;
|
||||
store->andmask = CLIP_ALL_BITS;
|
||||
store->andmask = CLIP_FRUSTUM_BITS;
|
||||
|
||||
if (tnl->NeedNdcCoords)
|
||||
{
|
||||
|
|
|
@ -176,7 +176,7 @@ run_vp( GLcontext *ctx, struct tnl_pipeline_stage *stage )
|
|||
* the clipmask.
|
||||
*/
|
||||
store->ormask = 0;
|
||||
store->andmask = CLIP_ALL_BITS;
|
||||
store->andmask = CLIP_FRUSTUM_BITS;
|
||||
|
||||
if (tnl->NeedNdcCoords) {
|
||||
VB->NdcPtr =
|
||||
|
|
|
@ -73,7 +73,8 @@
|
|||
#define EDGEFLAG_SET(idx, val) VB->EdgeFlag[idx] = val
|
||||
|
||||
|
||||
#define CLIPMASK (CLIP_ALL_BITS|CLIP_CULL_BIT)
|
||||
/* This does NOT include the CLIP_USER_BIT! */
|
||||
#define CLIPMASK (CLIP_FRUSTUM_BITS | CLIP_CULL_BIT)
|
||||
|
||||
|
||||
/* Vertices, with the possibility of clipping.
|
||||
|
@ -85,6 +86,7 @@
|
|||
do { \
|
||||
GLubyte c1 = mask[v1], c2 = mask[v2]; \
|
||||
GLubyte ormask = c1|c2; \
|
||||
printf("0x%x 0x%x 0x%x\n", c1, c2, CLIPMASK);\
|
||||
if (!ormask) \
|
||||
LineFunc( ctx, v1, v2 ); \
|
||||
else if (!(c1 & c2 & CLIPMASK)) \
|
||||
|
|
|
@ -168,7 +168,7 @@ static GLboolean run_vertex_stage( GLcontext *ctx,
|
|||
* the clipmask.
|
||||
*/
|
||||
store->ormask = 0;
|
||||
store->andmask = CLIP_ALL_BITS;
|
||||
store->andmask = CLIP_FRUSTUM_BITS;
|
||||
|
||||
if (tnl->NeedNdcCoords) {
|
||||
VB->NdcPtr =
|
||||
|
|
Loading…
Reference in New Issue