Results 1 to 6 of 6

Thread: question how to load *.obj models or other models

  1. #1
    Senior Member Lionheart008's Avatar
    Join Date
    Sep 2008
    Location
    Germany, Bad Sooden-Allendorf
    Age
    48
    Posts
    919
    Rep Power
    105

    question how to load *.obj models or other models

    hi petr :-)

    I have a simple question if you have perhaps a good link or library for me how I can load "objects" (models: poser files, *.obj files, milkshape or other ones) for Powerbasic (for example) as you did it I can imagine for your great tbgl modul. I tried to convert some nehe example for oxygen and I am trying now to load models too, but I have no good stuff or library by hand. and it's a djungle to get a simple overview of them. thanks in advance, good week-end, best regards, frank
    you can't always get what you want, but if you try sometimes you might find, you get what you need

  2. #2
    thinBasic MVPs ReneMiner's Avatar
    Join Date
    Oct 2012
    Location
    Germany
    Age
    51
    Posts
    1,436
    Blog Entries
    2
    Rep Power
    158
    you might convert those .obj-files to TBGL-Native M15 files look here.
    running thinBasic in HP Pavillon Desktop 590 a0xxx 8GB Ram AMD A6-9225 Radeon R4 5Compute Cores 2C+3G @2.6GHz

    OS: Windows 11 Enterprise x64 Build 22065 (21H2 pre-release)
    (says the systeminfo. anything else says it were Windows 10 - more or less insider - a lot of the system settings do not function - i could imagine it will not send feedback to microsoft since it always says i need a new app to open that feedback-hub-link. But hey: thinbasic runs well )

  3. #3
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,089
    Blog Entries
    5
    Rep Power
    726
    Hi Frank,

    I do not have OBJ loader written in PB, but I published a MD2 library for PowerBASIC, maybe this could be of interest?
    http://www.jose.it-berater.org/smffo...sg9011#msg9011


    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

  4. #4
    thinBasic MVPs ReneMiner's Avatar
    Join Date
    Oct 2012
    Location
    Germany
    Age
    51
    Posts
    1,436
    Blog Entries
    2
    Rep Power
    158
    There's no wall to hit!

    Obj-Loading is possible in plain thinBasic + TBGL:

    The program is intended to load just Obj-Files made with David-Laserscanner - so they have one group only - if you want to try, download for example "David-Angel_OBJ.zip" from here and see. Would be no Problem to extend this script to load OBJ-Files with multiple groups. It's a little longer because it uses FreeImage to load all kinds of image-formats as a texture.
    Last edited by ReneMiner; 25-03-2013 at 10:56.
    running thinBasic in HP Pavillon Desktop 590 a0xxx 8GB Ram AMD A6-9225 Radeon R4 5Compute Cores 2C+3G @2.6GHz

    OS: Windows 11 Enterprise x64 Build 22065 (21H2 pre-release)
    (says the systeminfo. anything else says it were Windows 10 - more or less insider - a lot of the system settings do not function - i could imagine it will not send feedback to microsoft since it always says i need a new app to open that feedback-hub-link. But hey: thinbasic runs well )

  5. #5
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    54
    Posts
    8,636
    Blog Entries
    2
    Rep Power
    10
    Quote Originally Posted by John Spikowski View Post
    If you hit the wall on this with thinBasic, ScriptBasic will translate its script to C and link in any .obj you wish. (along with static linking of any of it's extension modules) A big advantage of ScriptBasic being written in ANSI/ISO C.
    That is another OBJ file type.

    You are referring to this one: http://en.wikipedia.org/wiki/Object_file

    Here they are talking about this one: http://en.wikipedia.org/wiki/Wavefront_.obj_file
    Last edited by ErosOlmi; 25-03-2013 at 12:48.
    www.thinbasic.com | www.thinbasic.com/community/ | psch.thinbasic.com
    Win10Pro 64bit - 8GB Ram - Intel i7 M620 2.67GHz - NVIDIA Quadro FX1800M 1GB

  6. #6
    Senior Member Lionheart008's Avatar
    Join Date
    Sep 2008
    Location
    Germany, Bad Sooden-Allendorf
    Age
    48
    Posts
    919
    Rep Power
    105
    thank you all for your infos and example (rene) and correct meaning of *.obj (wavefront) files by eros link :-)

    thanks petr, I will check your example. I am looking forward for alternative libraries I know there's a lot of more to explore. If I find an interesting library or sdk I will mail here.

    regards, frank
    you can't always get what you want, but if you try sometimes you might find, you get what you need

Similar Threads

  1. Models
    By kryton9 in forum Media material
    Replies: 96
    Last Post: 04-03-2010, 15:18
  2. Graphics / Models / Hovercraft
    By Petr Schreiber in forum Media
    Replies: 17
    Last Post: 13-10-2008, 15:54
  3. Concept: Glider models
    By Michael Hartlef in forum Media
    Replies: 0
    Last Post: 13-10-2008, 08:25
  4. Creating models
    By Petr Schreiber in forum TBGL General
    Replies: 42
    Last Post: 20-04-2007, 03:58
  5. thinBasic Models and ArtWork
    By kryton9 in forum TBGL Modelling, 3D, other SW integration
    Replies: 13
    Last Post: 23-02-2007, 20:07

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •