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

[Req] Texture Corrector.... PLEASE

Scheduled Pinned Locked Moved Plugins
40 Posts 10 Posters 10.1k 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.
  • F Offline
    free agent
    last edited by free agent 1 Oct 2008, 19:28

    Dear Rubie Script writing people
    im having some problems with some plants ive imported that have leaves maped with png images, the one side is mapped correctly and the reverse has that same texture on but is very small and incorrectly mapped, so i go about picking the texture of a face on a leave(where there are about ten faces to a leaf) then orbiting around the geometry and dumping that texture on the reverse side of that face, which mirrors it perfectly, however it takes an incredibly long and this method is only possible for smaller plants as correcting hundreds of leaves will take years
    ....amen

    http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

    1 Reply Last reply Reply Quote 0
    • R Offline
      RickW
      last edited by 1 Oct 2008, 20:52

      With one or more faces selected, try this in the ruby console:

      Sketchup.active_model.selection.each{|e| e.back_material=e.material if e.typename=="Face"}
      

      I suggest you start with 1 or 2 faces to see if it works as expected, since I don't have one of your models to test. If that works for you, let me know and I'll "put some skin on the bones". πŸ˜„

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

      1 Reply Last reply Reply Quote 0
      • F Offline
        free agent
        last edited by 1 Oct 2008, 21:32

        the model with texture


        texture to fix.skp

        http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

        1 Reply Last reply Reply Quote 0
        • F Offline
          free agent
          last edited by 1 Oct 2008, 21:39

          hey thanx for the quick response

          the most ive work with rubie before is opening the consol wondering: "what the hell is that for" then closing the thing...

          so i opened my model, isolated a leaf, pasted ur code in there... now what?

          http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

          1 Reply Last reply Reply Quote 0
          • R Offline
            RickW
            last edited by 1 Oct 2008, 22:28

            I'll have to do some digging on this.

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

            1 Reply Last reply Reply Quote 0
            • F Offline
              free agent
              last edited by 2 Oct 2008, 07:29

              thanx πŸ˜„ cant wait for this one πŸŽ‰

              http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

              1 Reply Last reply Reply Quote 0
              • F Offline
                free agent
                last edited by 4 Oct 2008, 19:25

                is this difficult rubie to make?

                as a matter of interest Vray's SR1 clipmaps dont translate to reverse face of geometry that has transparency assigned to it... so this rubie will be more considerable more handy than just something some guy wants... xfrog, evermotion, and onyx trees all use transparency maps on leaves (not as many with the evermotion stuff but thats too hi-poly anyway)

                peace

                http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

                1 Reply Last reply Reply Quote 0
                • T Offline
                  thomthom
                  last edited by 5 Oct 2008, 10:48

                  I'm interested in this ruby as well. And there's an army of people over at the AsgVIS forum that need this utility.

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

                  1 Reply Last reply Reply Quote 0
                  • T Offline
                    thomthom
                    last edited by 5 Oct 2008, 10:49

                    I'd even be willing to pay for this ruby.

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

                    1 Reply Last reply Reply Quote 0
                    • T Offline
                      thomthom
                      last edited by 5 Oct 2008, 19:59

                      SketchUp does some weird stuff when it comes to backfaces. If you have a face where you apply a transparent texture on the front it automatically mirrors on the back if the backface has the default material. If you stretch and distort the texture on the front it updates the back. But if you apply a backface material, and you break that link. After removing the backface material to default, SU doesn't reset the mapping co-ordinates. Not until you make a change to the front side again, then it synchronizes again.

                      So maybe an alternate method would be for the script to reset the backface material to default and "touch" the front material forcing SU to update the backface.

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

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        silver_shadow
                        last edited by 6 Oct 2008, 05:08

                        I would also see this rubie happen. A lot of times i get a tree fro mxfrog and the textures of the face is correct on the one side but all messed up on the other side. It makes it difficult to present to clients if you dont want to render it (because rendering fix the problem) and present it in raw sketchup.

                        1 Reply Last reply Reply Quote 0
                        • F Offline
                          free agent
                          last edited by 7 Oct 2008, 10:49

                          is this a difficult script to write???

                          http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

                          1 Reply Last reply Reply Quote 0
                          • F Offline
                            free agent
                            last edited by 10 Oct 2008, 11:44

                            seriously NOTHING????!!!!!

                            http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

                            1 Reply Last reply Reply Quote 0
                            • T Offline
                              tomasz
                              last edited by 13 Oct 2008, 16:28

                              Hi,
                              It can be done for a flat object as a leave. I will have to do this exercise for FrontFace ruby, so will try to cook something simultaneously. πŸ˜„
                              Tomasz

                              Author of [Thea Render for SketchUp](http://www.thearender.com/sketchup)

                              1 Reply Last reply Reply Quote 0
                              • T Offline
                                thomthom
                                last edited by 13 Oct 2008, 19:49

                                Excellent!

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

                                1 Reply Last reply Reply Quote 0
                                • 4 Offline
                                  40Th
                                  last edited by 24 Oct 2008, 09:58

                                  @rickw said:

                                  With one or more faces selected, try this in the ruby console:

                                  Sketchup.active_model.selection.each{|e| e.back_material=e.material if e.typename=="Face"}
                                  

                                  I suggest you start with 1 or 2 faces to see if it works as expected, since I don't have one of your models to test. If that works for you, let me know and I'll "put some skin on the bones". πŸ˜„

                                  How do i use this script? And does this script solves this issue? πŸ˜’

                                  1 Reply Last reply Reply Quote 0
                                  • R Offline
                                    RickW
                                    last edited by 24 Oct 2008, 17:03

                                    Unfortunately, it doesn't solve the problem. There's a lot more complexity to it than I first thought. That's why there isn't a solution posted yet...

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

                                    1 Reply Last reply Reply Quote 0
                                    • D Offline
                                      davide.skp
                                      last edited by 12 Nov 2008, 16:09

                                      Rick, this is essential plugin!!!
                                      because every 3d trees sw produce geometry like free agent say...

                                      1 Reply Last reply Reply Quote 0
                                      • T Offline
                                        thomthom
                                        last edited by 26 Nov 2008, 15:19

                                        Any news on this?

                                        Will pay money for it.

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

                                        1 Reply Last reply Reply Quote 0
                                        • F Offline
                                          free agent
                                          last edited by 2 Dec 2008, 07:49

                                          bump... πŸ˜›

                                          http://i167.photobucket.com/albums/u143/FreeAgent84/bug.gif

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

                                          Advertisement