vkQuake2 doxygen  1.0 dev
r_scan.c File Reference
#include "r_local.h"
#include "r_dither.h"

Go to the source code of this file.

Macros

#define WRITEPDEST(i)   { pdest[i] = *(pbase + (s >> 16) + (t >> 16) * cachewidth); s+=sstep; t+=tstep;}
 

Functions

void D_DrawTurbulent8Span (espan_t *pspan)
 
void D_WarpScreen (void)
 
void Turbulent8 (espan_t *pspan)
 
void NonTurbulent8 (espan_t *pspan)
 
void D_DrawSpans16 (espan_t *pspan)
 
void D_DrawZSpans (espan_t *pspan)
 

Variables

static int count
 
static int spancount
 
static bytepbase
 
static bytepdest
 
static fixed16_t s
 
static fixed16_t t
 
static fixed16_t snext
 
static fixed16_t tnext
 
static fixed16_t sstep
 
static fixed16_t tstep
 
static float sdivz
 
static float tdivz
 
static float zi
 
static float z
 
static float du
 
static float dv
 
static float spancountminus1
 
static float sdivzstepu
 
static float tdivzstepu
 
static float zistepu
 
static int izi
 
static int izistep
 
static short * pz
 
static byter_turb_pbase
 
static byter_turb_pdest
 
static fixed16_t r_turb_s
 
static fixed16_t r_turb_t
 
static fixed16_t r_turb_sstep
 
static fixed16_t r_turb_tstep
 
static int r_turb_spancount
 
intr_turb_turb
 

Macro Definition Documentation

◆ WRITEPDEST

#define WRITEPDEST (   i)    { pdest[i] = *(pbase + (s >> 16) + (t >> 16) * cachewidth); s+=sstep; t+=tstep;}

Definition at line 427 of file r_scan.c.

Function Documentation

◆ D_DrawSpans16()

void D_DrawSpans16 ( espan_t pspan)

Definition at line 429 of file r_scan.c.

430 {
431  sstep = 0; // keep compiler happy
432  tstep = 0; // ditto
433 
434  pbase = (byte *)cacheblock;
435  sdivzstepu = d_sdivzstepu * 16;
436  tdivzstepu = d_tdivzstepu * 16;
437  zistepu = d_zistepu * 16;
438 
439  do
440  {
441  pdest = (byte *)((byte *)d_viewbuffer + (r_screenwidth * pspan->v) + pspan->u);
442  count = pspan->count >> 4;
443 
444  spancount = pspan->count % 16;
445 
446  // calculate the initial s/z, t/z, 1/z, s, and t and clamp
447  du = (float)pspan->u;
448  dv = (float)pspan->v;
449 
453  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
454 
455  s = (int)(sdivz * z) + sadjust;
456  if (s < 0) s = 0;
457  else if (s > bbextents) s = bbextents;
458 
459  t = (int)(tdivz * z) + tadjust;
460  if (t < 0) t = 0;
461  else if (t > bbextentt) t = bbextentt;
462 
463  while (count-- > 0) // Manoel Kasimier
464  {
465  sdivz += sdivzstepu;
466  tdivz += tdivzstepu;
467  zi += zistepu;
468  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
469 
470  snext = (int)(sdivz * z) + sadjust;
471  if (snext < 16) snext = 16;
472  else if (snext > bbextents) snext = bbextents;
473 
474  tnext = (int)(tdivz * z) + tadjust;
475  if (tnext < 16) tnext = 16;
476  else if (tnext > bbextentt) tnext = bbextentt;
477 
478  sstep = (snext - s) >> 4;
479  tstep = (tnext - t) >> 4;
480  pdest += 16;
481  WRITEPDEST(-16);
482  WRITEPDEST(-15);
483  WRITEPDEST(-14);
484  WRITEPDEST(-13);
485  WRITEPDEST(-12);
486  WRITEPDEST(-11);
487  WRITEPDEST(-10);
488  WRITEPDEST(-9);
489  WRITEPDEST(-8);
490  WRITEPDEST(-7);
491  WRITEPDEST(-6);
492  WRITEPDEST(-5);
493  WRITEPDEST(-4);
494  WRITEPDEST(-3);
495  WRITEPDEST(-2);
496  WRITEPDEST(-1);
497  s = snext;
498  t = tnext;
499  }
500  if (spancount > 0)
501  {
502  spancountminus1 = (float)(spancount - 1);
506  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
507 
508  snext = (int)(sdivz * z) + sadjust;
509  if (snext < 16) snext = 16;
510  else if (snext > bbextents) snext = bbextents;
511 
512  tnext = (int)(tdivz * z) + tadjust;
513  if (tnext < 16) tnext = 16;
514  else if (tnext > bbextentt) tnext = bbextentt;
515 
516  if (spancount > 1)
517  {
518  sstep = (snext - s) / (spancount - 1);
519  tstep = (tnext - t) / (spancount - 1);
520  }
521 
522  pdest += spancount;
523 
524  switch (spancount)
525  {
526  case 16:
527  WRITEPDEST(-16);
528  case 15:
529  WRITEPDEST(-15);
530  case 14:
531  WRITEPDEST(-14);
532  case 13:
533  WRITEPDEST(-13);
534  case 12:
535  WRITEPDEST(-12);
536  case 11:
537  WRITEPDEST(-11);
538  case 10:
539  WRITEPDEST(-10);
540  case 9:
541  WRITEPDEST(-9);
542  case 8:
543  WRITEPDEST(-8);
544  case 7:
545  WRITEPDEST(-7);
546  case 6:
547  WRITEPDEST(-6);
548  case 5:
549  WRITEPDEST(-5);
550  case 4:
551  WRITEPDEST(-4);
552  case 3:
553  WRITEPDEST(-3);
554  case 2:
555  WRITEPDEST(-2);
556  case 1:
557  WRITEPDEST(-1);
558  break;
559  }
560  }
561  } while ((pspan = pspan->pnext) != NULL);
562 }

