It is mostly out of boredom, really... This afternoon I decided to make a simple 3D Game on Cocoa & OpenGL based on what I've done on one of my OpenGL class. I'm using the MD2 loading code that is posted at David Henry's "The Quake II's MD2 file format" and I like how it's put together, giving nice explanations, and nice C++ code. I want this to go all Cocoa/Objective-C so I can get the feel for the stuff and I got to a part which I cannot translate to C - I simply do not got enough experience in programming. Here is the code in question, which relates to file reading:
// read frame data...
file.seekg( header.ofs_frames, std::ios::beg );
file.read( (char *)buffer, num_frames * header.framesize );
So, my question is this: is there an equivalent for seek() on C's file functions that I can use? Any related info you think I might find useful?
Thank-you in advance, and bless.