- More sky changes: Textures taller than 200 pixels but shorter than 241
are scaled to the height of a 200 pixel tall sky. Skies taller than 240 use the same scale as a 240 tall sky but are shifted down to make the top of the texture align with the top of the screen when looking fully up. Thus, by using a sky texture with a height of 240 or more pixels, the sky will be drawn with square pixels instead of the vertically elongated ones imposed by Doom's native 320x200 resolution. SVN r1978 (trunk)
This commit is contained in:
parent
e0734b3c2d
commit
84fda053ba
3 changed files with 45 additions and 13 deletions
|
|
@ -866,6 +866,14 @@ static void R_DrawSky (visplane_t *pl)
|
|||
{ // The texture does not tile nicely
|
||||
frontyScale = DivScale16 (skyscale, frontyScale);
|
||||
frontiScale = DivScale32 (1, frontyScale);
|
||||
// Sodding crap. Fixed point sucks when you want precision.
|
||||
// TODO (if I'm feeling adventurous): Rewrite the renderer to use floating point
|
||||
// coordinates to keep as much precision as possible until the final
|
||||
// rasterization stage so fudges like this aren't needed.
|
||||
if (viewheight <= 600)
|
||||
{
|
||||
skymid -= FRACUNIT;
|
||||
}
|
||||
R_DrawSkyStriped (pl);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue