sketchucation logo sketchucation
    • Login
    ℹ️ GoFundMe | Our friend Gus Robatto needs some help in a challenging time Learn More

    Convert Color by Layer Colors...

    Scheduled Pinned Locked Moved SketchUp Discussions
    sketchup
    9 Posts 5 Posters 1.2k 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.
    • Y Offline
      yahellid
      last edited by

      I've been trying to find a good solution to my problem involving color by layer. When I import a DWG into Sketchup from Revit, there is no material information, but all things come in on separate layers. If I color by layer, I can have the layers color or texture settings all setup so that I can simply reimport a revised dwg file and all the layers will appear as I want them to. This can almost work like an xref or Sketchup component.

      But can I take that model and convert the colors to correspond to the objects themselves and not just the layer?

      This could be the final solution to working from Autocad to Revit into Sketchup seamlessly. The benefits of that equation can be discussed, but the problem remains.

      Any thoughts?

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

        Obviously using a Style that has 'Color by Layer' will display things as you want... BUT to turn each object's color to match its Layer Color and then swap to the more normal 'Color by Material' it is NOT an easy task... There is currently no API method to get a Layer's Color. I wrote a hack to set a Layer's color BUT the reverse is not readily possible...
        You could perhaps export a DXF of the SKP read every Layer name back in with its CAD color and reverse engineer that into an RGB color... but seems extreme ?
        I think AdamB was hopeful about reading Layer colors from the SKP db... but I've heard nothing about it lately... 😕
        http://groups.google.com/group/sketchupruby/browse_thread/thread/ca5c730306b91246
        and
        http://forums.sketchucation.com/viewtopic.php?f=180&t=25697&p=311870#p311870

        TIG

        1 Reply Last reply Reply Quote 0
        • Y Offline
          yahellid
          last edited by

          Thanks for the reply TIG.

          It seems there are ways to do something once, which may be messy, but you do what you have to do. But having a systematic workthough that is untedious-ly repeatable is a whole other.

          1 Reply Last reply Reply Quote 0
          • Al HartA Offline
            Al Hart
            last edited by

            Is there a ruby anywhere to assign a SketchUp material to faces to match the name of the layer - but without trying to get the color from the color by layer. If so, then it would be relatively simple to set SketchUp materials for one or two layers.

            I thought I had tried a ruby which did that sometime ago, but I can;'t seem to find it again.

            (I found this thread while looking for just that plugin. Unfortunately it is hard to search for "Convert layer to material)

            Al Hart

            http://wiki.renderplus.com/images/e/ef/Render_plus_colored30x30%29.PNG
            IRender nXt from Render Plus

            1 Reply Last reply Reply Quote 0
            • Al HartA Offline
              Al Hart
              last edited by

              I found the ruby - layers_materials.rb - although it doesn't seem to work in SU 8.

              Al Hart

              http://wiki.renderplus.com/images/e/ef/Render_plus_colored30x30%29.PNG
              IRender nXt from Render Plus

              1 Reply Last reply Reply Quote 0
              • N Offline
                narlee
                last edited by

                I found a post at http://www.sketchucation.com/forums/viewtopic.php?f=180&t=23650&start=0, where TIG provides a link to DXFlayercols.rb. But I have to login to access the link and I can't seem to login and get back to that page without it asking me to login again (stuck in do-loop hell!).

                1 Reply Last reply Reply Quote 0
                • N Offline
                  narlee
                  last edited by

                  I found TIG's DXFlayerscols.rb, but it doesn't seem to do anything, at least for SU 8

                  1 Reply Last reply Reply Quote 0
                  • arail1A Offline
                    arail1
                    last edited by

                    I'd really like a plugin like this. I find myself struggling a lot with the organization of materials and layers. In modo, my other primary application, it's quite straightforward and very simple.

                    1 Reply Last reply Reply Quote 0
                    • Al HartA Offline
                      Al Hart
                      last edited by

                      I took a look at getting Didiers's Layer Names to Materials ruby working.

                      I posted a new version in this thread:

                      http://forums.sketchucation.com/viewtopic.php?f=323&t=36715

                      Convert Layer Names to Materials.jpg


                      convert_materials_to_layer_names.rb

                      Al Hart

                      http://wiki.renderplus.com/images/e/ef/Render_plus_colored30x30%29.PNG
                      IRender nXt from Render Plus

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

                      Advertisement