Referenced by D_SkySurf(), and D_SolidSurf().

◆ D_DrawTurbulent8Span()

void D_DrawTurbulent8Span ( espan_t pspan)

Definition at line 112 of file r_scan.c.

113 {
114  static int sturb, tturb;
115 
116  // float ditht, diths;
117 
118  do
119  {
120  if (sw_transmooth->value /*> 1*/)
121  {
122  sturb = r_turb_s + r_turb_turb[(r_turb_t >> 16)&(CYCLE - 1)];
123  tturb = r_turb_t + r_turb_turb[(r_turb_s >> 16)&(CYCLE - 1)];
124 
125  DitherKernel2(sturb, tturb, pspan->u + r_turb_spancount, pspan->v);
126 
127  tturb = (tturb >> 16) & 63;
128  sturb = (sturb >> 16) & 63;
129  }
130  else
131  {
132  sturb = ((r_turb_s + r_turb_turb[(r_turb_t >> 16)&(CYCLE - 1)]) >> 16) & 63;
133  tturb = ((r_turb_t + r_turb_turb[(r_turb_s >> 16)&(CYCLE - 1)]) >> 16) & 63;
134  }
135 
136  *r_turb_pdest++ = *(r_turb_pbase + (tturb << 6) + sturb);
139  } while (--r_turb_spancount > 0);
140 }

Referenced by NonTurbulent8(), and Turbulent8().

◆ D_DrawZSpans()

void D_DrawZSpans ( espan_t pspan)

Definition at line 574 of file r_scan.c.

