#include "t_vertex.h"
+#if 0
+#define DEBUG_INSERT printf("%s\n", __FUNCTION__)
+#else
+#define DEBUG_INSERT
+#endif
+
/*
* These functions take the NDC coordinates pointed to by 'in', apply the
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[5] * in[1] + vp[13];
out[2] = vp[10] * in[2] + vp[14];
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[5] * in[1] + vp[13];
out[2] = vp[10] * in[2] + vp[14];
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[5] * in[1] + vp[13];
out[2] = vp[14];
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[13];
out[2] = vp[14];
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[5] * in[1] + vp[13];
out[2] = vp[10] * in[2] + vp[14];
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[5] * in[1] + vp[13];
out[2] = vp[10] * in[2] + vp[14];
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[13];
out[2] = vp[14];
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[5] * in[1] + vp[13];
}
{
GLfloat *out = (GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = vp[0] * in[0] + vp[12];
out[1] = vp[13];
}
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = in[1];
out[2] = in[2];
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = in[1];
out[2] = in[2];
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = in[1];
out[2] = 0;
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = 0;
out[2] = 0;
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = in[1];
out[2] = in[3];
static INLINE void insert_3f_xyw_err( const struct tnl_clipspace_attr *a, GLubyte *v, const GLfloat *in )
{
(void) a; (void) v; (void) in;
+ DEBUG_INSERT;
_mesa_exit(1);
}
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = in[1];
out[2] = in[2];
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = in[1];
out[2] = 0;
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = 0;
out[2] = 0;
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = in[1];
}
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
out[1] = 0;
}
{
GLfloat *out = (GLfloat *)(v);
(void) a;
-
+ DEBUG_INSERT;
out[0] = in[0];
}
static INLINE void insert_null( const struct tnl_clipspace_attr *a, GLubyte *v, const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a; (void) v; (void) in;
}
const GLfloat *in )
{
GLchan *c = (GLchan *)v;
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_CHAN(c[0], in[0]);
UNCLAMPED_FLOAT_TO_CHAN(c[1], in[1]);
const GLfloat *in )
{
GLchan *c = (GLchan *)v;
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_CHAN(c[0], in[0]);
UNCLAMPED_FLOAT_TO_CHAN(c[1], in[1]);
const GLfloat *in )
{
GLchan *c = (GLchan *)v;
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_CHAN(c[0], in[0]);
UNCLAMPED_FLOAT_TO_CHAN(c[1], in[1]);
const GLfloat *in )
{
GLchan *c = (GLchan *)v;
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_CHAN(c[0], in[0]);
c[1] = 0;
static INLINE void insert_4ub_4f_rgba_4( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_4ub_4f_rgba_3( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_4ub_4f_rgba_2( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_4ub_4f_rgba_1( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
v[1] = 0;
static INLINE void insert_4ub_4f_bgra_4( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_4ub_4f_bgra_3( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_4ub_4f_bgra_2( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_4ub_4f_bgra_1( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[0]);
v[1] = 0;
static INLINE void insert_4ub_4f_argb_4( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[1]);
static INLINE void insert_4ub_4f_argb_3( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[1]);
static INLINE void insert_4ub_4f_argb_2( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[1]);
static INLINE void insert_4ub_4f_argb_1( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[0]);
v[2] = 0x00;
static INLINE void insert_4ub_4f_abgr_4( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[3], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[1]);
static INLINE void insert_4ub_4f_abgr_3( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[3], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[1]);
static INLINE void insert_4ub_4f_abgr_2( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[3], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[1]);
static INLINE void insert_4ub_4f_abgr_1( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[3], in[0]);
v[2] = 0x00;
static INLINE void insert_3ub_3f_rgb_3( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_3ub_3f_rgb_2( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_3ub_3f_rgb_1( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
v[1] = 0;
static INLINE void insert_3ub_3f_bgr_3( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_3ub_3f_bgr_2( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[0]);
UNCLAMPED_FLOAT_TO_UBYTE(v[1], in[1]);
static INLINE void insert_3ub_3f_bgr_1( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[2], in[0]);
v[1] = 0;
static INLINE void insert_1ub_1f_1( const struct tnl_clipspace_attr *a, GLubyte *v,
const GLfloat *in )
{
+ DEBUG_INSERT;
(void) a;
UNCLAMPED_FLOAT_TO_UBYTE(v[0], in[0]);
}
/* Although included for completeness, the position coordinate is
* usually handled differently during clipping.
*/
+ DEBUG_INSERT;
out[0] = (in[0] - vp[12]) / vp[0];
out[1] = (in[1] - vp[13]) / vp[5];
out[2] = (in[2] - vp[14]) / vp[10];
{
const GLfloat *in = (const GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = (in[0] - vp[12]) / vp[0];
out[1] = (in[1] - vp[13]) / vp[5];
out[2] = (in[2] - vp[14]) / vp[10];
{
const GLfloat *in = (const GLfloat *)v;
const GLfloat * const vp = a->vp;
-
+ DEBUG_INSERT;
out[0] = (in[0] - vp[12]) / vp[0];
out[1] = (in[1] - vp[13]) / vp[5];
out[2] = 0;