core | glapi | vbo | math | shader | swrast | swrast_setup | tnl | tnl_dd

s_lines.c File Reference

#include "main/glheader.h"
#include "main/context.h"
#include "main/colormac.h"
#include "main/macros.h"
#include "s_aaline.h"
#include "s_context.h"
#include "s_depth.h"
#include "s_feedback.h"
#include "s_lines.h"
#include "s_span.h"
#include "s_linetemp.h"

Defines

#define NAME   simple_no_z_ci_line
#define INTERP_INDEX
#define RENDER_SPAN(span)   _swrast_write_index_span(ctx, &span)
#define NAME   simple_no_z_rgba_line
#define INTERP_RGBA
#define RENDER_SPAN(span)   _swrast_write_rgba_span(ctx, &span);
#define NAME   ci_line
#define INTERP_INDEX
#define INTERP_Z
#define INTERP_ATTRIBS
#define RENDER_SPAN(span)
#define NAME   rgba_line
#define INTERP_RGBA
#define INTERP_Z
#define RENDER_SPAN(span)
#define NAME   general_line
#define INTERP_RGBA
#define INTERP_Z
#define INTERP_ATTRIBS
#define RENDER_SPAN(span)
#define USE(lineFunc)   swrast->Line = lineFunc

Functions

static void compute_stipple_mask (GLcontext *ctx, GLuint len, GLubyte mask[])
static void draw_wide_line (GLcontext *ctx, SWspan *span, GLboolean xMajor)
void _swrast_add_spec_terms_line (GLcontext *ctx, const SWvertex *v0, const SWvertex *v1)
void _swrast_choose_line (GLcontext *ctx)
 Determine which line drawing function to use given the current rendering context.


Define Documentation

#define INTERP_ATTRIBS

#define INTERP_ATTRIBS

#define INTERP_INDEX

#define INTERP_INDEX

#define INTERP_RGBA

#define INTERP_RGBA

#define INTERP_RGBA

#define INTERP_Z

#define INTERP_Z

#define INTERP_Z

#define NAME   general_line

#define NAME   rgba_line

#define NAME   ci_line

#define NAME   simple_no_z_rgba_line

#define NAME   simple_no_z_ci_line

#define RENDER_SPAN ( span   ) 

Value:

if (ctx->Line.StippleFlag) {                                    \
      span.arrayMask |= SPAN_MASK;                              \
      compute_stipple_mask(ctx, span.end, span.array->mask);    \
   }                                                            \
   if (ctx->Line.Width > 1.0) {                                 \
      draw_wide_line(ctx, &span, (GLboolean)(dx > dy));         \
   }                                                            \
   else {                                                       \
      _swrast_write_rgba_span(ctx, &span);                      \
   }

#define RENDER_SPAN ( span   ) 

Value:

if (ctx->Line.StippleFlag) {                                    \
      span.arrayMask |= SPAN_MASK;                              \
      compute_stipple_mask(ctx, span.end, span.array->mask);    \
   }                                                            \
   if (ctx->Line.Width > 1.0) {                                 \
      draw_wide_line(ctx, &span, (GLboolean)(dx > dy));         \
   }                                                            \
   else {                                                       \
      _swrast_write_rgba_span(ctx, &span);                      \
   }

#define RENDER_SPAN ( span   ) 

Value:

if (ctx->Line.StippleFlag) {                                    \
      span.arrayMask |= SPAN_MASK;                              \
      compute_stipple_mask(ctx, span.end, span.array->mask);    \
   }                                                            \
   if (ctx->Line.Width > 1.0) {                                 \
      draw_wide_line(ctx, &span, (GLboolean)(dx > dy));         \
   }                                                            \
   else {                                                       \
      _swrast_write_index_span(ctx, &span);                     \
   }

#define RENDER_SPAN ( span   )     _swrast_write_rgba_span(ctx, &span);

#define RENDER_SPAN ( span   )     _swrast_write_index_span(ctx, &span)

#define USE ( lineFunc   )     swrast->Line = lineFunc


Function Documentation

void _swrast_add_spec_terms_line ( GLcontext ctx,
const SWvertex v0,
const SWvertex v1 
)

void _swrast_choose_line ( GLcontext ctx  ) 

Determine which line drawing function to use given the current rendering context.

Please update the summary flag _SWRAST_NEW_LINE if you add or remove tests to this code.

static void compute_stipple_mask ( GLcontext ctx,
GLuint  len,
GLubyte  mask[] 
) [static]

static void draw_wide_line ( GLcontext ctx,
SWspan span,
GLboolean  xMajor 
) [static]


Generated on Sun Sep 27 06:48:05 2009 for Mesa Software Rasterization (swrast) by  doxygen 1.5.4