575 {
576  short *pdest;
577  unsigned ltemp;
578 
579  // FIXME: check for clamping/range problems
580  // we count on FP exceptions being turned off to avoid range problems
581  izistep = (int)(d_zistepu * 0x8000 * 0x10000);
582 
583  do
584  {
585  pdest = d_pzbuffer + (d_zwidth * pspan->v) + pspan->u;
586 
587  count = pspan->count;
588 
589  // calculate the initial 1/z
590  du = (float)pspan->u;
591  dv = (float)pspan->v;
592 
594  // we count on FP exceptions being turned off to avoid range problems
595  izi = (int)(zi * 0x8000 * 0x10000);
596 
597  if ((intptr_t)pdest & 0x02)
598  {
599  *pdest++ = (short)(izi >> 16);
600  izi += izistep;
601  count--;
602  }
603 
604  if ((spancount = count >> 1) > 0)
605  {
606  do
607  {
608  ltemp = izi >> 16;
609  izi += izistep;
610  ltemp |= izi & 0xFFFF0000;
611  izi += izistep;
612  *(int *)pdest = ltemp;
613  pdest += 2;
614  } while (--spancount > 0);
615  }
616 
617  if (count & 1)
618  *pdest = (short)(izi >> 16);
619 
620  } while ((pspan = pspan->pnext) != NULL);
621 }

Referenced by D_BackgroundSurf(), D_DrawflatSurfaces(), D_SkySurf(), D_SolidSurf(), and D_TurbulentSurf().

◆ D_WarpScreen()

void D_WarpScreen ( void  )

Definition at line 52 of file r_scan.c.

53 {
54  static int w, h;
55  static int u, v, u2, v2;
56  static byte *dest;
57  static int *turb;
58  static int *col;
59  static byte **row;
60 
61  static int cached_width, cached_height;
62  static byte *rowptr[4200 + AMP2 * 2]; //qb: 4K... was 1200
63  static int column[2400 + AMP2 * 2]; //qb: 4K... was 1600
64 
65  //
66  // these are constant over resolutions, and can be saved
67  //
69  h = r_newrefdef.height;
70  if (w != cached_width || h != cached_height)
71  {
72  cached_width = w;
73  cached_height = h;
74  for (v = 0; v < h + AMP2 * 2; v++)
75  {
76  v2 = (int)((float)v / (h + AMP2 * 2) * r_refdef.vrect.height);
77  rowptr[v] = r_warpbuffer + (r_warpwidth * v2);
78  }
79 
80  for (u = 0; u < w + AMP2 * 2; u++)
81  {
82  u2 = (int)((float)u / (w + AMP2 * 2) * r_refdef.vrect.width);
83  column[u] = u2;
84  }
85  }
86 
87  turb = intsintable + ((int)(r_newrefdef.time*SPEED)&(CYCLE - 1));
89 
90  for (v = 0; v < h; v++, dest += vid.rowbytes)
91  {
92  col = &column[turb[v]];
93  row = &rowptr[v];
94  for (u = 0; u < w; u += 4)
95  {
96  dest[u + 0] = row[turb[u + 0]][col[u + 0]];
97  dest[u + 1] = row[turb[u + 1]][col[u + 1]];
98  dest[u + 2] = row[turb[u + 2]][col[u + 2]];
99  dest[u + 3] = row[turb[u + 3]][col[u + 3]];
100  }
101  }
102 }

Referenced by R_RenderFrame().

◆ NonTurbulent8()

void NonTurbulent8 ( espan_t pspan)

Definition at line 281 of file r_scan.c.

