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

    Script idea...

    Scheduled Pinned Locked Moved Developers' Forum
    12 Posts 6 Posters 2.4k Views 6 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.
    • M Offline
      Matt666
      last edited by Matt666

      Hi,

      Thank you for all scripts created here !! 😍

      I have a suggestion (here for french users, and for the based post) for a new script which I believe is feasible for someone familiar with ruby script.

      Beeing a carpenter, I often use wood textures and the problem is that one time out of two they are not in the rigth orientation as far as the wood grain is concern.Sans titre 1.jpg
      Most of the time the wood grain has to be oriented along the longest dimension of a surface.Sans titre 2.jpg
      It would be nice to have a ruby script that detect this situation and does orient the grain of the wood texture in the right direction.

      Procedure :
      1- Selection
      2- Texturise faces in along the longest dimension
      3- Question : is it the right sense ?
      3b - No ? Rotate textures at 90Β°.
      4- Validate.

      What do you think about that ? Reasonnable ? Do you agree it will be a nice script ?

      Thank you !!

      PS : Thanks to Bert for the translation of this post πŸ˜‰ But he doesn't translate the end !! The faults are mine !! πŸ˜„

      Frenglish at its best !
      My scripts

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

        now youve mentioned it the idea makes perfect sense. It would be cool to see it done, although its a pity its not a native SU feature, then it could be on all the time.

        One potential issue: what happens with end grains?

        http://remusrendering.wordpress.com/

        1 Reply Last reply Reply Quote 0
        • alexschreyerA Offline
          alexschreyer Extension Creator
          last edited by

          Even better: Get the plugin to check primary orientation of component/group and apply lengthwise to longest sides. At the same time, apply end-grain texture to shortest ends. Of course, we still need a way to manually override this. The plugin could even have a drop-down selection for different woods.

          Author of "Architectural Design with SketchUp":
          http://sketchupfordesign.com/

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

            I tihnk the manual over ride thing would be pretty simple really: youd jsut run the script, and thne if you needed to change anything youd just change it as noraml. Perhaps have a 'lock texture' button as well, in case you have to run the script again.

            http://remusrendering.wordpress.com/

            1 Reply Last reply Reply Quote 0
            • M Offline
              Matt666
              last edited by

              Hi !
              Sorry I have a bad English!

              @unknownuser said:

              One potential issue: what happens with end grains?

              what does mean "end grains" ?

              @unknownuser said:

              its a pity its not a native SU feature,

              I agree with you, Remus... 😲

              Frenglish at its best !
              My scripts

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

                @unknownuser said:

                what does mean "end grains" ?

                I believe he is referring to the cross cut, or end of the board


                end grain

                Hank

                1 Reply Last reply Reply Quote 0
                • M Offline
                  Matt666
                  last edited by

                  Oh !! Ok I see !! πŸ˜„

                  Generally in furniture manufacturing, we don't see end grains.
                  For example, when we have to make a shelf, we produce a belt around the shelf. So, no end grains.

                  SO the script can apply textures along the longest dimension on each face !

                  Frenglish at its best !
                  My scripts

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

                    My TextureHelper script was created after a similar request for an easy way to orient wood grain textures. It's not automatic, but it is quick - click a face to rotate the texture, or shift-click to scale the texture (ctrl-click will reverse rotate, and ctrl-shift-click will inverse scale).

                    RickW
                    [www.smustard.com](http://www.smustard.com)

                    1 Reply Last reply Reply Quote 0
                    • M Offline
                      Matt666
                      last edited by

                      Hello Rick !

                      Yes, i've seen your script, but I thought it can't completly do what I want. That's why I have asked here if someone could create this plugin...

                      @unknownuser said:

                      It's not automatic, but it is quick

                      The problem is I often use textures... A plugin which texturises a selection automaticaly would be sooo useful, and fast !

                      Frenglish at its best !
                      My scripts

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

                        The main problems in creating an "automatic" script are 1) knowing which direction the texture runs (is it up-down or left-right), and 2) reading the user's mind to assign the correct orientation.

                        #1 is handled by making an assumption that all textures are up-down orientation
                        #2 could be handled by orienting along the longest edge, but that also assumes SketchUp applied the texture oriented to the short edge.

                        I can look at this and see if a script could work.

                        RickW
                        [www.smustard.com](http://www.smustard.com)

                        1 Reply Last reply Reply Quote 0
                        • M Offline
                          Matt666
                          last edited by

                          Hello Rick !
                          Sorry, I'm French, so I understand your message coarsely πŸ˜•

                          @unknownuser said:

                          is handled by making an assumption that all textures are up-down orientation

                          I think it's not important... Because as you say, SU can't read user's mind.
                          So I think the solution is to ask a question "is it the right sense ?" after the textures creations. Because we can't know the direction of a texture definition (I think)... If the answer is no, the script have to rotate all the textures perpendicularly.
                          What do you think about that ??

                          @unknownuser said:

                          but that also assumes SketchUp applied the texture oriented to the short edge.

                          I had not thought about this problem... So we can't have control on which direction the texture will take ? Means faces have a direction when they've been created ? 😲 And textures are placed depending the face direction ? Sorry for my questions... πŸ˜•

                          @unknownuser said:

                          I can look at this and see if a script could work.

                          Really ??? 😍 😍 😍
                          Thank you Rick !

                          PS : Sorry for my "Frenglish"....

                          Frenglish at its best !
                          My scripts

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

                            Here's a link to a plugin that does what you want for max. Might give developers ideas on how to do it for SU.

                            http://www.vg2max.spb.ru/PolygonMap.htm

                            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