Inside3D!
     

Compiling Glquake on windows7
Goto page Previous  1, 2, 3
 
Post new topic   Reply to topic    Inside3d Forums Forum Index -> Engine Programming
View previous topic :: View next topic  
Author Message
mh



Joined: 12 Jan 2008
Posts: 909

PostPosted: Sat Apr 10, 2010 10:36 pm    Post subject: Reply with quote

gl_ztrick should be defaulted to 0, gl_clear to 1 and gl_finish to 1 for best behaviour on a modern card. You won't 17 gazillion frames per second but it will run right.

However, I bet that the cause of this problem is that the weapon models are falling foul of R_CullBox. Comment out the call to R_CullBox in R_DrawAliasModel and see if it fixes it. If so, have a thought about a way to do it correctly (such as adding a nocull flag to the entity_t struct or something similar).
_________________
DirectQ Engine - New release 1.8.666a, 9th August 2010
MHQuake Blog (General)
Direct3D 8 Quake Engines
Back to top
View user's profile Send private message Visit poster's website
Charlieguitar



Joined: 29 Mar 2010
Posts: 20

PostPosted: Sun Apr 11, 2010 12:45 am    Post subject: Reply with quote

thats awesome. another fix done. thanks Very Happy

also doing the old quakesrc skybox tutorial, i seem to be having a problem

>.\gl_warp.c(912) : error C2065: 'inumverts' : undeclared identifier

The version of r_drawskychain in the tutorial looks like this

void R_DrawSkyChain (msurface_t *s)

{



msurface_t *fa;
int i;


vec3_t verts[MAX_CLIP_VERTS];

glpoly_t *p;



if (r_skybox.value) // if the skybox value is one, draw the skybox



{

c_sky = 0;

GL_Bind(solidskytexture);



// calculate vertex values for sky box



for (fa=s ; fa ; fa=fa->texturechain)

{

for (p=fa->polys ; p ; p=p->next)

{

for (i=0 ; inumverts ; i++)

{

VectorSubtract (p->verts[i], r_origin, verts[i]);

}

ClipSkyPolygon (p->numverts, verts[0], 0);

}

}



}

else // otherwise, draw the normal quake sky

{

GL_DisableMultitexture();



// used when gl_texsort is on

GL_Bind(solidskytexture);

speedscale = realtime*8;

speedscale -= (int)speedscale & ~127 ;



for (fa=s ; fa ; fa=fa->texturechain)

EmitSkyPolys (fa);



glEnable (GL_BLEND);

GL_Bind (alphaskytexture);

speedscale = realtime*16;

speedscale -= (int)speedscale & ~127 ;



for (fa=s ; fa ; fa=fa->texturechain)

EmitSkyPolys (fa);



glDisable (GL_BLEND);

}

}

Im guessing inumverts just needs to be declared somewhere, i've tried it as an int but the engine crashes on level load so im guessing it needs to be something else?
Back to top
View user's profile Send private message
Charlieguitar



Joined: 29 Mar 2010
Posts: 20

PostPosted: Sun Apr 11, 2010 1:12 am    Post subject: Reply with quote

ignore last post, i figured out that it was a typo and should have been
for (i=0 ; i<p->numverts ; i++)

;D
Back to top
View user's profile Send private message
Charlieguitar



Joined: 29 Mar 2010
Posts: 20

PostPosted: Sun Apr 11, 2010 1:59 am    Post subject: Reply with quote

One thing i'd really love to get going though is the .lit tutorial
http://www.quake-1.com/docs/quakesrc.org/95.html
I followed the instructions to a T but im guessing about 91 errors about syntax and undeclared definitions and such. has anyone else had success with this tutorial? Am i just doing something very silly?
Back to top
View user's profile Send private message
reckless



Joined: 24 Jan 2008
Posts: 390
Location: inside tha debugger

PostPosted: Sun Apr 11, 2010 10:02 am    Post subject: Reply with quote

theres a couple of typos in the old tuts.

there a good pointer but the safest bet is download qip quake (has all those old tutorials implemented with comments) then do a compare if anything on the qsg tutorials look's wrong it most likely is Wink

it does take a bit of work but in the end it will work.

