sketchucation logo sketchucation
    • Login
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info

    Color by Height?

    Scheduled Pinned Locked Moved Plugins
    19 Posts 11 Posters 3.0k Views 11 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.
    • Didier BurD Offline
      Didier Bur
      last edited by

      Hi,
      Maybe my Mesh2Heightmap script will help.
      Here is the description:
      Generates an image of the model (generally plan view) that can be used as a heightmap.
      BMP and RAW formats supported, mask, blur, crop options. Doc included.

      Can be DL here: http://rhin.crai.archi.fr/RubyLibraryDepot/plugin_details.php?id=585
      heightmap.jpg
      Hope this helps,

      DB

      1 Reply Last reply Reply Quote 0
      • Dave RD Offline
        Dave R
        last edited by

        Thanks Didier, it might work but after installing it and trying to start SU, I get an immediate bugsplat before the program can open it. I renamed the file so it wouldn't load and the bugsplats don't happen.

        Etaoin Shrdlu

        %

        (THERE'S NO PLACE LIKE)

        G28 X0.0 Y0.0 Z0.0

        M30

        %

        1 Reply Last reply Reply Quote 0
        • J Offline
          jopsa2
          last edited by

          hi dave!
          ive actually used Sketchup Fog in the past to export depth maps,kind of explained it in this thread:

          http://forums.sketchucation.com/viewtopic.php?f=18&t=21987

          but basically, switch of all edges, turn fog colour to black, and face colour to monochrome.

          works best with objects that aren't too deep, here's an example:

          moldura 01 DISP.jpg

          4. cornisa 009.jpg

          1 Reply Last reply Reply Quote 0
          • Dave RD Offline
            Dave R
            last edited by

            Thank you Jopsa2,

            I gave that a try and sent the image to my friend. He said it worked very well.

            http://farm5.static.flickr.com/4098/4765059183_63f4bf32a5_z.jpg

            Etaoin Shrdlu

            %

            (THERE'S NO PLACE LIKE)

            G28 X0.0 Y0.0 Z0.0

            M30

            %

            1 Reply Last reply Reply Quote 0
            • TaffGochT Offline
              TaffGoch
              last edited by

              With some "calibration" of greyscale-to-depth, I can see this as being very useful, if it will work with the Sears CompuCarve (same as CarveWright.)

              I don't have one, as they were a bit too pricy, when first introduced. Perhaps, it's time to take another look....


              Dave, "Quando omni flunkus, moritati" ? -- I should'a known... πŸ˜†

              ..."If the women don't find you handsome, they should at least find you handy."

              At least, I'm handy....

              -Taff

              "Information is not knowledge." -- Albert Einstein

              1 Reply Last reply Reply Quote 0
              • Dave RD Offline
                Dave R
                last edited by

                Taff,

                I don't know a lot about setting up gray scale images for the CarveWright/CompuCarve machines but the friend who was asking about this said that the software seemed happy enough with the image I posted. I looked at the machines with some interest a few years ago when they first came out. I found they were a bit limited for the sorts of things I want a computer-driven machine for so I kind of forgot about them until this came up.

                BTW, I work real hard to be handy. Haven't got the other thing going for me after all. πŸ˜„

                Etaoin Shrdlu

                %

                (THERE'S NO PLACE LIKE)

                G28 X0.0 Y0.0 Z0.0

                M30

                %

                1 Reply Last reply Reply Quote 0
                • Chris FullmerC Offline
                  Chris Fullmer
                  last edited by

                  Hey Dave,sorry I have not gotten back to you yet. I see that you were able to get something use-able. Color by z could be altered to force it to use only a certain amount of colors for sure, to limit it to 5 or 6 shades. But it looks like you've a system working, so that seems good enough for me πŸ˜„

                  Chris

                  Lately you've been tan, suspicious for the winter.
                  All my Plugins I've written

                  1 Reply Last reply Reply Quote 0
                  • GaieusG Offline
                    Gaieus
                    last edited by

                    Hi Dave,

                    This is another extremely cool way of generating these maps!
                    πŸ‘ πŸ‘ πŸ‘

                    Gai...

                    1 Reply Last reply Reply Quote 0
                    • thomthomT Offline
                      thomthom
                      last edited by

                      @davidlouis said:

                      so its Vray friendly too.

                      Except that VRay doesn't render distorted textures very well. And projection often create lots of it. But if the mesh is triangualted well enough the error might not be particularly visible.

                      Thomas Thomassen β€” SketchUp Monkey & Coding addict
                      List of my plugins and link to the CookieWare fund

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

                        Hi Thom

                        I meant its Vray friendly in the sense that it doesn't generate large quantities (even hundreds) of materials based on the colour graduation as in Color by Z.

                        The displacement map generated was a spin off from thread and i figured if i had alrady sucessfully used a colour gradient, why not a grayscale and the bonus of the displacement map out of it.

                        I agree with you about the Vray displacement map thing... I tested it in vray with mixed results.

                        Got a pretty decent result out of cinema 4d though! see attached
                        I'm assuming that the CNC machine thingy might be able to use this too...

                        Dave


                        displacement.jpg

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

                          Nice method David πŸ‘

                          http://dmdarchitecture.co.uk/

                          1 Reply Last reply Reply Quote 0
                          • Dave RD Offline
                            Dave R
                            last edited by

                            Hi David,

                            That does seem like a very nice method. I'll pass it on to my friend and have him give it a go. Thank you.

                            Etaoin Shrdlu

                            %

                            (THERE'S NO PLACE LIKE)

                            G28 X0.0 Y0.0 Z0.0

                            M30

                            %

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

                              If i may add my two cents worth...

                              I have been able to produce 'height maps' of terrain studies using a projected texture.
                              This could basically be used on any 3d object

                              Method:

                              1.Basically you create a color/grayscale gradient image in photoshop or otherwise,
                              2.Import into sketchup as a texture onto a vertical plane (rectangle) that represents the extent of the terrain. The vertical extent of this rectangle is more crucial than the horizontal.
                              3.Once you have the texture on the rectangle, go to the edit texture context menu and click on 'projected'.
                              4. Then sample the projected texture off the rectangle... choose all the surfaces of the terrain and apply.

                              Voila!

                              additional tips:
                              A:Do not apply the sampled projected texture to a group, it will not apply properly. You need to assign the material directly to the faces.
                              B:When making the vertical rectangle to represent the extents of your terrain it helps to overshoot the exact size a bit both top and bottom so that you don't pick up the extreme edge of the color gradient and start of the next tile of the gradient which can sometimes render as a dark colour.

                              This can obviously be done with a grayscale gradient too which i imagine could be used to generate a displacement map (exported jpg from a top view) similar to what Dave R and jopsa2 have been talking about.

                              Also in comparison to Chris's Color by Z plugin, although this is not technically a plugin, its avoids a multitude of generated materials, instead this one uses just one... so its Vray friendly too.

                              Attached is a sample image for reference.

                              Hope this helps.

                              Dave


                              height&displacement map.jpg

                              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