282 {
283 
284  // r_turb_turb = sintable + ((int)(r_newrefdef.time*SPEED)&(CYCLE-1));
286 
287  r_turb_sstep = 0; // keep compiler happy
288  r_turb_tstep = 0; // ditto
289 
290  r_turb_pbase = (unsigned char *)cacheblock;
291 
292  sdivzstepu = d_sdivzstepu * 16;
293  tdivzstepu = d_tdivzstepu * 16;
294  zistepu = d_zistepu * 16;
295 
296  do
297  {
298  r_turb_pdest = (unsigned char *)((byte *)d_viewbuffer +
299  (r_screenwidth * pspan->v) + pspan->u);
300 
301  count = pspan->count;
302 
303  // calculate the initial s/z, t/z, 1/z, s, and t and clamp
304  du = (float)pspan->u;
305  dv = (float)pspan->v;
306 
310  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
311 
312  r_turb_s = (int)(sdivz * z) + sadjust;
313  if (r_turb_s > bbextents)
315  else if (r_turb_s < 0)
316  r_turb_s = 0;
317 
318  r_turb_t = (int)(tdivz * z) + tadjust;
319  if (r_turb_t > bbextentt)
321  else if (r_turb_t < 0)
322  r_turb_t = 0;
323 
324  do
325  {
326  // calculate s and t at the far end of the span
327  if (count >= 16)
328  r_turb_spancount = 16;
329  else
331 
333 
334  if (count)
335  {
336  // calculate s/z, t/z, zi->fixed s and t at far end of span,
337  // calculate s and t steps across span by shifting
338  sdivz += sdivzstepu;
339  tdivz += tdivzstepu;
340  zi += zistepu;
341  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
342 
343  snext = (int)(sdivz * z) + sadjust;
344  if (snext > bbextents)
345  snext = bbextents;
346  else if (snext < 16)
347  snext = 16; // prevent round-off error on <0 steps from
348  // from causing overstepping & running off the
349  // edge of the texture
350 
351  tnext = (int)(tdivz * z) + tadjust;
352  if (tnext > bbextentt)
353  tnext = bbextentt;
354  else if (tnext < 16)
355  tnext = 16; // guard against round-off error on <0 steps
356 
357  r_turb_sstep = (snext - r_turb_s) >> 4;
358  r_turb_tstep = (tnext - r_turb_t) >> 4;
359  }
360  else
361  {
362  // calculate s/z, t/z, zi->fixed s and t at last pixel in span (so
363  // can't step off polygon), clamp, calculate s and t steps across
364  // span by division, biasing steps low so we don't run off the
365  // texture
366  spancountminus1 = (float)(r_turb_spancount - 1);
370  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
371  snext = (int)(sdivz * z) + sadjust;
372  if (snext > bbextents)
373  snext = bbextents;
374  else if (snext < 16)
375  snext = 16; // prevent round-off error on <0 steps from
376  // from causing overstepping & running off the
377  // edge of the texture
378 
379  tnext = (int)(tdivz * z) + tadjust;
380  if (tnext > bbextentt)
381  tnext = bbextentt;
382  else if (tnext < 16)
383  tnext = 16; // guard against round-off error on <0 steps
384 
385  if (r_turb_spancount > 1)
386  {
389  }
390  }
391 
392  r_turb_s = r_turb_s & ((CYCLE << 16) - 1);
393  r_turb_t = r_turb_t & ((CYCLE << 16) - 1);
394 
395  D_DrawTurbulent8Span(pspan);
396 
397  r_turb_s = snext;
398  r_turb_t = tnext;
399 
400  } while (count > 0);
401 
402  } while ((pspan = pspan->pnext) != NULL);
403 }

Referenced by D_TurbulentSurf().

◆ Turbulent8()

void Turbulent8 ( espan_t pspan)

Definition at line 150 of file r_scan.c.

