Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: Kazan on October 26, 2002, 11:36:12 am

Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 11:36:12 am
i can give you write access to it's CVS repository
Title: If someone wants to Pick up POF CS Developement...
Post by: Galemp on October 26, 2002, 12:57:44 pm
Kazan, you've done a great job, but PCS is a necessary evil IMO. If someone would only integrate all the PCS functions into ModelView, we'd be all set.
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 01:02:30 pm
i said if someone else wants to work on it i will let them - and remember mine has a partially completed renderer [you should change the GLUT to SDL... GLUT = teh suck, SDL rocks]

so "integrating into modelview" ... no more like finishing off the modelview in mine ...

modelview32 = barely good for viewing.. coding in modelview = teh suck

i would consider working on PCS if i wasn't busy with my own game
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 01:25:02 pm
were is the code at, we all can still DL it right?
and personaly I think it would be better to try and integrate it into Pofview (the V tool), but I'm just talking out my ass on this one
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 01:28:56 pm
everyone who says "integrated it with X other tool" is instantly talking out their ass - you don't combine two non-related codebases.. it simply doesn't work - plus POF CS already has the framework for all those "model viewing" ****.. what do you think that render window is!

the sourcecode is in my sf.net CVS

here is the POFRenderer.cpp (http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/alliance/POFConstructorSuite/POFRenderer.cpp?rev=1.3&content-type=text/vnd.viewcvs-markup) from POF CS... scroll down to the "void POFRenderer::CallBackDisplayFunc(void)" function
see that switch statement.. "switch (RenderDataContext)"
that switches what is currently being drawn - ie paths, shields, etc
it's all there.. all the RCONTEXTs are defined in POFRenderer.h.. i just hadn't implemented all of them yet... and you can fix the bug in the GLOW chunk code that i never tracked down in POFHandler.cpp
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 01:35:06 pm
never mind I found it,after you edited
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 01:49:03 pm
so what's the cvs root,
so I can DL and play with it
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 01:58:06 pm
CVS Command
cvs -z3 -d:pserver:[email protected]:/cvsroot/alliance co pofconstructorsuite

anonymous password is "anonymous"
Title: If someone wants to Pick up POF CS Developement...
Post by: aldo_14 on October 26, 2002, 02:16:36 pm
Quote
Originally posted by Kazan
everyone who says "integrated it with X other tool" is instantly talking out their ass - you don't combine two non-related codebases.. it simply doesn't work - plus POF CS already has the framework for all those "model viewing" ****.. what do you think that render window is!
 


:rolleyes:

Depends on your levels of abstraction, dunnit....
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 02:20:28 pm
i am rather abstract and practice good style - they do not

and it's pointless because most of the framework is actually there - you'd spend more time and loose more performance merging the codebases than you would writing on than you would writing on the existing framework


the GUI and working code are completely decoupled - so if you want you can scrap my GUI.. and i encourage you scrap the GLUT/GLUTmaster and replace it with clean SDL
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 02:22:12 pm
its rejecting access
I hate cvs grrr
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 02:25:52 pm
http://sourceforge.net/cvs/?group_id=26889
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 02:31:28 pm
that did, got it now, thanks ;)
I'm such a CVS newb
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 02:38:18 pm
just tried compileing it and it can't seem to find apvector.h
amung other things
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 02:40:55 pm
lol... none of the apvector stuff is standard ... you need to download them from the collegeboard

[i no longer use the ap classes.. i use STL now.. but im not bothering porting that code]
Title: If someone wants to Pick up POF CS Developement...
Post by: aldo_14 on October 26, 2002, 02:40:55 pm
Quote
Originally posted by Kazan
i am rather abstract and practice good style - they do not

and it's pointless because most of the framework is actually there - you'd spend more time and loose more performance merging the codebases than you would writing on than you would writing on the existing framework


the GUI and working code are completely decoupled - so if you want you can scrap my GUI.. and i encourage you scrap the GLUT/GLUTmaster and replace it with clean SDL


s'pose.  i'm used to using Java, so I normally have a shedload of specifically independent classes done up specifically for reusability / revision.... but it's really a completely different paradigm.
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 02:43:34 pm
ok so were do I get it from
also I keep getting
"lines ending only with carriage return have been detected. these will be modified to inclued a line feed"
is this something to be concerned about
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 02:46:59 pm
lol you need to recheck it out.. setting the "Checkout files with unix line endings"....
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 02:50:25 pm
also it seems
PCSGlowProc.cpp
is missing
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 02:53:31 pm
REALLY? *looks in the cvs*
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 02:57:34 pm
ya, it should be between PCSFuelProc.cpp and PCSHDR2Proc.cpp, but it isn't
and were would I be able to find the ap*.h things (or did I mis understad you and these are no longer referenced)
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 03:07:19 pm
i told you go to the collegeboard website to get the ap classes

