blah, forgot about no-asm :P

This commit is contained in:
Bill Currie 2003-01-06 19:05:51 +00:00
parent 71196fedf6
commit ca720c26a5
3 changed files with 63 additions and 5 deletions

View file

@ -173,7 +173,7 @@ D_PolysetSetEdgeTable (void)
#ifndef USE_INTEL_ASM #ifndef USE_INTEL_ASM
void static void
D_PolysetRecursiveTriangle (int *lp1, int *lp2, int *lp3) D_PolysetRecursiveTriangle (int *lp1, int *lp2, int *lp3)
{ {
int *temp; int *temp;
@ -250,7 +250,7 @@ D_PolysetRecursiveTriangle (int *lp1, int *lp2, int *lp3)
} }
void static void
D_DrawSubdiv (void) D_DrawSubdiv (void)
{ {
mtriangle_t *ptri; mtriangle_t *ptri;
@ -302,7 +302,7 @@ D_DrawSubdiv (void)
} }
void static void
D_DrawNonSubdiv (void) D_DrawNonSubdiv (void)
{ {
mtriangle_t *ptri; mtriangle_t *ptri;

View file

@ -253,7 +253,7 @@ R_StepActiveU (edge_t *pedge)
#ifndef USE_INTEL_ASM #ifndef USE_INTEL_ASM
void static void
R_LeadingEdge (edge_t *edge) R_LeadingEdge (edge_t *edge)
{ {
espan_t *span; espan_t *span;
@ -362,6 +362,64 @@ R_LeadingEdge (edge_t *edge)
} }
} }
static void
R_TrailingEdge (surf_t *surf, edge_t *edge)
{
espan_t *span;
int iu;
// don't generate a span if this is an inverted span, with the end edge
// preceding the start edge (that is, we haven't seen the start edge yet)
if (--surf->spanstate == 0) {
if (surf->insubmodel)
r_bmodelactive--;
if (surf == surfaces[1].next) {
// emit a span (current top going away)
iu = edge->u >> 20;
if (iu > surf->last_u) {
span = span_p++;
span->u = surf->last_u;
span->count = iu - span->u;
span->v = current_iv;
span->pnext = surf->spans;
surf->spans = span;
}
// set last_u on the surface below
surf->next->last_u = iu;
}
surf->prev->next = surf->next;
surf->next->prev = surf->prev;
}
}
static void
R_CleanupSpan (void)
{
surf_t *surf;
int iu;
espan_t *span;
// now that we've reached the right edge of the screen, we're done with any
// unfinished surfaces, so emit a span for whatever's on top
surf = surfaces[1].next;
iu = edge_tail_u_shift20;
if (iu > surf->last_u) {
span = span_p++;
span->u = surf->last_u;
span->count = iu - span->u;
span->v = current_iv;
span->pnext = surf->spans;
surf->spans = span;
}
// reset spanstate for all surfaces in the surface stack
do {
surf->spanstate = 0;
surf = surf->next;
} while (surf != &surfaces[1]);
}
void void
R_GenerateSpans (void) R_GenerateSpans (void)
{ {

View file

@ -116,7 +116,7 @@ R_ClipSpriteFace (int nump, clipplane_t *pclipplane)
if (dists[i] == 0 || dists[i + 1] == 0) if (dists[i] == 0 || dists[i + 1] == 0)
continue; continue;
#if __APPLE_CC__ == 1173 #if __APPLE_CC__ <= 1175
// bug in gcc (GCC) 3.1 20020420 (prerelease) for darwin // bug in gcc (GCC) 3.1 20020420 (prerelease) for darwin
if ((dists[i] > 0) && (dists[i + 1] > 0)) if ((dists[i] > 0) && (dists[i + 1] > 0))
continue; continue;