[Plugin] Model Info

[Plugin] Model Info

Postby thomthom » Thu Dec 09, 2010 2:09 pm

Overview
Outputs the model statistics to either console or file.

ModelInfo.png


Version 1.1.0
Count the triangles of each face. In tests this is more than three times slower - so it has been made into an extended function.

ExtendedModelInfo.png


Counting triangles is more accurate indication to how complex the model is. As the following screenshot illustrate - the two scenes has identical number of faces, but the number of triangles required to generate the faces is significantly different due to the inner holes in the upper example.
FaceVsTriangles.png


Version 1.2.0
Outputs the component statistics.

ModelInfoCompStat.png


Access
Plugins > Model Info

Features
  • Statistics to File
  • Statistics to Console
  • Extended Statistics to File (1.1.0)
  • Extended Statistics to Console (1.1.0)

Requirements
  • SketchUp 6 or newer - ( Other versions untested )
  • TT_Lib2 (v2.4.0)

Download



Footprint
<Sketchup>/Plugins/
+-
tt_model_info.rb

0
Last edited by thomthom on Sat Jan 18, 2014 1:22 pm, edited 1 time in total.
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.0.0) — 09 Desember 2010

Postby Gaieus » Thu Dec 09, 2010 2:17 pm

Nifty! :thumb:
0
User avatar
Gaieus 
 

Re: [Plugin] Model Info (1.0.0) — 09 Desember 2010

Postby solo » Thu Dec 09, 2010 2:19 pm

Thom, how about a call out on how many poly's have been used?
0
www.solos-art.com

I'm a social vegan, I avoid meet.
User avatar
solo 
Global Moderator
 

Re: [Plugin] Model Info (1.0.0) — 09 Desember 2010

Postby thomthom » Thu Dec 09, 2010 2:38 pm

You mean triangles?
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.0.0) — 09 Desember 2010

Postby Rich O Brien » Thu Dec 09, 2010 2:53 pm

Doesn't Fredo have this?

viewtopic.php?t=30976
0
There's a frontroom and a backroom....reverse faces
User avatar
Rich O Brien 
Administrator
 

Re: [Plugin] Model Info (1.0.0) — 09 Desember 2010

Postby solo » Thu Dec 09, 2010 2:59 pm

Ah, cool one, never seen that before, thanks Rich.

Thom, I guess there is a lot more to it than just reporting amount of faces as SU does not use triangles, they are n-gons.
Kinda hard to figure out SU's limit due to this inconsistency, had it been triangle based one could get a clearer idea.
0
www.solos-art.com

I'm a social vegan, I avoid meet.
User avatar
solo 
Global Moderator
 

Re: [Plugin] Model Info (1.0.0) — 09 Desember 2010

Postby Gaieus » Thu Dec 09, 2010 3:18 pm

If you export your model to 3ds or dae, it will get triangulated. When re-importing without merging co-planar faces, you get a clearer poly count with triangles.
0
User avatar
Gaieus 
 

Re: [Plugin] Model Info (1.0.0) — 09 Desember 2010

Postby thomthom » Thu Dec 09, 2010 3:24 pm

solo wrote:Thom, I guess there is a lot more to it than just reporting amount of faces as SU does not use triangles, they are n-gons.
Kinda hard to figure out SU's limit due to this inconsistency, had it been triangle based one could get a clearer idea.

Can extract the internal triangulation. SU makes that available to the API. My Probe plugin lets you inspect how SU triangulates faces.
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.1.0) — 09 Desember 2010

Postby thomthom » Thu Dec 09, 2010 3:49 pm

Ok. Did a quick update - added triangle count if you choose Extended Model Info. (Note it's at least three times slower.)
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.1.1) — 09 Desember 2010

Postby glro » Thu Dec 09, 2010 4:47 pm

thomthom wrote:Overview
Outputs the model statistics to either console or file.
...



this is interesting...

