Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: m15 utils

  1. #1
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397

    m15 utils

    This is a small utility that analyzes a m15 file and tells you the number of vertices, quads, triangles and polygons that are in the m15 file.

    Just click on the Add/Load Model button and you can select multiple m15 files at one time.
    Check the window caption for the status of what is going on. Some files with lots of vertices can take some time to analyze.

    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	m15 utils screenshot.PNG 
Views:	181 
Size:	20.8 KB 
ID:	4375  
    Attached Files Attached Files
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  2. #2
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    6,778
    Blog Entries
    3
    Rep Power
    691

    Re: m15 utils

    Hi Kent,

    very interesting utility.
    Just few things:
    • When I click "Add model" it opens Open dialog in MyDocuments path - I would prefer program path
    • On some models I get GPF, try attached one


    Fact is that the attached model has some color problems in thinEdge_Viewer too , it is older one so maybe something is wrong with it.


    Thanks,
    Petr
    Attached Files Attached Files
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 7 64bit - Intel Core 2 Duo T6600 @ 2.2GHz - 4 GB RAM - NVIDIA GeForce G210M 512MB
    Windows 8 64bit - Intel Core i5-3350P @ 3.1GHz - 8 GB RAM - NVIDIA GeForce GT640 3GB

  3. #3
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397

    Re: m15 utils

    I got a fault too Petr.... strange as I tested on my computer with a lot of m15 files... it must be something in the file. I will need to look study when more awake
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  4. #4
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    6,778
    Blog Entries
    3
    Rep Power
    691

    Re: m15 utils

    Do not worry so much,

    it is possible that file is corrupted. Maybe you could just put analysing in TRY/EXCEPT block and put in ShowMessage something.


    Thanks,
    Petr


    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 7 64bit - Intel Core 2 Duo T6600 @ 2.2GHz - 4 GB RAM - NVIDIA GeForce G210M 512MB
    Windows 8 64bit - Intel Core i5-3350P @ 3.1GHz - 8 GB RAM - NVIDIA GeForce GT640 3GB

  5. #5
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397

    Re: m15 utils

    Petr I can verify that it is a bug in my program. My viewer I wrote in PowerBasic is able to open up the file with no problems. It must be in the quad / triangle analysis as the powerbasic one doesn't do that.

    Thanks for helping me trace down problems.
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  6. #6
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397

    Re: m15 utils

    I found out what the problem is. I thought we discussed this, but maybe I am wrong... I thought only quads or triangles were saved out. In this file I see some polys with more than 4 verts making a face. I guess I need to check for regular polygons then too. I will need to put that in. Feels good to track the problem down... it was driving me crazy wondering what was wrong

    Ok, I also found a bug in the m15 file... the VERTEXNUM is off from what is actually there by a few vertices.
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  7. #7
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    6,778
    Blog Entries
    3
    Rep Power
    691

    Re: m15 utils

    Good job Kent,

    you were faster than me in catching the problem, perfect!


    Thanks a lot,
    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 7 64bit - Intel Core 2 Duo T6600 @ 2.2GHz - 4 GB RAM - NVIDIA GeForce G210M 512MB
    Windows 8 64bit - Intel Core i5-3350P @ 3.1GHz - 8 GB RAM - NVIDIA GeForce GT640 3GB

  8. #8
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397

    Re: m15 utils

    Even though the m15 util was buggy... it helped do what it is to do, that is analyze an m15 file.

    I will finish fixing the bugs and put the new version up today.

    Added later: There is something really wrong with my application and that m15 file. When I assign the red color value from line 20 it messes up the vertex count.
    I have no idea why?

    I will try to rewrite the whole thing in PowerBasic and see what happens, so there will be a delay in getting a nice working version, sorry about that.
    I will remove the download from the first post for now and put up a good working one when I can write it
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  9. #9
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397

    Re: m15 utils

    It seems to be working fine now. The latest version 4 is available in the first post in this thread.
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  10. #10
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    6,778
    Blog Entries
    3
    Rep Power
    691

    Re: m15 utils

    Kent,

    thanks a lot, works nice!

    I have one crazy idea, if too mad please stop me.

    I have in head idea of "release advisor" for longer time.
    You would pass directory where you have script ( game ), and it would make some stats and suggestions.

    You could view models, sort them by vertexcount/polycount, it could also check whether textures are power of two...

    So you could see where possible bottlenecks ( model uses more than texture, too high polycount ) are, if there is need for texture resize and so on.

    What do you think? I would not let all this work on you of course, when I will have more time ( soon! ) I could contribute some code too.


    Bye,
    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 7 64bit - Intel Core 2 Duo T6600 @ 2.2GHz - 4 GB RAM - NVIDIA GeForce G210M 512MB
    Windows 8 64bit - Intel Core i5-3350P @ 3.1GHz - 8 GB RAM - NVIDIA GeForce GT640 3GB

Page 1 of 2 12 LastLast

Posting Permissions

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