Results 1 to 10 of 10

Thread: How to convert *.txt files to *.obj files?

  1. #1
    Join Date
    Apr 2010
    Location
    Singapore
    Posts
    156
    Thanks
    47
    Qt products
    Qt4
    Platforms
    Windows

    Default How to convert *.txt files to *.obj files?

    Hello,
    What are the methods to convert *.txt files to *.obj files and how to do it?
    Is there a fast and easy method available, perhaps a ready made tool readily available ?
    If got any example or link , it would be more helpful.

    regards,
    Emma
    Last edited by babygal; 30th June 2011 at 08:14.

  2. #2
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Thanked 342 Times in 324 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How to convert *.txt files to *.obj files?

    What .obj files do you mean ? .obj files used as mesh description in 3d modeling tools (they are already text files btw) ? Or some other .obj files, can you give example ?

  3. #3
    Join Date
    Apr 2010
    Location
    Singapore
    Posts
    156
    Thanks
    47
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: How to convert *.txt files to *.obj files?

    Quote Originally Posted by stampede View Post
    What .obj files do you mean ? .obj files used as mesh description in 3d modeling tools (they are already text files btw) ? Or some other .obj files, can you give example ?
    Hi,
    Yes I meant .obj files used as mesh description in 3D modeling tools. Yes currently those are only in the form of text files which I am having now. Hence,the next step would be that I need a converter which could convert the text files to object files, because currently my program takes only object files as input and not text files. Unless, I write a new routine that reads text file and then render the meshes.
    Currently I am looking for a way to convert the mesh text files to object files because I have an object file reader routine written already in my program.

    Thank you.

    regards,
    Emma

  4. #4
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Thanked 342 Times in 324 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How to convert *.txt files to *.obj files?

    (...) because currently my program takes only object files as input
    Ok, so what is the format of those object files ? Or where do you get those mesh files from ? Are you exporting meshes from 3d studio ? Maybe Ogre mesh files ?

  5. #5
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: How to convert *.txt files to *.obj files?

    ...and while you are at it, what is in the txt files?

  6. #6
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Thanked 342 Times in 324 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How to convert *.txt files to *.obj files?

    @ChrisW67: I think the mentioned .txt files are in fact .obj files, which contains description of 3d meshes ( list of vertices, faces and edges, vertex groups info and material references, all in human-readable text format ), and babygal wants to convert those text files (.obj) to some kind of binary format, which is suitable for loading in her application.
    Anyway I think it could be good to ask on 3d max, blender, ZBrush, Ogre or something-related-to-3d community forum, it's more probable that you'll find help with mesh files format conversions there.
    Another thing is that writing an .obj parser is quite easy task, but if you don't feel like doing it, try asking on 3d-related community forum.

  7. #7
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: How to convert *.txt files to *.obj files?

    You could also look at MeshLab because they seem to handle a lot of file formats of this type and the source is available.

  8. #8
    Join Date
    Apr 2010
    Location
    Singapore
    Posts
    156
    Thanks
    47
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: How to convert *.txt files to *.obj files?

    Quote Originally Posted by ChrisW67 View Post
    ...and while you are at it, what is in the txt files?
    Hi ChrisW67,
    The .txt files contain description of 3D meshes (list of vertexes and faces).


    Added after 1 50 minutes:


    Quote Originally Posted by stampede View Post
    Ok, so what is the format of those object files ? Or where do you get those mesh files from ? Are you exporting meshes from 3d studio ? Maybe Ogre mesh files ?
    Hi stampede,
    Sorry when you mentioned format of those object files, is it the structure you are referring to or something else?
    The text mesh files are generated by my program when a certain API is called.
    No, I am not exporting meshes from 3D studio.
    No, not Ogre mesh files either.


    regards,
    Emma
    Last edited by babygal; 1st July 2011 at 09:25.

  9. #9
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: How to convert *.txt files to *.obj files?

    Quote Originally Posted by babygal View Post
    Hi ChrisW67,
    The .txt files contain description of 3D meshes (list of vertexes and faces).
    Did you try just renaming the file from *.txt to *.obj?
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  10. #10
    Join Date
    Sep 2009
    Location
    Wroclaw, Poland
    Posts
    1,394
    Thanked 342 Times in 324 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows Android

    Default Re: How to convert *.txt files to *.obj files?

    is it the structure you are referring to or something else?
    Yes, I am referring to a structure of the file. Is it just as simple as wysota mentioned, different extension given to the same file format ?

Similar Threads

  1. Replies: 9
    Last Post: 28th April 2010, 09:18
  2. Replies: 12
    Last Post: 17th June 2009, 05:34
  3. Convert Windows .rc files for use by Qt?
    By pineweasel in forum Newbie
    Replies: 1
    Last Post: 1st June 2009, 15:53
  4. visual studio project files - adding extra files
    By luf in forum Qt Programming
    Replies: 3
    Last Post: 13th June 2008, 21:05
  5. how to save sequences of text files and sound files
    By nagpalma in forum Qt Programming
    Replies: 8
    Last Post: 3rd July 2007, 00:06

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.