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

    How does material color multiplication works?

    Scheduled Pinned Locked Moved Developers' Forum
    7 Posts 4 Posters 1.2k Views 4 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.
    • fuzzybroF Offline
      fuzzybro
      last edited by

      When material has a texture and color the result is really weird. It is not just texture and color multiplication as commonly seen in computer graphics. How does it work in Sketchup so I can reproduce it in other renderer?

      Thanks

      [OctaneRender for SketchUp Overview and Demo Version(http://sketchucation.com/click.php?url)]

      Latest updates, tutorials and artwork
      facebook.com/octane4sketchup

      1 Reply Last reply Reply Quote 0
      • tt_suT Offline
        tt_su
        last edited by

        Material color multiplication? What do you mean?

        1 Reply Last reply Reply Quote 0
        • A Offline
          Aerilius
          last edited by

          SketchUp's UI has two ways to modify the color of a textured material: You can color-shift the texture image (it still preserves color differences, but with an emphasis at a different Sketchup::Color)
          and you can colorize the texture image (boolean, preserves only the brightness, sets the hue and saturation to a specific color).

          The API does not differentiate between the two, so when you read color from a color-shifted material and set the same value again, it will be not just be color-shifted but colorized. It's better not to use these properties in Ruby scripts.

          You can however "bake" the color-shift/colorization into a texture when exporting textures with the Sketchup::TextureWriter.

          1 Reply Last reply Reply Quote 0
          • tt_suT Offline
            tt_su
            last edited by

            Ah! That color adjustment features.

            The Colorize function just converts it to a grayscale and maps that to the selected color.

            I'll look into the color shifting. I have always thought it was a blend going on - but I'll see if I can dig into the code and see what actually happens.

            1 Reply Last reply Reply Quote 0
            • tt_suT Offline
              tt_su
              last edited by

              It does a HSL shift.

              1 Reply Last reply Reply Quote 0
              • nikusknxN Offline
                nikusknx
                last edited by

                @tt_su said:

                It does a HSL shift.

                Hi,
                If we have the original rgb texture, and the hls or rgb color of the texture, what is the opertion to do to each pixel to create the new material with color like the Sketchup texture writer???

                thanks

                1 Reply Last reply Reply Quote 0
                • tt_suT Offline
                  tt_su
                  last edited by

                  I would need the deltas, and know whether the material is HSL shifted or tinted - something the Ruby API doesn't expose right now. But we have an issue open to address that.

                  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