sketchucation logo sketchucation
    • Login
    ⌛ Sale Ending | 30% Off Profile Builder 4 ends 30th September

    [Plugin] Very fast texture writer

    Scheduled Pinned Locked Moved Plugins
    44 Posts 18 Posters 91.6k Views 18 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Lemoyne ArchitectL Offline
      Lemoyne Architect
      last edited by

      Ok, I finally went in and made a copy of one of the SKM files, renamed it to .ZIP, opened it, and looked at the files. The JPG file in there has the alphanumeric filename I’m encountering. Doing the same with some other materials gets a filename based on the material name.

      So, in this case, the materials I’m trying to work with just have random alphanumeric filenames for the JPGs they originally created the materials from - so that is all that fast_tw is able to extract. It’s a fault of the materials I’m working with and nothing to do with fast_tw.

      1 Reply Last reply Reply Quote 0
      • D Offline
        driven
        last edited by

        @lemoyne architect said:

        ..The JPG file in there has the alphanumeric filename I’m encountering. the same with some other materials gets a filename based on the material name...

        glad you resolved it, but I'm now curious did the name show as that in the material browser?

        john

        learn from the mistakes of others, you may not live long enough to make them all yourself...

        1 Reply Last reply Reply Quote 0
        • Lemoyne ArchitectL Offline
          Lemoyne Architect
          last edited by

          No, that was what was confusing me. I had downloaded a model from the 3DWarehouse, but wanted to modify the materials being used. There were enough that I was looking for an easy way to strip them out rather than right clicking on each and every material and editing them individually - hence doing a search and finding fast_tw.

          Playing around with fast_tw and other materials, most of the time someone names the JPG the same name as the material they create. In this case the materials were things like “Material001, Material002, Material003…” while the JPGs were named “4IASae2uulg1, NX054xYNCb63, QtIJ9RU2U1Mj…”

          To me, it would seem that would make it very difficult to keep things organized during the creation of the materials, but some people seem to just make things more difficult than they need to be.

          1 Reply Last reply Reply Quote 0
          • D Offline
            driven
            last edited by

            ahhh... Material001/2, etc and or <auto_1/2> etc... are name given when SU finds an 'unknown' material in an import or from the eyedropper...

            that looks like it uses the materials unique id for the jpg name...

            I think fast_tw could be tweaked to re-name the jpg and mat at the same time...

            john

            learn from the mistakes of others, you may not live long enough to make them all yourself...

            1 Reply Last reply Reply Quote 0
            • C Offline
              Craig2014
              last edited by

              Hi

              Does this work in SU2016?

              I cant see it anywhere after install, although the ruby script "fast_tw +" works in extracting all but 4 out of maybe 15 materials in my sample model.

              Is there an icon for this or menu shortcut in SU16 or is it only usable by Ruby?

              Thanks

              1 Reply Last reply Reply Quote 0
              • TIGT Offline
                TIG Moderator
                last edited by

                It's not an extension.
                It's some code to run from the Ruby Console.
                It's pretty old...
                It will work in v2016.
                You can add the menu item or toolbar yourself...
                There are many simple plugins from which you can crib the method[s]...

                Depending what you want to do with your texture images, v2016 also now has this additional thumbnail writing method [max resolution 128px] - this also includes non-textured materials.

                model=Sketchup.active_model
                folder=UI.select_directory(
                  title; "Select Folder for Thumbnails",
                  directory; File.dirname(model.path)
                )
                if folder
                  model.materials.each{|material|
                    thumbnail = File.join(folder, "#{material.display_name}.png")
                    material.write_thumbnail(thumbnail, 128)
                  }
                end
                

                TIG

                1 Reply Last reply Reply Quote 0
                • D Offline
                  driven
                  last edited by

                  @TIG, is there really a size limit on a PC...

                  I write them out at 512px in one of my plugins for mac...

                  john

                  learn from the mistakes of others, you may not live long enough to make them all yourself...

                  1 Reply Last reply Reply Quote 0
                  • TIGT Offline
                    TIG Moderator
                    last edited by

                    I've had several PC failures with a resolution > 128px [although it's not clearly limited in the API docs - but you know what those docs are like!!!], hence my suggestion of a max size...
                    BUT the PC users are free to try it with bigger sizes, and then disabuse me of my preconception [if they get it to work]...

                    TIG

                    1 Reply Last reply Reply Quote 0
                    • P Offline
                      paulower
                      last edited by

                      I was looking for a plugin like that. I had a file with many textures, but most were not applied to any object. When you export a 3DS file for example, the textures that were not applied to any face were not exported.

                      This Plugin helped me a lot because it exports all the textures that are in the model, including those that are not applied.

                      Thank you very much.

                      Baú SketchUp
                      Visite nosso blog.. Visit our blog Baú SketchUp

                      1 Reply Last reply Reply Quote 0
                      • onzkiO Offline
                        onzki
                        last edited by

                        Hi, old thread wondering for 2025 version, still working?


                        [/hr]Dell Alienware Area-51. SKU 2021 Pro. AutoCAD 2023. Landscape design firm

                        1 Reply Last reply Reply Quote 0
                        • TIGT Offline
                          TIG Moderator
                          last edited by

                          Probably OK - try it...

                          TIG

                          1 Reply Last reply Reply Quote 0
                          • 1
                          • 2
                          • 3
                          • 3 / 3
                          • First post
                            Last post
                          Buy SketchPlus
                          Buy SUbD
                          Buy WrapR
                          Buy eBook
                          Buy Modelur
                          Buy Vertex Tools
                          Buy SketchCuisine
                          Buy FormFonts

                          Advertisement