151 {
152 
154 
155  r_turb_sstep = 0; // keep compiler happy
156  r_turb_tstep = 0; // ditto
157 
158  r_turb_pbase = (unsigned char *)cacheblock;
159 
160  sdivzstepu = d_sdivzstepu * 16;
161  tdivzstepu = d_tdivzstepu * 16;
162  zistepu = d_zistepu * 16;
163 
164  do
165  {
166  r_turb_pdest = (unsigned char *)((byte *)d_viewbuffer +
167  (r_screenwidth * pspan->v) + pspan->u);
168 
169  count = pspan->count;
170 
171  // calculate the initial s/z, t/z, 1/z, s, and t and clamp
172  du = (float)pspan->u;
173  dv = (float)pspan->v;
174 
178  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
179 
180  r_turb_s = (int)(sdivz * z) + sadjust;
181  if (r_turb_s > bbextents)
183  else if (r_turb_s < 0)
184  r_turb_s = 0;
185 
186  r_turb_t = (int)(tdivz * z) + tadjust;
187  if (r_turb_t > bbextentt)
189  else if (r_turb_t < 0)
190  r_turb_t = 0;
191 
192  do
193  {
194  // calculate s and t at the far end of the span
195  if (count >= 16)
196  r_turb_spancount = 16;
197  else
199 
201 
202  if (count)
203  {
204  // calculate s/z, t/z, zi->fixed s and t at far end of span,
205  // calculate s and t steps across span by shifting
206  sdivz += sdivzstepu;
207  tdivz += tdivzstepu;
208  zi += zistepu;
209  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
210 
211  snext = (int)(sdivz * z) + sadjust;
212  if (snext > bbextents)
213  snext = bbextents;
214  else if (snext < 16)
215  snext = 16; // prevent round-off error on <0 steps from
216  // from causing overstepping & running off the
217  // edge of the texture
218 
219  tnext = (int)(tdivz * z) + tadjust;
220  if (tnext > bbextentt)
221  tnext = bbextentt;
222  else if (tnext < 16)
223  tnext = 16; // guard against round-off error on <0 steps
224 
225  r_turb_sstep = (snext - r_turb_s) >> 4;
226  r_turb_tstep = (tnext - r_turb_t) >> 4;
227  }
228  else
229  {
230  // calculate s/z, t/z, zi->fixed s and t at last pixel in span (so
231  // can't step off polygon), clamp, calculate s and t steps across
232  // span by division, biasing steps low so we don't run off the
233  // texture
234  spancountminus1 = (float)(r_turb_spancount - 1);
238  z = (float)0x10000 / zi; // prescale to 16.16 fixed-point
239  snext = (int)(sdivz * z) + sadjust;
240  if (snext > bbextents)
241  snext = bbextents;
242  else if (snext < 16)
243  snext = 16; // prevent round-off error on <0 steps from
244  // from causing overstepping & running off the
245  // edge of the texture
246 
247  tnext = (int)(tdivz * z) + tadjust;
248  if (tnext > bbextentt)
249  tnext = bbextentt;
250  else if (tnext < 16)
251  tnext = 16; // guard against round-off error on <0 steps
252 
253  if (r_turb_spancount > 1)
254  {
257  }
258  }
259 
260  r_turb_s = r_turb_s & ((CYCLE << 16) - 1);
261  r_turb_t = r_turb_t & ((CYCLE << 16) - 1);
262 
263  D_DrawTurbulent8Span(pspan);
264 
265  r_turb_s = snext;
266  r_turb_t = tnext;
267 
268  } while (count > 0);
269 
270  } while ((pspan = pspan->pnext) != NULL);
271 }

Referenced by D_TurbulentSurf().

Variable Documentation

◆ count

int count
static

Definition at line 28 of file r_scan.c.

Referenced by D_DrawSpans16(), D_DrawZSpans(), NonTurbulent8(), and Turbulent8().

◆ du

◆ dv

◆ izi

int izi
static

Definition at line 33 of file r_scan.c.

Referenced by D_DrawZSpans().

◆ izistep

int izistep
static

Definition at line 33 of file r_scan.c.

Referenced by D_DrawZSpans().

◆ pbase

byte* pbase
static

Definition at line 29 of file r_scan.c.

Referenced by D_DrawSpans16().

◆ pdest

byte * pdest
static

Definition at line 29 of file r_scan.c.

Referenced by D_DrawSpans16(), and D_DrawZSpans().

◆ pz

short* pz
static

Definition at line 34 of file r_scan.c.

◆ r_turb_pbase

byte* r_turb_pbase
static

Definition at line 36 of file r_scan.c.

Referenced by D_DrawTurbulent8Span(), NonTurbulent8(), and Turbulent8().

◆ r_turb_pdest

byte * r_turb_pdest
static

Definition at line 36 of file r_scan.c.

Referenced by D_DrawTurbulent8Span(), NonTurbulent8(), and Turbulent8().

◆ r_turb_s

fixed16_t r_turb_s
static

Definition at line 37 of file r_scan.c.

Referenced by D_DrawTurbulent8Span(), NonTurbulent8(), and Turbulent8().

◆ r_turb_spancount

int r_turb_spancount
static

Definition at line 38 of file r_scan.c.

Referenced by D_DrawTurbulent8Span(), NonTurbulent8(), and Turbulent8().

◆ r_turb_sstep

fixed16_t r_turb_sstep
static

Definition at line 37 of file r_scan.c.

Referenced by D_DrawTurbulent8Span(), NonTurbulent8(), and Turbulent8().