update your cvs.. i commited PCSGlowProc

bobboau! IM ME.. yahoo lordkazan, icq 28119425, msn [email protected]
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 03:23:58 pm
were is the collegeboard website?
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 03:32:44 pm
collegeboard.org .....
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 03:41:35 pm
I get redirected to collegeboard.com wich looks like some sort of college preperation site
Title: If someone wants to Pick up POF CS Developement...
Post by: phreak on October 26, 2002, 03:43:40 pm
bob i have them, if you can't find them i'll email them to you
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 03:46:42 pm
[email protected]
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 04:00:53 pm
that';s what is is moron

the AP templated classes are from AP Computer Science.. the AP program is coordinated by the college board... yuo need to look up AP Comp Sci in their database and get the templated classes
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 04:21:09 pm
:doubt:
ok now I need the glut files...
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 04:55:08 pm
and the OpenIL [DevIL] files... openil.sf.net
Title: If someone wants to Pick up POF CS Developement...
Post by: KARMA on October 26, 2002, 06:58:55 pm
a thing that i'd really love in pcs is the ability to edit hyerachy of a model: sometimes when i convert with pcs i find the lods in a wrong order..pretty strange and realy pissing, since in this cases i only can switch to cob2fs2...but with the ability of editing hyerachy that wouldn't be a problem, but also the possibility to import meshes in specific positions (thrusters? turrets?) could be very useful
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 07:01:05 pm
the lods being in the wrong order is your fault - it's documented that POF CS processes lods IN THE ORDER FOUND
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 07:33:51 pm
ok were, exactly, did you get you're glut stuff from
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 07:36:57 pm
god damn man, you ever heard of google?
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 07:49:04 pm
yes, but there are quite a few hits, and, while I'm sure the right file is amungst them some were, I thought it would be quicker to mearly ask for a direct link
and I'm sure some other people would find it useful also
Title: If someone wants to Pick up POF CS Developement...
Post by: RandomTiger on October 26, 2002, 08:26:21 pm
I have 3.7 here: http://www.ijbrooks.demon.co.uk/tom/glut.zip

Heres another likely link:

http://www.xmission.com/~nate/glut.html
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 08:30:58 pm
I've already got those,
I'm missing glutMaster.h, specificly
Title: If someone wants to Pick up POF CS Developement...
Post by: RandomTiger on October 26, 2002, 08:41:42 pm
Quote
Originally posted by Bobboau
I've already got those,
I'm missing glutMaster.h, specificly


Not used glut for a while but I've never heard of that file.
Everything you need for glut should be in there.
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 08:43:22 pm
glutmaster is seperate from glut.. go and ****ing download it
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 08:53:18 pm
from were, :rolleyes:
I find a bunch of diferent sites with some files up, none of them seem to be offical, no "this is what you need" zip, I want to make sure I get everything
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 09:05:26 pm
LEARN THE ****INHG USE GOOGLE CORRECTLY - GOD DAMN!
Title: If someone wants to Pick up POF CS Developement...
Post by: RandomTiger on October 26, 2002, 09:20:27 pm
Calm down. :rolleyes:

I dont know anything about glutmaster but this looks like a promising link:

http://www.stetten.com/george/glutmaster/glutmaster.html
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 09:23:05 pm
RT: that's the official site
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 09:47:55 pm
:doubt: does anyone have the correct glut32.lib
Title: If someone wants to Pick up POF CS Developement...
Post by: mikhael on October 26, 2002, 10:11:47 pm
Just out of curiosity, Kazan, could you keep it civil?
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 26, 2002, 10:12:35 pm
you don't know Kazan very well :lol:
Title: If someone wants to Pick up POF CS Developement...
Post by: mikhael on October 26, 2002, 10:16:45 pm
Quote
Originally posted by Bobboau
you don't know Kazan very well :lol:


Too right. I think I'll keep it that way. If you need any help with the GL/GLu/GLUT stuff, let me know, Bobboau. I'm pretty sure I have a link that will help you get your GL build environment setup... Um... here's the files I use with VisualStudio and Codewarrior. There's a link there about where to put the files, too.
http://lahs.losalamos.k12.nm.us/departments/computers/opengl/Libraries.html

I use the standard Mesa libs with GCC.