when you choose statistics, you have 2 options:
> entire model (that's what you exported)
> components

could you do the same job, but for "components" instead, and precisely with the developped hierarchy?
0

glro 
 

Re: [Plugin] Model Info (1.1.1) — 09 Desember 2010

Postby thomthom » Thu Dec 09, 2010 8:47 pm

glro wrote:could you do the same job, but for "components" instead, and precisely with the developped hierarchy?


You mean the stats for a selected component?

What do you mean by the "developed hierachy"?
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.1.1) — 09 Desember 2010

Postby glro » Thu Dec 09, 2010 9:30 pm

thomthom wrote:
glro wrote:could you do the same job, but for "components" instead, and precisely with the developped hierarchy?


You mean the stats for a selected component?

What do you mean by the "developed hierachy"?


the stats for components, instead of "for the whole model"

this...
0

glro 
 

Re: [Plugin] Model Info (1.1.1) — 09 Desember 2010

Postby thomthom » Thu Dec 09, 2010 9:40 pm

Oooh... I never noticed that option before! :shock:
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.1.1) — 09 Desember 2010

Postby glro » Thu Dec 09, 2010 10:03 pm

thomthom wrote:Oooh... I never noticed that option before! :shock:


if you choose this option, the statistics include the nestled components
the whole problem is: how to retrieve this information?

i think i might have a solution coming, but since it is not finished, i have to wait
0

glro 
 

Re: [Plugin] Model Info (1.1.1) — 09 Desember 2010

Postby thomthom » Thu Dec 09, 2010 10:10 pm

I can make it produce that info - just got to wait until next week. Moving apartment this weekend.
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.1.1) — 09 Desember 2010

Postby thomthom » Mon Dec 13, 2010 1:19 pm

glro wrote:
thomthom wrote:Oooh... I never noticed that option before! :shock:


if you choose this option, the statistics include the nestled components
the whole problem is: how to retrieve this information?

i think i might have a solution coming, but since it is not finished, i have to wait

Version 1.2.0
Outputs the component statistics.
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.2.0) — 13 Desember 2010

Postby Dave R » Mon Dec 13, 2010 3:20 pm



Thomthom, thank you for this cool plugin. I have noticed an odd thing, though. I copied and pasted a few components from a file called "spinet desk" to a new file and saved it as a new file. Evidently the plugin is still looking at the other, closed original file and giving the stats for that as well. Or is it possible the console isn't cleared when switching to a different SKP file? Is it possible to clear the contents of the console before processing and displaying a new run of the plugin?
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] Model Info (1.2.0) — 13 Desember 2010

Postby thomthom » Mon Dec 13, 2010 3:30 pm

Dave R wrote:vidently the plugin is still looking at the other, closed original file and giving the stats for that as well. Or is it possible the console isn't cleared when switching to a different SKP file?

The console output is not interactive. Just a history of the output. You find the latest output at the bottom. Notice that in your screenshot it says "Drawer.skp" further down.

Dave R wrote:Is it possible to clear the contents of the console before processing and displaying a new run of the plugin?

I have a Windows hack I could add. Don't know how to do it for OSX. ...but you might have some that don't want it cleared... I'd rather not add too many options to this. It's just a quick and dirty plugin.
0
Thomas Thomassen — SketchUp Monkey & Coding addict
List of my plugins and link to the CookieWare fund
User avatar
thomthom 
PluginStore Author
PluginStore Author
 

Re: [Plugin] Model Info (1.2.0) — 13 Desember 2010

Postby Dave R » Mon Dec 13, 2010 3:41 pm

Understood. Thank you for this.
0
%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] Model Info (1.2.0) — 13 Desember 2010

Postby Ben Ritter » Mon Dec 13, 2010 5:29 pm

Thank you again TIG.
0

Ben Ritter 
 

Re: [Plugin] Model Info (1.2.0) — 13 Desember 2010

Postby f123f0507 » Sun Jul 21, 2013 5:08 am

Thank you again TIG.
0

f123f0507 
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 



 

Return to Plugins

Who is online

Users browsing this forum: Majestic-12 Bot and 8 guests

Visit our sponsors: