Reading SKP thumbnail
-
Hi,
I have made a search but haven't found a solution yet.
Does someone know a way to read a thumbnail stored in SKP file?
If SU Team could give us info on where we can find its location and a size, that would be enough
Tomasz
-
I also thought that tbd wrote a thumbnail extract utility, a long time ago.
-
IF SketchUp is loaded, you can generate an image file for any skp file using:
Sketchup::save_thumbnailIf not, the thumbnail should be in the normal place and size required by Windows, so popular graphic utilities (like ImageMajik,) or C function calls can retrieve it.
Checking the code snippets index, we have:
[ cod e] extract png thumbnail image from .skp file
... which has both outside and inside SketchUp examples.
-
Thanks! I have checked 3 or more pages with search result, but didn't find the snippets post. I will be checking it first now.
I want extract them directly from files, without opening them in SU.
Jim's extract_png.rb looks like a good solution. -
@tomasz said:
I want extract them directly from files, without opening them in SU.
Jim's extract_png.rb looks like a good solution.You do not need to open the file(s) using:
Sketchup::save_thumbnail
.. just that you must use it from within SketchUp Ruby. -
@dan rathbun said:
You do not need to open the file(s) using:
Sketchup::save_thumbnail
.. just that you must use it from within SketchUp Ruby.Right, I didn't realize that there is a path parameter in this method!
-
blink -- me neither! I guess I always just skipped over that method...
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better π
Register LoginAdvertisement