Loading.......................

This is a discussion on Loading....................... within the C++ Programming forums, part of the General Programming Boards category; ok heres what I wanted: say I have a file called "cube.x" which is a 3d model that I could ...

  1. #1
    Registered User
    Join Date
    Oct 2001
    Posts
    75

    Loading.......................

    ok heres what I wanted:


    say I have a file called "cube.x" which is a 3d model that I could use to load into a program/game

    what I was wondering is how would I load this into a program or something so that it ca nbe displayed just like it would be in a 3d modelling program or something u knopw so that I loa din an object or model like the cube.x and then I see it on the screen if u understand can u plz help me out here


    cheers


    stealth
    If I knew what You know I wouldnt be here.............. Stealth

    Ecliptic Entertainment
    http://www.ecliptic-entertainment.com/

  2. #2
    Normal vector Carlos's Avatar
    Join Date
    Sep 2001
    Location
    Budapest
    Posts
    463
    I *try* to understand what you've written...you've got Hrabal's style (no punctuation, nothing)

    What kind of 3D model is that?
    Point Coordinates, vectors or what?

    OpenGL has some libraries for loading 3DStudio models, I read it once right in this board.

    For DirectX there must surely be something alike, sunlight would be of help, but he's gone .

    For more info on OpenGL visit NeHe

  3. #3
    Registered User
    Join Date
    Oct 2001
    Posts
    75
    yeah I've been to that site and all that stuff requires I learn OpenGL Which I will do after I learn C++ or maybe I will go with DX but I was thinking that C++ must have a way to load up any file type I mean even if I have to write the function to do it myself then I will the only problem is where do I start - " what kinda model is that" it's a model saved as a direct x format thingy so yeah I dont think I'll be going towards OGL at the moment well the X model is another kinda 3d object like a 3ds which I also wanna work with but I was kinda thinking to do it plz dont laugh if I'm wrong but I can only say it in words



    - find the file like a user inputs a directory or path + the name and or maybe the exstension of the file (like "*.X" or "*.3ds")

    - then maybe either somehow get what kind of info is needed on loading that file type and then load it

    maybe there is some C++ way of loading in 3d models or objects I dont know that why I ask

    and if u wanna know I'm using DevC++

    I have bordland but dont know how to set it up otherwise I would



    cheers


    stealth
    If I knew what You know I wouldnt be here.............. Stealth

    Ecliptic Entertainment
    http://www.ecliptic-entertainment.com/

  4. #4
    Normal vector Carlos's Avatar
    Join Date
    Sep 2001
    Location
    Budapest
    Posts
    463
    ANSI C has it's standard functions to handle files : fopen, fclose, getc etc, but there's no special function in C or C++ to handle special file formats like 3D, graphical file formats etc.

    These are usually provided by special API's, libraries (like DirectX, OpenGL, Intel JPEG lib), or you can made them from scratch.
    The last method is harder, nut it has it's advantages:
    - it's your code, you can use it as you like
    - it's optimized by you
    - you can define your own file-format
    - you can copyright/ trademark it (like the guys at Frauhofen Institute did with MP3 ) and earn lots of money

    If you cannot manage it at all, try to find out infos from the file's header, and process data as required...

    Btw, if the file is a standard file type, there's probably an adequate lib or something to use it.
    Last edited by Carlos; 10-31-2001 at 03:26 AM.

  5. #5
    Registered User
    Join Date
    Oct 2001
    Posts
    75
    ok man thats a start I'd rather learn DX over OGL but the download is so huge oh well better make a choice fast

    thanks man
    If I knew what You know I wouldnt be here.............. Stealth

    Ecliptic Entertainment
    http://www.ecliptic-entertainment.com/

  6. #6
    Normal vector Carlos's Avatar
    Join Date
    Sep 2001
    Location
    Budapest
    Posts
    463
    For DirectX stuff check http://nexe.gamedev.net/

    An example of loading a MilkShape3D file:
    http://nexe.gamedev.net/tutorials/Vi...utorial7.myxml

    Have fun!

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Cargo loading system
    By kyle rull in forum C Programming
    Replies: 1
    Last Post: 04-20-2009, 12:16 PM
  2. added start menu crashes game
    By avgprogamerjoe in forum Game Programming
    Replies: 6
    Last Post: 08-29-2007, 01:30 PM
  3. Loading a bitmap (Without using glaux)
    By Shamino in forum Game Programming
    Replies: 7
    Last Post: 03-16-2006, 08:43 AM
  4. need help with .md3 file loading
    By Shadow12345 in forum Game Programming
    Replies: 2
    Last Post: 12-06-2002, 03:06 PM
  5. Loading Screen
    By pinkcheese in forum Windows Programming
    Replies: 2
    Last Post: 04-06-2002, 10:48 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21