Results 1 to 10 of 10

Thread: A simple opengl way to load objects(x, 3ds)?

  1. #1
    Member Contributor
    Join Date
    Jan 2001
    Location
    Germany
    Posts
    55

    A simple opengl way to load objects(x, 3ds)?

    [QUOTE]
    Well i used to program directx, now then i used *.x files as models which i built in 3d studio max r3.
    But does anybody know a simple way to load and display an x or 3ds file.
    Does opengl maybe also have a meshbuilder?

    Thnaks for any help
    -your starnut coder
    -http://starnut.9ug.com
    Programming in Directx and Opengl

  2. #2
    Junior Member Newbie
    Join Date
    Jun 2000
    Location
    Calgary, Canada
    Posts
    19

    Re: A simple opengl way to load objects(x, 3ds)?

    OpenGL doesn't have any high level stuff like the old DirectX Retained Mode. Your best bet is to get a program called 3D Exploration and use it to export a model to OpenGL .cpp files. This usually works pretty good, but remember to select Tools|Convert To Double Sided.

  3. #3
    Member Contributor
    Join Date
    Feb 2000
    Location
    San Diego Ca, USA
    Posts
    50

    Re: A simple opengl way to load objects(x, 3ds)?

    export your objects to .ASE and parse the
    data into your program

  4. #4
    Member Contributor
    Join Date
    Jan 2001
    Location
    Germany
    Posts
    55

    Re: A simple opengl way to load objects(x, 3ds)?

    Thanks that works fine i got the program View3ds its great.
    -http://starnut.9ug.com
    Programming in Directx and Opengl

  5. #5
    Senior Member Regular Contributor
    Join Date
    Jul 2000
    Location
    Canada
    Posts
    173

    Re: A simple opengl way to load objects(x, 3ds)?

    I usually use my own translator to convert STL files to OpenGL code. The only problem is that STL files do not have information about color, animation, etc. They just have the triangulated mesh. Then I have to assign those variables when I am programming. Too bad OpenGL does not have a MeshBuilder like DirectX...
    Billy

  6. #6
    Member Contributor
    Join Date
    Nov 2000
    Location
    Thuringia, Germany
    Posts
    85

    Re: A simple opengl way to load objects(x, 3ds)?

    opengl is no high-level api. it's a low level api for doing the graphic and render stuff. the rest you have to do yourself

    greetings,

    Bastian.

  7. #7
    Junior Member Newbie
    Join Date
    Jan 2001
    Location
    fr
    Posts
    9

    Re: A simple opengl way to load objects(x, 3ds)?

    If you want to render an *ase file, the simplest way is to build in your program four structures:
    for exemple:

    typedef struct {
    float x,y,z;
    } VERTEX;

    typedef struct {
    int A,B,C;
    }FACE;

    typedef struct{
    int nvert;
    VERTEX *point;
    } OBJECT;

    typedef struct{
    int nobj;
    OBJECT *object;
    } SCENE;

    after having declared these, read your ase file with the fonction strcmp and load each object,coordinate, face in yours structures... hope my help,
    frog

  8. #8
    Member Contributor
    Join Date
    Jan 2001
    Location
    Germany
    Posts
    55

    Re: A simple opengl way to load objects(x, 3ds)?

    Thanks i got objects in now.
    Thanks for all youre help guys.
    -http://starnut.9ug.com
    Programming in Directx and Opengl

  9. #9
    Junior Member Newbie
    Join Date
    Jan 2001
    Location
    Athens, Greece
    Posts
    1

    Re: A simple opengl way to load objects(x, 3ds)?

    Could you please tell me where you found View3ds?
    Thanks a lot

    Alex

  10. #10
    Member Contributor
    Join Date
    Jan 2001
    Location
    Germany
    Posts
    55

    Re: A simple opengl way to load objects(x, 3ds)?

    Sure i can send the program to you just mail me your email. Thanks
    -http://starnut.9ug.com
    Programming in Directx and Opengl

Similar Threads

  1. Simple Texture Load & Unload
    By xandred in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 01-04-2013, 11:29 PM
  2. Replies: 9
    Last Post: 07-27-2012, 06:31 AM
  3. how to load wavefront objects
    By alexisgr in forum OpenGL: Basic Coding
    Replies: 6
    Last Post: 01-26-2009, 05:15 AM
  4. Simple Code to load DXT textures
    By patbier in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 12-10-2005, 02:42 AM
  5. how to load objects?
    By in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 11-11-2000, 09:54 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean