Two styles from one ruby
-
I am looking for some advice about the following:
I want to offer a 3D sketchup display (e.g. for exploring) and a 2D sketch for compiling instructions (e.g. to position components in a model or products on site), something like this:
I made a template set with top view and parallel projection and a callback which works apart from the style part:
@dlg.add_action_callback("topper") {|d, p| model = Sketchup.active_model view = model.active_view newview= view.zoom_extents subDir = "Styles/spdesign_scf/" fileName = "Sharp_3h_pencil.style" stylePath = Sketchup.find_support_file fileName, subDir status = model.styles.add_style stylePath true subDir= "D;\\Nameset1\\Thumbnails\\" thumbName = "Thumb.jpg" status = view.write_image subDir+thumbName status = styles.add_style stylePath false Sketchup.send_action("viewIso;") Sketchup.send_action("viewPerspective;") Sketchup.send_action("viewZoomExtents;") }
I would not only like to make it work, but also to improve the jpg in the webdialog.
Any help gratefully received!
Chris
Advertisement