Couple of things from JonoF. Incidentally, they are commented out. This commit sucks. :D

git-svn-id: https://svn.eduke32.com/eduke32@118 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2006-04-26 19:32:18 +00:00
parent e316013c1d
commit dbd7df89de
3 changed files with 18 additions and 16 deletions

View file

@ -6093,10 +6093,6 @@ void drawmapview(long dax, long day, long zoome, short ang)
long bakgxvect, bakgyvect, sortnum, gap, npoints;
long xvect, yvect, xvect2, yvect2, daslope;
#ifdef POLYMOST
//if (rendmode == 3) return;
#endif
beforedrawrooms = 0;
clearbuf(&gotsector[0],(long)((numsectors+31)>>5),0L);
@ -6178,7 +6174,7 @@ void drawmapview(long dax, long day, long zoome, short ang)
if (palookup[sec->floorpal] != globalpalwritten)
{
globalpalwritten = palookup[sec->floorpal];
if (!globalpalwritten) globalpalwritten = palookup[globalpal]; // JBF: fixes null-pointer crash
if (!globalpalwritten) globalpalwritten = palookup[0]; // JBF: fixes null-pointer crash
setpalookupaddress(globalpalwritten);
}
globalpicnum = sec->floorpicnum;
@ -9897,11 +9893,13 @@ void drawline256(long x1, long y1, long x2, long y2, char col)
setpolymost2dview(); // JBF 20040205: more efficient setup
//bglEnable(GL_BLEND); // When using line antialiasing, this is needed
bglBegin(GL_LINES);
bglColor4ub(p.r,p.g,p.b,255);
bglVertex2f((float)x1/4096.0,(float)y1/4096.0);
bglVertex2f((float)x2/4096.0,(float)y2/4096.0);
bglEnd();
//bglDisable(GL_BLEND);
return;
}

View file

@ -1,15 +1,16 @@
#ifdef __APPLE__
# include <jfaud/jfaud.hpp>
#else
# include "jfaud.hpp"
#endif
#include <ctype.h>
#include "compat.h"
#include "baselayer.h"
#include "cache1d.h"
typedef uint64 uint64_t;
#ifdef __APPLE__
# include <jfaud/jfaud.hpp>
#else
# include "jfaud.hpp"
#endif
extern "C" {
void initsb(char,char,long,char,char,char,char);
void uninitsb(void);

View file

@ -543,6 +543,9 @@ void polymost_glinit()
bglBlendFunc(GL_SRC_ALPHA,GL_ONE_MINUS_SRC_ALPHA);
//bglHint(GL_LINE_SMOOTH_HINT, GL_NICEST);
//bglEnable(GL_LINE_SMOOTH);
if (glmultisample > 0 && glinfo.multisample) {
if (glinfo.nvmultisamplehint)
bglHint(GL_MULTISAMPLE_FILTER_HINT_NV, glnvmultisamplehint ? GL_NICEST:GL_FASTEST);
@ -2755,11 +2758,11 @@ static void polymost_drawalls (long bunch)
if ((oy < cy0) && (oy < cy1)) domost(x1,oy,x0,oy);
else if ((oy < cy0) != (oy < cy1))
{ /* cy1 cy0
// / \
//oy---------- oy---------
// / \
// cy0 cy1
*/
// / \
//oy---------- oy---------
// / \
// cy0 cy1
*/
ox = (oy-cy0)*(x1-x0)/(cy1-cy0) + x0;
if (oy < cy0) { domost(ox,oy,x0,oy); domost(x1,cy1,ox,oy); }
else { domost(ox,oy,x0,cy0); domost(x1,oy,ox,oy); }