Hard Light Productions Forums

General FreeSpace => FreeSpace Discussion => Topic started by: blowfish on May 20, 2008, 05:18:14 pm

Title: POF Model Format Specifications
Post by: blowfish on May 20, 2008, 05:18:14 pm
Is there anywhere I can find up-to-date documentation of the structure of POF files?  Does such documentation exist?
Title: Re: POF Model Format Specifications
Post by: Water on May 21, 2008, 06:07:21 am
While your waiting for an answer to that question.
Have a look here. It's a bit more work but it may have some useful bits.
http://alliance.cvs.sourceforge.net/alliance/pcs2/ (http://alliance.cvs.sourceforge.net/alliance/pcs2/)
Title: Re: POF Model Format Specifications
Post by: Kazan on May 21, 2008, 01:37:30 pm
Why do you need to know?

the most "up to date" documentation is the FS2 Open Codebase and the PCS2 codebase
Title: Re: POF Model Format Specifications
Post by: blowfish on May 21, 2008, 01:55:08 pm
Why do you need to know?

the most "up to date" documentation is the FS2 Open Codebase and the PCS2 codebase

I'm trying to create a basic texture-replacement app for Mac, so that I don't have to go to my old windoze computer every time I want to make a minor texture adjustment to a model.  I understand how to work with data, so I'm trying to figure out extract the texture information, and put everything back correctly into the POF when I'm done.  The FS2_Open source seems to be pretty helpful, after looking at it a bit more closely.
Title: Re: POF Model Format Specifications
Post by: Kazan on May 21, 2008, 02:01:28 pm
you know PCS2 is written in wxWidgets so it would be relatively trivial to add mac into it's multiplatform support.. i just need to clean up it's posix-operating system handling.

biggest thing that needs to be done is add macros in for int transformation
Title: Re: POF Model Format Specifications
Post by: blowfish on May 21, 2008, 03:10:17 pm
OK.  I figured out how a POF file is structured.  Just one thing: can I rely on the fact that the texture chunk will be the first one?
Title: Re: POF Model Format Specifications
Post by: Kazan on May 21, 2008, 04:53:35 pm
generally yes... but... just scan for the chunk's signature... or better yet

use PCS2
Title: Re: POF Model Format Specifications
Post by: blowfish on May 21, 2008, 04:56:11 pm
use PCS2

I was wondering if you were going to say that at some point...

EDIT: Anyway, I already have a system in place to go through the chunks until the texture chunk is found.
Title: Re: POF Model Format Specifications
Post by: blowfish on May 22, 2008, 01:04:43 am
Well, I got it to parse fine, and I can extract a list of textures regardless of where the texture chunk is.  But I can't even test my save code because the mutable data isn't working correctly :mad:
Title: Re: POF Model Format Specifications
Post by: Kazan on May 22, 2008, 11:06:10 am
use PCS2
Title: Re: POF Model Format Specifications
Post by: blowfish on May 22, 2008, 12:06:57 pm
Fine :rolleyes:
Title: Re: POF Model Format Specifications
Post by: Goober5000 on May 22, 2008, 10:40:43 pm
Dude, don't listen to Kazan.  He didn't listen to the people who said "use ModelView". :D

If you have an idea for a cool personal project, by all means go for it.  You learn best by doing.
Title: Re: POF Model Format Specifications
Post by: blowfish on May 22, 2008, 10:50:05 pm
You learn best by doing.

True.  Even if I were to give up on this project now, I would have learned a huge amount about the structure of POF files.