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

    Elev45shadows.rb help

    Scheduled Pinned Locked Moved Developers' Forum
    24 Posts 4 Posters 2.8k 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.
    • TIGT Offline
      TIG Moderator
      last edited by

      The script forces a new place / country and north-angle, + sun=angle so that the shadows work at 45 degrees on that elevation. As I said I can't get it to reproduce here and It's fine on simialr set ups to yours... ???

      .

      TIG

      1 Reply Last reply Reply Quote 0
      • brodieB Offline
        brodie
        last edited by

        @tig said:

        The script forces a new place / country and north-angle, + sun=angle so that the shadows work at 45 degrees on that elevation. As I said I can't get it to reproduce here and It's fine on simialr set ups to yours... ???

        .

        hrm...guess I'll have to settle w/ my ol' 48 degree manual shadows 😞

        The other weird thing I've noticed is what your ruby does to the time settings in the shadow settings dialog box. Don't know if this is intentional or not. If you open the first skp file RV posted you'll see that it sets the time to go from 11:10am to 11:01pm. I'm not sure if it's always this range but it is always changed to a very odd range and as I recall this affects all other shadow settings. I'd have to go and verify but I think if you've already got a scene set up, say scene 1. and then you go into scene 2 and apply the ruby and go back to scene 1 the slider is in the same position but since the range changed what was, say 1pm, is now, say, 10pm.

        Let me know if any of that make sense or if you need me to go and verify all that stuff. Don't know if it'll help you.

        -Brodie

        steelblue http://www.steelbluellc.com

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

          The script has to (re)set the time (and where north is) to get the sun at the right place in the sky to cast the shadow at 45 degrees on the chosen elevation. If you have several pages (scenes) set up you should ensure that they are saved with the particualr location and date+time etc you desire. Make new page(s) for the 45 degree shadows and when it's done update that too...

          You should be able to have several pages each with different times/dates etc...

          TIG

          1 Reply Last reply Reply Quote 0
          • brodieB Offline
            brodie
            last edited by

            I took a quick crack at it. This file has 3 scenes. I created the first 2 w/ shadows on at different times of the day, then created the 3rd one using the ruby (which turned everything dark as it has been). Going back to my other scenes did indeed change the time range back to normal however everything was still dark, weird.

            -Brodie


            shadow test.skp

            steelblue http://www.steelbluellc.com

            1 Reply Last reply Reply Quote 0
            • brodieB Offline
              brodie
              last edited by

              TIG, could you post a skp file w/ a saved scene using your ruby so I can open it and see what happens?

              -Brodie

              steelblue http://www.steelbluellc.com

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

                Here's an example...

                A normal scene plus a north and west elevation with 45 shadows. Update each tab as the scene is made and each scene has a different north, date, time, location etc to get the shadows as needed...


                45test.skp

                TIG

                1 Reply Last reply Reply Quote 0
                • brodieB Offline
                  brodie
                  last edited by

                  Very interesting. Here's what I'm finding. Using your plugin does indeed change the location in terms of latitude and longitude. What it doesn't change is the name (still Boulder instead of Elevations 45 Shadows or whatever) or (here's the important part) the time zone. Time zone stays at -7 (Boulder's time zone) rather than switching to +0 (the time zone in the skp file you posted).

                  Starting a new drawing, using your script and then manually changing the time zone produced results identical to the results of your sketchup file.

                  HOWEVER, when I open your SU file the shadows aren't truely 45 degrees. Well, I take that back. They are 45 degrees, however the shadows aren't as long as I'd expect them. For example, if a block is protruding out 1 foot you'd expect the shadow to travel 45 degrees and to stop 1' down and 1' to the right. W/ your script it travels 45 degrees but not quite the full 1' down and 1' over. Check out the example below. On my screen the shadow stops just before the purple face. I'd expect it to travel to the far end of the purple face.

                  I think we're getting close here. On your screen does the shadow cover up the purple face in my example because on mine it doesn't.

                  -Brodie


                  45test 1.skp

                  steelblue http://www.steelbluellc.com

                  1 Reply Last reply Reply Quote 0
                  • brodieB Offline
                    brodie
                    last edited by

                    an image to reiterate what I'm saying


                    45test 1.jpg

                    steelblue http://www.steelbluellc.com

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

                      It always changes the location name for me...

                      Point taken about the 45 degree accuracy. I've fixed it to within a smidge of a mm... Needed minor adjustments to time of day and long/lat to get it 'as near as damn is to swearing'. The 'Boulder' Time Zone bit was from a typo that's corrected...

                      See updated script... http://www.sketchucation.com/forums/scf/viewtopic.php?p=98081#p98081

                      .

                      TIG

                      1 Reply Last reply Reply Quote 0
                      • brodieB Offline
                        brodie
                        last edited by

                        Bloody wonderful. Agreed, that is much closer. That did, indeed fix the location issue (doesn't still say Boulder, CO any more). I'm still having to manually change the time zone from -7 to +0 but I can certainly live w/ that! Thanks a ton, glad we finally figured this out.

                        Only thing I'd suggest is adding a caveat in the text of your script and maybe in that other post as well to folks, that if the screen goes dark after running the script to go to Window -> Model Info -> Location -> Custom Location button and change time zone to UTC-0

                        Thanks again!

                        -Brodie

                        steelblue http://www.steelbluellc.com

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

                          301 Moved Permanently

                          favicon

                          (www.sketchucation.com)

                          Here's v1.4 - it should fix the T Z Offset error ???

                          .

                          TIG

                          1 Reply Last reply Reply Quote 0
                          • brodieB Offline
                            brodie
                            last edited by

                            Wonderful! It works like a charm now. Thanks so much for fixing it!

                            -Brodie

                            steelblue http://www.steelbluellc.com

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

                              The new one is just perfect πŸ‘

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

                                Hooray !

                                TIG

                                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