sketchucation logo sketchucation
    • Login
    1. Home
    2. todd burch
    3. Posts
    πŸ›£οΈ Road Profile Builder | Generate roads, curbs and pavements easily Download
    T
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 55
    • Posts 903
    • Groups 1

    Posts

    Recent Best Controversial
    • RE: Tool Cabinet in Progress

      Hi Chris.

      There are a few kinks I want to work out. I don't know if you saw the thread I started about component axis, but that's a big annoyance right now (no standard for which axis is width, length or thickness, even for the people that pay attention to them). However, dims can pretty much be inferred for woodworking projects, plus, dhtml code can be provided with widgets to allow the viewer to swap values if inferences don't work.

      And, as you pointed out, materials are missing. (And, depending on how the modeler paid attention to applying materials, dims can be worked out via the material - I still need to figure that one out.)

      And, I'll add the ability to click on a thumbnail and show a larger (user chosen size) image. And, there are a few more bells and whistles that would be nice too, like a materials list for lumber and sheet goods, plus a way to categorize non-wood stuff like hardware and glass.

      I'm finding the smarter it is made, the more it requires the user to be a partner in the drawing process so both can "agree" on how the model is defined (via names, attributes, axis, materials, etc.)

      I don't mean to highjack this thread, so that's all I'll say here. If you want to start a new thread, let me know.

      Todd

      posted in Woodworking
      T
      todd burch
    • RE: Ruby Console.... what's up with all the <br/>s?

      @thomthom said:

      Maybe you're gotten a plugin being naughty and editing base methods...

      Not a chance!! No way, no how - not on this machine.

      posted in Developers' Forum
      T
      todd burch
    • RE: Ruby Console.... what's up with all the <br/>s?

      I figured it out, and it's a SU bug. When you have a 0x0a in your string, and you puts that string to the console, you'll get a <br/> instead of a newline.

      At least that's how it working (er, not working?) on my Mac.

      Todd

      posted in Developers' Forum
      T
      todd burch
    • RE: Tool Cabinet in Progress

      Looks good. Pretty fancy tool cabinet. White oak?

      I made you a present. See attached. Extract it into a folder and open the cutlist.html file.

      It's the output of a little project I'm working on. You'll notice the dimensions in the various columns are somewhat random.

      Todd


      cutlist.zip

      posted in Woodworking
      T
      todd burch
    • RE: Connect lines

      There's an app for that.

      To mark the location of all the open line segments, use this script:
      http://www.smustard.com/script/StrayLines

      To make faces once you close all the open line segments, use this script:
      http://www.smustard.com/script/MakeFaces
      (and don't forget http://www.smustard.com/script/ProgressBar)

      To quickly connect all the open line segments, you have two choices of scripts:
      http://www.smustard.com/script/CloseOpens
      http://www.smustard.com/script/ExtendCloseLines

      posted in Developers' Forum
      T
      todd burch
    • Ruby Console.... what's up with all the &lt;br/&gt;s?

      This is quite annoying. Since when did the Ruby console take it upon itself to inject <br/> tags in my output?

      Is this what all the fuss is about with the alternative Ruby Consoles?

      Todd

      posted in Developers' Forum
      T
      todd burch
    • RE: SU Ruby + XML

      I write an xml file in ruby, pass it to my webdialog, and use the browser to parse the xml and generate my html table dynamically.

      Works awesome.

      posted in Developers' Forum
      T
      todd burch
    • RE: Mac Help Needed

      The default working directory for Ruby inside Sketchup is root.

      You could start with ENV['HOME'] to get to a more reasonable choice for user files.

      posted in Developers' Forum
      T
      todd burch
    • RE: WebDialog set_file

      It appears your html file is two folders higher in the hierarchy than /plugins.

      How smart do you think find_support_file (or set_file) is?

      posted in Developers' Forum
      T
      todd burch
    • RE: Updated Woodworking Bench

      Interesting. Here, SYP is pretty cheap, but fir will cost you and arm and a leg - way too expensive for a workbench. While fir is a nice strong and stable wood, it's kinda soft.

      I have a workbench I got some time ago from a retiring friend, no so-so different from what you will be making. However, the top is face-to-face laminated maple, but the base is made of fir in the same style you are making. It's not super rigid due to its construction style (or, should I say, the execution of the construction), but if I bolted it to the shop wall, it would be fine.

      Post pictures as you make it!

      posted in Woodworking
      T
      todd burch
    • RE: Do you pay attention to the Component Axis?

      Sorry Wo3Dan - left you out. πŸ˜‰

      I agree - blue would be height, and red and green can be swapped for the other two dimensions.

      If length doesn't make sense to you for height (which it does to me), and you put width for green, the you put red for length, which could also be called depth. Right?

      length=height has made sense to me, because width = width, and thickness = depth. But, I am not 6 feet long, I am 6 feet high. My foot is 12 inches long and 3 inches wide, and is probably 2 inches thick from top to sole. But the ocean has a great depth.

      Oh geeze.

      Someone tell me what to use.

      posted in SketchUp Discussions
      T
      todd burch
    • RE: Do you pay attention to the Component Axis?

      Here's the default returned information from how we get dimensions for a component. (its bounding box)

      SketchUp001.jpg

      I see that Sketchup uses the Y axis to infer height, (in this case it is the component's thickness, but that is arbitrary), the X axis to imply width, and the Z axis for depth. That goes against my logic, where Z ("up" towards the sky) would be height, while Y, which is "deeper" (further away) in the standard view, from the viewer, should be depth. Width, as it is implied in bounds.width, makes sense.

      I guess what I am hearing is that I have depth and height backwards, and I should be using (because most people do this?) the Y axis reading (bounds.height) to get "length".

      Now, for clarification... Thomas, dale and TIG all use:

      • red for width (which is bounds.width)

      • green for depth (which is bounds.height)

      • blue for height (which is bounds.depth)
        And Sketchup returns

      • red for width

      • green for height

      • blue for depth
        And I have used

      • red for width

      • green for depth (thickness)

      • blue for height (length)

      And Thomas and dale TIG pay strict attention to Z for length or height measurements (which is bounds.depth).

      And then Mike does green for length and red for depth. I guess width is blue (aka, UP?)

      I'm starting to think that Sketchup screwed up the naming of the bounds.height and bound.depth and got them backwards.

      I guess I'm getting (I've been? I am?) confused (can't imagine why) by the terms width, depth, length, height and thickness.

      In my book, height has always been a measure of unit from the ground (x/y plane) to the sky (up Z).

      Now... (thinking and pondering...), perhaps this is the reasoning for the terms. On a 2D cartesian coordinate graph, Y is height, so perhaps it's a carryover into 3D, and it would also make sense to name the measure "depth" to represent the distance from the viewer to the 2D graph, and beyond. So this could possibly explain Sketchup's method names then.

      So my stupid question of the week would be... if the depth, width and height terms are indeed a carryover from 2D into 3D, why in tarnation isn't the sky at the top of the Y axis and why isn't the blue axis pointing at my chest when I open SketchUp?

      I'm so confused.

      posted in SketchUp Discussions
      T
      todd burch
    • Do you pay attention to the Component Axis?

      I'm working on a plugin for wood-related stuff that will be aware of a component's length, width thickness. This translates into x, y and z axis values, or red, green and blue if that's your preferred terminology.

      What I've surmised is that there does not seem to be a standard for what axis is width, depth (thickness) or height (length) axis settings. For my drawings, I have settled on x (red) being width, y (green) being thickness, and z (blue) being length. When the component axis are set this way, my plugin works wonders.

      I have also been asked to infer a wood component's length based on an applied material (aka, wood grain). This can be done, but I have not tackled that yet.

      So my questions are

      • Do you pay attention to the component axis when drawing assemblies of components?
      • What axis do you use for length, width and depth?
      • Is there a standard I'm not aware of?
      • Would it be reasonable for a plugin to assume the shortest dimension is the thickness of the component, and the longest dimension to be the length?
        Thanks, Todd
      posted in SketchUp Discussions sketchup
      T
      todd burch
    • RE: Updated Woodworking Bench

      Looks good. What flavor materials?

      posted in Woodworking
      T
      todd burch
    • RE: End of an Era

      I really enjoyed watching Norm. My family would hurry home from church on Sundays (pre DVR's, but we would record on VHS tapes when needed) to see Norm. My son and I would recite together, with Norm, word-for-word, the "Safetly Glasses" spiel.

      He did inspire me when I was learning woodworking. It was him, books and magazines.

      He certainly sold a lot of tools along the way. I've nothing bad to say about him today (I mean, right now, while I'm writing this post, after 2 glasses of wine).

      posted in Woodworking
      T
      todd burch
    • RE: [CODE] Camera settings

      It can be that easy. It depends on where and how you are saving the information, and how much info you want to save.

      If you browse the methods for the Camera class, there are a few others that can be saved as well, such as fov, perspective and aspect_ratio.

      For positioning the camera, all you need is camera.eye and camera.target and camera.up. The other info is camera settings.

      posted in Developers' Forum
      T
      todd burch
    • RE: [CODE] Camera settings

      Do you mean like

      
      eye = Sketchup.active_model.active_view.camera.eye
      target = Sketchup.active_model.active_view.camera.target 
      up = Sketchup.active_model.active_view.camera.up 
       
      # flip the camera upside down 
      up.reverse! 
      
      Sketchup.active_model.active_view.camera.set(eye, target, up) 
      
      

      ?

      posted in Developers' Forum
      T
      todd burch
    • RE: Bug - WebDialogs are caching and not refreshing images

      @dan rathbun said:

      I don't think it's an SU bug, it's probably a browser cache quirk.

      I'll agree to call it "behavior" until we get (if ever) a control to influence what the embedded browser is doing and as long as the hack works.

      @dan rathbun said:

      I wonder if the image table was enclosed inside a FORM block, would the Js method %(#BF00BF)[form.reset] cause the images to refresh?

      Good idea. Try it and let us know.

      posted in Developers' Forum
      T
      todd burch
    • RE: Bug - WebDialogs are caching and not refreshing images

      Thanks Thomas - but the meta tag didn't work. I'm on a Mac - I have not started porting to Windows yet.

      On a Mac, you reload a (non-WebDialog) web page via CMD+R. However, in a WebDialog, CMD+R activates the PAN tool in SU.

      I had already stated that if a new file name was used, the new image would load, but I wasn't really interested in creating a new unique name each time, as the user's disk could get cluttered with obsolete thumbnails. (Are they mine to delete? Are they not? - I didn't want to go there.)

      TBD had a suggestion to just delete the files when the WebDialog closed, and this might be a good solution too, but I found a trivial/benign solution over on StackOverflow that does the trick (aka, WORKAROUND). Here's the trick.

      On the <img src='filename.png'> tag, by adding a random value after the filename, as you would do with a query string, forces the browser to reload the image. So, instead of 'filename.png', I use 'filename.png?123456789', where '123456789' (or whatever) gets appended and it is generated by the Javascript var seconds = new Date().getTime() ; function call.

      Thanks - your first post keyed me into searching further for how to cause the browser to not cache images and I didn't even notice your second post - and what I found was exactly what you suggested!.

      Todd

      (edit - adjusted some comments )

      posted in Developers' Forum
      T
      todd burch
    • Bug - WebDialogs are caching and not refreshing images

      (Perhaps a known bug, but the first time I've hit it. Running SU Pro 7.1.5803 )

      Loading several SU thumbnails (.png files) into an HTML table via the <img...> tag, SU refuses to load new or changed images once a file of a given name is used in a web dialog. You have to quit SU completely, not just close the model and reopen it (on a Mac), in order to obtain an updated copy of the image. Seems to me the browser used inside SU for the purposes of web dialogs has a pit bull hold on images in the image cache.

      At first I thought SU was not updating the image for a component.definition.save_thumbnail or a refresh_thumbnail, but that all seems to be working fine, as the video shows.

      I've attached a video demo of the bug.


      Video Demo of WebDialog Image Caching Bug

      posted in Developers' Forum
      T
      todd burch
    • 1 / 1