◆ r_turb_t

fixed16_t r_turb_t
static

Definition at line 37 of file r_scan.c.

Referenced by D_DrawTurbulent8Span(), NonTurbulent8(), and Turbulent8().

◆ r_turb_tstep

fixed16_t r_turb_tstep
static

Definition at line 37 of file r_scan.c.

Referenced by D_DrawTurbulent8Span(), NonTurbulent8(), and Turbulent8().

◆ r_turb_turb

◆ s

fixed16_t s
static

Definition at line 30 of file r_scan.c.

Referenced by BrightnessCallback(), CalcSurfaceExtents(), Cbuf_AddEarlyCommands(), Cbuf_AddLateCommands(), CL_ConnectionlessPacket(), CL_Heatbeam(), CL_LoadClientinfo(), CL_ParseClientinfo(), CL_ParseConfigString(), CL_ParseNuke(), CL_ParseServerMessage(), CL_ParseStatusMessage(), CL_ParseSteam(), CL_ParseWidow(), CL_ProcessSustain(), CL_RailTrail(), CL_SetLightstyle(), ClientUserinfoChanged(), CM_BoxLeafnums_r(), CM_InitBoxHull(), Cmd_Alias_f(), Cmd_Drop_f(), Cmd_Use_f(), COM_FileBase(), COM_FilePath(), CompleteCommand(), Con_DrawNotify(), crc32_init(), Cvar_InfoValidate(), D_BackgroundSurf(), D_DrawflatSurfaces(), D_DrawSpans16(), D_DrawSurfaces(), D_SkySurf(), D_SolidSurf(), D_TurbulentSurf(), do_floor(), DrawAltString(), DrawSkyPolygon(), DrawString(), DrawTextureChains(), ED_CallSpawn(), EmitWaterPolys(), EndDMLevel(), FS_ListFiles(), FS_NextPath(), FS_Path_f(), G_Find(), GL_BuildPolygonFromSurface(), GL_Upload8(), Info_Print(), Info_RemoveKey(), Info_SetValueForKey(), Info_Validate(), Info_ValueForKey(), is_whole_packet_present(), logClearStencil(), logTexCoord1d(), logTexCoord1f(), logTexCoord1i(), logTexCoord1s(), logTexCoord2d(), logTexCoord2f(), logTexCoord2i(), logTexCoord2s(), logTexCoord3d(), logTexCoord3f(), logTexCoord3i(), logTexCoord3s(), logTexCoord4d(), logTexCoord4f(), logTexCoord4i(), logTexCoord4s(), M_Keydown(), MakeSkyVec(), Mat_Rotate(), Mat_Scale(), Menu_SelectItem(), Menu_SlideItem(), Mod_LoadAliasModel(), MSG_WriteString(), NET_AdrToString(), NET_StringToAdr(), NET_StringToSockaddr(), NetadrToSockadr(), PF_WriteString(), PlayerConfig_ScanDirectories(), PlayerTrail_Add(), PM_AddCurrents(), PrecacheItem(), Qcommon_Frame(), Qcommon_Init(), R_AddDynamicLights(), R_AddDynamicLightsRGB(), R_DrawAliasModel(), R_DrawAlphaSurfaces(), R_DrawSpanlet33Stipple(), R_DrawSpanlet66Stipple(), R_PolysetUpdateTables(), R_RotateBmodel(), R_ScanEdges(), RecursiveLightPoint(), RecursiveLightPointColor(), S_AliasName(), S_LoadSound(), S_PaintChannels(), SCR_CenterPrint(), SCR_ExecuteLayoutString(), ScreenSizeCallback(), Separator_Draw(), SetStringHighBit(), SHOWNET(), Slider_DoSlide(), Slider_Draw(), SNDDMA_GetDMAPos(), SockadrToNetadr(), SpinControl_DoEnter(), SpinControl_DoSlide(), SpinControl_Draw(), StartServer_MenuInit(), StringToFilter(), SubdividePolygon(), SV_ConnectionlessPacket(), SV_ExecuteClientMessage(), SV_ExecuteUserCommand(), SV_SetPlayer(), SV_Status_f(), SV_WipeSavegame(), Vk_BuildPolygonFromSurface(), Vk_Upload8(), vorbis_decode_packet_rest(), vorbis_find_page(), and vtos().