Actually, here's the list of OpenGL links I keep bookmarked for one reason or another:
http://www.xmission.com/~nate/glut.html
http://www.lighthouse3d.com/opengl/glut/
http://nehe.gamedev.net/opengl1.asp
http://courses.cs.vt.edu/~cs4204/schedule.html
http://www.opengl.org/developers/documentation/glut/spec3/spec3.html
http://www.opengl.org/developers/documentation/man_pages/hardcopy/GL/html/

If those don't help, just ask. :D
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 26, 2002, 10:38:25 pm
mikhael: infact no.. **** you i cannot keep it civil when someone is annoying the **** out of me with questions that google can answer and im trying to do work and i keep getting emails notifing me of thread replies that are useless thread replies
Title: If someone wants to Pick up POF CS Developement...
Post by: mikhael on October 26, 2002, 10:44:30 pm
Quote
Originally posted by Kazan
mikhael: infact no.. **** you i cannot keep it civil when someone is annoying the **** out of me with questions that google can answer and im trying to do work and i keep getting emails notifing me of thread replies that are useless thread replies


Then don't answer. It okay. Honest. Unless you've got a broken keybaord, the delete key takes care of "useless thread replies". Quit with the pathetic whinging, already. We get the point.
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 27, 2002, 12:24:53 am
or you could unsubscribe, or even better, ignor them
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 27, 2002, 12:51:22 am
thank you mikhael, I got it working now
Title: If someone wants to Pick up POF CS Developement...
Post by: mikhael on October 27, 2002, 01:03:53 am
Quote
Originally posted by Bobboau
thank you mikhael, I got it working now


Excellent. :D

If you need any help, let me know. Or ask here. Someone is bound to have an answer. :D
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 27, 2002, 03:01:26 pm
I think I may have fixed the glow point bug, sort of
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 27, 2002, 03:45:45 pm
there's a mismatch in the read and write routines IIRC
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 27, 2002, 07:11:16 pm
I beleve you forgot to include the int for the size of the properties string (though you did remember the string data it'self)
and this
Code: [Select]

for (int j = 0; j < hull_lights.lights[i].num_Lights; j++)
{
memcpy(&hull_lights.lights[i].lights[j], vector_buf, sizeof(vector));
outfile.write(vector_buf, sizeof(vector));
outfile.flush();

memcpy(&hull_lights.lights[i].lights[j], vector_buf, sizeof(vector));
outfile.write(vector_buf, sizeof(vector));
outfile.flush();

memcpy(&hull_lights.lights[i].lights[j], temp_buf, sizeof(float));
outfile.write(temp_buf, sizeof(float));
outfile.flush();

}

should be this
Code: [Select]

for (int j = 0; j < hull_lights.lights[i].num_Lights; j++)
{
memcpy(vector_buf, &hull_lights.lights[i].lights[j].point, sizeof(vector));
outfile.write(vector_buf, sizeof(vector));
outfile.flush();

memcpy(vector_buf, &hull_lights.lights[i].lights[j].norm, sizeof(vector));
outfile.write(vector_buf, sizeof(vector));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].lights[j].radius, sizeof(float));
outfile.write(temp_buf, sizeof(float));
outfile.flush();

}

basicly you forgot to tell wich member if hull_lights.lights you were useing
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 27, 2002, 07:13:59 pm
you have a sourceforge account.. i'll give you CVS write access
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 27, 2002, 07:20:15 pm
why not just give a general account and password for the entire SCP team,
I'm sure the others would be less likely to cause more bugs than they fix, wich I can't realy say for myself :wink:
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 27, 2002, 07:44:56 pm
because you cannot do that