and i agree with mh on the culling problem. especially if you implemented phoenix interpolation tutorial it sometimes goes screwy (most notably on alias models).

there has been quite a lot of fixes through the years listing them all would be a full time job Laughing
Back to top
View user's profile Send private message
reckless



Joined: 24 Jan 2008
Posts: 390
Location: inside tha debugger

PostPosted: Sun Apr 11, 2010 10:06 am    Post subject: Reply with quote

link to qip quake

http://www.inside3d.com/qip/home.shtml
Back to top
View user's profile Send private message
Charlieguitar



Joined: 29 Mar 2010
Posts: 20

PostPosted: Sun Apr 11, 2010 5:33 pm    Post subject: Reply with quote

thanks for the info Very Happy Ive gotten further than last time, but it seems theres some kind of syntax error or typo even in the qip code? Specificly the r_drawaliasmodel function. The one from the tutorial and the one from the qip source both give me syntax errors for some reason.
Back to top
View user's profile Send private message
Charlieguitar



Joined: 29 Mar 2010
Posts: 20

PostPosted: Sun Apr 11, 2010 5:42 pm    Post subject: Reply with quote

getting these errors in both the r_buildlightmap and r_drawaliasmodel functions from QIP and the code from the tutorial
gl_rsurf.c(185) : error C2232: '->value' : left operand has 'struct' type, use '.'

this is line 185
if (r_fullbright->value || !cl.worldmodel->lightdata)

Sad
Back to top
View user's profile Send private message
mh



Joined: 12 Jan 2008
Posts: 909

PostPosted: Sun Apr 11, 2010 6:02 pm    Post subject: Reply with quote

-> for pointers and . for non-pointers. Use .
_________________
DirectQ Engine - New release 1.8.666a, 9th August 2010
MHQuake Blog (General)
Direct3D 8 Quake Engines
Back to top
View user's profile Send private message Visit poster's website
Charlieguitar



Joined: 29 Mar 2010
Posts: 20

PostPosted: Sun Apr 11, 2010 6:06 pm    Post subject: Reply with quote

my bad Very Happy
thanks, that sorted it
Back to top
View user's profile Send private message
reckless



Joined: 24 Jan 2008
Posts: 390
Location: inside tha debugger

PostPosted: Sun Apr 11, 2010 11:45 pm    Post subject: Reply with quote

i guess older msvc was a bit more lenient than newer versions about pointer errors (shame on you ms) Twisted Evil


non the less the qip source is quite good as a starting point for looking up improvements made to quake.

and good to see progress Wink
Back to top
View user's profile Send private message
Tomaz



Joined: 05 Nov 2004
Posts: 49

PostPosted: Mon Apr 12, 2010 6:15 am    Post subject: Reply with quote

reckless wrote:
i guess older msvc was a bit more lenient than newer versions about pointer errors (shame on you ms) Twisted Evil


No it has always errored about using . and -> wrong.
Back to top
View user's profile Send private message
reckless



Joined: 24 Jan 2008
Posts: 390
Location: inside tha debugger

PostPosted: Mon Apr 12, 2010 10:09 pm    Post subject: Reply with quote

was not to be taken seriously hehe.

had an old version of qip on my pc
which worked ok but i tried this one and got same error. allthough im not sure if i had that error sometime and just fixed it then forgot Embarassed
Back to top
View user's profile Send private message
WhiteMagicRaven



Joined: 13 Apr 2010
Posts: 5

PostPosted: Tue Apr 13, 2010 9:21 am    Post subject: Reply with quote

mh wrote:
The old QuakeSrc.org tutorials are here: http://www.quake-1.com/docs/quakesrc.org/

Some of them are slightly ropey (watch out for the ones I wrote!), but a lot of people started out here. The Hexen II ones should also be mostly usable, and even some of the Quake II ones, although you may have to massage the code a little to get things working right (but that's half the fun!)

It's also worthwhile to download the Hexen II and Quake II code as a lot of it is actually usable in Quake.


This is best source port and alive
http://uhexen2.sourceforge.net/
if you click "Links" on main page
you can find more source ports.
I have question:
What other source ports you know?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Inside3d Forums Forum Index -> Engine Programming All times are GMT
Goto page Previous  1, 2, 3
Page 3 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2004 phpBB Group