◆ sdivz

float sdivz
static

Definition at line 31 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), R_PolygonDrawSpans(), and Turbulent8().

◆ sdivzstepu

float sdivzstepu
static

Definition at line 32 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), and Turbulent8().

◆ snext

fixed16_t snext
static

Definition at line 30 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), R_PolygonDrawSpans(), and Turbulent8().

◆ spancount

int spancount
static

Definition at line 28 of file r_scan.c.

Referenced by D_DrawSpans16(), and D_DrawZSpans().

◆ spancountminus1

float spancountminus1
static

Definition at line 31 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), R_PolygonDrawSpans(), and Turbulent8().

◆ sstep

fixed16_t sstep
static

Definition at line 30 of file r_scan.c.

Referenced by D_DrawSpans16().

◆ t

fixed16_t t
static

Definition at line 30 of file r_scan.c.

Referenced by D_DrawSpans16().

◆ tdivz

float tdivz
static

Definition at line 31 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), R_PolygonDrawSpans(), and Turbulent8().

◆ tdivzstepu

float tdivzstepu
static

Definition at line 32 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), and Turbulent8().

◆ tnext

fixed16_t tnext
static

Definition at line 30 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), R_PolygonDrawSpans(), and Turbulent8().

◆ tstep

fixed16_t tstep
static

Definition at line 30 of file r_scan.c.

Referenced by D_DrawSpans16().

◆ z

float z
static

Definition at line 31 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), and Turbulent8().

◆ zi

float zi
static

Definition at line 31 of file r_scan.c.

Referenced by D_DrawSpans16(), D_DrawZSpans(), NonTurbulent8(), and Turbulent8().

◆ zistepu

float zistepu
static

Definition at line 32 of file r_scan.c.

Referenced by D_DrawSpans16(), NonTurbulent8(), and Turbulent8().