sourceforge cvs is ssh encrypted cvs
Title: If someone wants to Pick up POF CS Developement...
Post by: Bobboau on October 28, 2002, 03:35:44 am
well I have less than a clue as to whats causeing the vast majority of crashing, I get an assertion error when I try loading a new model after haveing some (but not all) glow point models open, after saveing more than once, going into the debugger mearly confuses me (it seems like glow data may be overwriteing SOBJ data internaly, but that is little more than a guess), I've gone through and looked for things that other chuncks have that glow doesn't but it doesn't seem to have fixed anything and probly only made things worse, and I disabled the 3D veiwer to limet bug sorces, only good I've done is the read write functions (and killed that anoying nag when I want to open a new file)
I added an int for glow type to the HullLights struct, and the needed interface in the gloweditor, so I can do somehting I wanted to do (diferent rendering stiles, point/beam/other)
posting the read/right stuff here if anyone else want to take a shot,
I am not qualified to do much more at this time (I even can't read 73% of the code, let alone bug hunt)

Code: [Select]

void POF::Parse_Memory_GLOW(char *buffer)
{
//hull_lights
char *localptr = buffer;

memcpy(&hull_lights.num_glows_arrays, localptr, sizeof(int));
localptr += sizeof(int);

hull_lights.lights = new HullLights[hull_lights.num_glows_arrays];

for (int i = 0; i < hull_lights.num_glows_arrays; i++)
{
memcpy(&hull_lights.lights[i].disp_time, localptr, sizeof(int));
localptr += sizeof(int);

memcpy(&hull_lights.lights[i].on_time, localptr, sizeof(int));
localptr += sizeof(int);

memcpy(&hull_lights.lights[i].off_time, localptr, sizeof(int));
localptr += sizeof(int);

memcpy(&hull_lights.lights[i].obj_parent, localptr, sizeof(int));
localptr += sizeof(int);

memcpy(&hull_lights.lights[i].LOD, localptr, sizeof(int));
localptr += sizeof(int);

memcpy(&hull_lights.lights[i].type, localptr, sizeof(int));
localptr += sizeof(int);

memcpy(&hull_lights.lights[i].num_Lights, localptr, sizeof(int));
localptr += sizeof(int);

memcpy(&hull_lights.lights[i].properties.length, localptr, sizeof(int));
localptr += sizeof(int);

hull_lights.lights[i].properties.str = new char[hull_lights.lights[i].properties.length];

memcpy(hull_lights.lights[i].properties.str, localptr, hull_lights.lights[i].properties.length);
localptr += hull_lights.lights[i].properties.length;

hull_lights.lights[i].lights = new HullLightPoint[hull_lights.lights[i].num_Lights];

for (int j = 0; j < hull_lights.lights[i].num_Lights; j++)
{
memcpy(&hull_lights.lights[i].lights[j].point, localptr, sizeof(vector));
localptr += sizeof(vector);

memcpy(&hull_lights.lights[i].lights[j].norm, localptr, sizeof(vector));
localptr += sizeof(vector);

memcpy(&hull_lights.lights[i].lights[j].radius, localptr, sizeof(float));
localptr += sizeof(float);

}
}
}


from within
bool POF::SavePOF(ofstream &outfile)
Code: [Select]

// 16 GLOW ----------------------------------------
if (hull_lights.num_glows_arrays != 0)
{
//write signature
outfile.write("GLOW", 4);

k = sizeof(int) + (8 * sizeof(int) * hull_lights.num_glows_arrays); // each group in binary format is 7 ints + strlen + size of their point array
for ( i  = 0; i < hull_lights.num_glows_arrays; i++)
{
k += ( (hull_lights.lights[i].properties.length) + (sizeof(HullLightPoint) * hull_lights.lights[i].num_Lights));
}


// write size
memcpy(temp_buf, &k, sizeof(int));
outfile.write(temp_buf, sizeof(int));

// write data

memcpy(temp_buf, &hull_lights.num_glows_arrays, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();


for (int i = 0; i < hull_lights.num_glows_arrays; i++)
{
memcpy(temp_buf, &hull_lights.lights[i].disp_time, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].on_time, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].off_time, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].obj_parent, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].LOD, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].type, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].num_Lights, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].properties.length, sizeof(int));
outfile.write(temp_buf, sizeof(int));
outfile.flush();


outfile.write(hull_lights.lights[i].properties.str, hull_lights.lights[i].properties.length);
outfile.flush();

for (int j = 0; j < hull_lights.lights[i].num_Lights; j++)
{
memcpy(vector_buf, &hull_lights.lights[i].lights[j].point, sizeof(vector));
outfile.write(vector_buf, sizeof(vector));
outfile.flush();

memcpy(vector_buf, &hull_lights.lights[i].lights[j].norm, sizeof(vector));
outfile.write(vector_buf, sizeof(vector));
outfile.flush();

memcpy(temp_buf, &hull_lights.lights[i].lights[j].radius, sizeof(float));
outfile.write(temp_buf, sizeof(float));
outfile.flush();

}
}
}

remember I added an int (type) to the HullLights struct

I've got a copy running stable enough for my needs, I can test new code changes and modify models myself, though I wouldn't want to put anyone else through it's buggynes if I didn't have to
I realy hope someone picks this up becase I do not want to be stuck with my crash happy version
we've got to have someone who knows how to use this stile
Title: If someone wants to Pick up POF CS Developement...
Post by: Kazan on October 28, 2002, 08:23:14 am
screw it.. i'll start coding on it again - i need a break from openprivateer anyway
Title: If someone wants to Pick up POF CS Developement...
Post by: RandomTiger on October 28, 2002, 08:27:10 am
:lol: