sketchucation logo sketchucation
    • Login
    Oops, your profile's looking a bit empty! To help us tailor your experience, please fill in key details like your SketchUp version, skill level, operating system, and more. Update and save your info on your profile page today!
    🛣️ Road Profile Builder | Generate roads, curbs and pavements easily Download

    Two styles from one ruby

    Scheduled Pinned Locked Moved Developers' Forum
    1 Posts 1 Posters 696 Views 1 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.
    • chrisglasierC Offline
      chrisglasier
      last edited by

      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:

      Sketchup nameset - step 4E.jpg

      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

      With TBA interfaces we can analyse what is to be achieved so that IT can help with automation to achieve it.

      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