zistepu
static float zistepu
Definition: r_scan.c:32
d_sdivzorigin
float d_sdivzorigin
Definition: r_main.c:190
zi
static float zi
Definition: r_scan.c:31
r_turb_turb
int * r_turb_turb
Definition: r_scan.c:40
int
CONST PIXELFORMATDESCRIPTOR int
Definition: qgl_win.c:35
CYCLE
#define CYCLE
Definition: asm_draw.h:16
WRITEPDEST
#define WRITEPDEST(i)
Definition: r_scan.c:427
viddef_t::buffer
pixel_t * buffer
Definition: r_local.h:94
v
GLdouble v
Definition: qgl_win.c:143
d_tdivzstepv
float d_tdivzstepv
Definition: r_local.h:518
spancountminus1
static float spancountminus1
Definition: r_scan.c:31
vrect_s::height
int height
Definition: vid.h:24
pdest
static byte * pdest
Definition: r_scan.c:29
d_viewbuffer
pixel_t * d_viewbuffer
Definition: r_main.c:196
refdef_t::y
int y
Definition: ref.h:104
d_tdivzorigin
float d_tdivzorigin
Definition: r_local.h:519
espan_s::pnext
struct espan_s * pnext
Definition: r_local.h:407
count
static int count
Definition: r_scan.c:28
sintable
int sintable[4200]
Definition: r_rast.c:47
sstep
static fixed16_t sstep
Definition: r_scan.c:30
SPEED
#define SPEED
Definition: r_local.h:241
t
static fixed16_t t
Definition: r_scan.c:30
r_turb_t
static fixed16_t r_turb_t
Definition: r_scan.c:37
tdivzstepu
static float tdivzstepu
Definition: r_scan.c:32
intsintable
int intsintable[4200]
Definition: r_rast.c:48
D_DrawTurbulent8Span
void D_DrawTurbulent8Span(espan_t *pspan)
Definition: r_scan.c:112
dv
static float dv
Definition: r_scan.c:31
tdivz
static float tdivz
Definition: r_scan.c:31
espan_s::count
int count
Definition: r_local.h:406
snext
static fixed16_t snext
Definition: r_scan.c:30
u
static int u
Definition: r_part.c:472
d_ziorigin
float d_ziorigin
Definition: r_local.h:519
viddef_t::rowbytes
int rowbytes
Definition: r_local.h:97
r_turb_pbase
static byte * r_turb_pbase
Definition: r_scan.c:36
DitherKernel2
#define DitherKernel2(u, v, X, Y)
Definition: r_dither.h:36
v2
GLdouble GLdouble GLint GLint GLdouble GLdouble v2
Definition: qgl_win.c:227
bbextentt
fixed16_t bbextentt
Definition: r_local.h:522
espan_s::v
int v
Definition: r_local.h:406
izistep
static int izistep
Definition: r_scan.c:33
r_turb_s
static fixed16_t r_turb_s
Definition: r_scan.c:37
tstep
static fixed16_t tstep
Definition: r_scan.c:30
sadjust
fixed16_t sadjust
Definition: r_local.h:732
d_tdivzstepu
float d_tdivzstepu
Definition: r_local.h:517
r_newrefdef
refdef_t r_newrefdef
Definition: r_main.c:38
tnext
static fixed16_t tnext
Definition: r_scan.c:30
cvar_s::value
float value
Definition: q_shared.h:331
espan_s::u
int u
Definition: r_local.h:406
du
static float du
Definition: r_scan.c:31
NULL
#define NULL
Definition: q_shared.h:67
bbextents
fixed16_t bbextents
Definition: r_local.h:733
refdef_t::time
float time
Definition: ref.h:109
d_zistepv
float d_zistepv
Definition: r_local.h:518
r_turb_tstep
static fixed16_t r_turb_tstep
Definition: r_scan.c:37
refdef_t::height
int height
Definition: ref.h:104
r_screenwidth
int r_screenwidth
Definition: r_main.c:87
d_zistepu
float d_zistepu
Definition: r_local.h:517
AMP2
#define AMP2
Definition: r_local.h:240
s
static fixed16_t s
Definition: r_scan.c:30
sdivz
static float sdivz
Definition: r_scan.c:31
oldrefdef_t::vrect
vrect_t vrect
Definition: r_local.h:118
vrect_s::width
int width
Definition: vid.h:24
r_turb_pdest
static byte * r_turb_pdest
Definition: r_scan.c:36
u2
GLdouble GLdouble u2
Definition: qgl_win.c:225
r_warpbuffer
byte * r_warpbuffer
Definition: r_main.c:45
sdivzstepu
static float sdivzstepu
Definition: r_scan.c:32
z
static float z
Definition: r_scan.c:31
d_zwidth
unsigned int d_zwidth
Definition: r_local.h:538
d_sdivzstepu
float d_sdivzstepu
Definition: r_main.c:188
r_turb_sstep
static fixed16_t r_turb_sstep
Definition: r_scan.c:37
refdef_t::width
int width
Definition: ref.h:104
r_warpwidth
int r_warpwidth
Definition: r_main.c:46
spancount
static int spancount
Definition: r_scan.c:28
w
GLdouble GLdouble GLdouble w
Definition: qgl_win.c:291
d_sdivzstepv
float d_sdivzstepv
Definition: r_main.c:189
refdef_t::x
int x
Definition: ref.h:104
pbase
static byte * pbase
Definition: r_scan.c:29
cacheblock
pixel_t * cacheblock
Definition: r_main.c:194
d_pzbuffer
short * d_pzbuffer
Definition: r_main.c:197
tadjust
fixed16_t tadjust
Definition: r_local.h:521
sw_transmooth
cvar_t * sw_transmooth
Definition: r_main.c:131
izi
static int izi
Definition: r_scan.c:33
r_turb_spancount
static int r_turb_spancount
Definition: r_scan.c:38
r_refdef
oldrefdef_t r_refdef
Definition: r_main.c:80
blanktable
int blanktable[4200]
Definition: r_rast.c:49
vid
viddef_t vid
Definition: r_main.c:24