• Login
sketchucation logo sketchucation
  • Login
๐Ÿค‘ SketchPlus 1.3 | 44 Tools for $15 until June 20th Buy Now

Delete all textures from materials?

Scheduled Pinned Locked Moved Plugins
4 Posts 3 Posters 1.0k Views
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.
  • G Offline
    gnome_mo
    last edited by 1 Apr 2020, 11:47

    So, I have an issue with some imported models from ArchiCAD.
    Solution would be to delete all textures from materials while keeping the actual material - for example brick material would still be named Brick but instead of texture, it would only be red color.
    Is this possible in any way except unchecking textures one by one?
    Thank you in advance.

    1 Reply Last reply Reply Quote 0
    • T Online
      TIG Moderator
      last edited by 1 Apr 2020, 12:30

      Copy/paste all of this code into the Ruby Console + enter

      model=Sketchup.active_model
      model.start_operation('NoTex', true)
      model.materials.each{|m| m.texture=nil }
      model.commit_operation
      

      It's one-step undo-able...

      All materials in the model will now NOT have a texture...

      TIG

      1 Reply Last reply Reply Quote 0
      • G Offline
        gnome_mo
        last edited by 1 Apr 2020, 13:19

        @tig said:

        Copy/paste all of this code into the Ruby Console + enter

        model=Sketchup.active_model
        > model.start_operation('NoTex', true)
        > model.materials.each{|m| m.texture=nil }
        > model.commit_operation
        

        It's one-step undo-able...

        All materials in the model will now NOT have a texture...

        That did the trick! Thanks TIG, you're the best ๐Ÿ˜„

        1 Reply Last reply Reply Quote 0
        • H Offline
          HornOxx
          last edited by 1 Apr 2020, 17:31

          ๐Ÿ˜ฎ great & thanks Tig
          And it is great that the interpolated colors from the now deleted textures remain ๐Ÿ‘

          never trust a skinny cook

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

          Advertisement