sketchup

ruby gems in Google-Sketchup

孤人 提交于 2019-12-11 11:00:54
问题 How do I use ruby gems in google-sketchup? Whenever I try typing: > require 'rubygems' into the ruby console, I get the following: Error: #<LoadError: (eval):7:in `require': no such file to load -- rubygems> EDIT I am on OSX. 回答1: sorry this is not an answer, i just thought i could shed some more light... (i dont have enough rep points to comment yet) typing RUBY_VERSION in the SketchUp Ruby Console returns 1.8.5? i have several ruby versions on my mac but certainly not 1.8.5. using sketchup

Parsing text in Ruby

馋奶兔 提交于 2019-12-09 22:40:09
问题 I'm working on a script for importing component information for SketchUp. A very helpful individual on their help page, assisted me in creating one that works on an "edited" line by line text file. Now I'm ready to take it to the next level - importing directly from the original file created by FreePCB. The portion of the file I wish to use is below: "sample_1.txt" [parts] part: C1 ref_text: 1270000 127000 0 -7620000 1270000 1 package: "CAP-AX-10X18-7X" value: "4.7pF" 1270000 127000 0 1270000

STL rendering with threejs

喜你入骨 提交于 2019-12-08 10:52:04
问题 I have created a 3D model for printing in 3D an industrial layout. Because I am not used in playing with professional 3D modeler software, I used SketchUp and the result was fine ! Now, I want to reuse the 3D models to make a dynamic visit of the "to-be" installation. I exported each object in Collada format (DAE), and then try to used the collada importer in Threejs. I have around 130 objects that I want to be able to select interactively, but I manage only to load one ... I then get a try

Punching a hole through a cylinder using Sketchup Ruby API

一世执手 提交于 2019-12-07 22:44:57
问题 I'm writing a script to make a simple flute in SketchUp (free version, Mac). I want to make a tube and and then cylinders which poke through the tube, draw the intersection lines between the tube and the cylinders, then erase the cylinders, leaving circles to cut out of the tube. This works if I do it with the mouse, but I found it difficult to be precise about placement and measurement with the mouse. So far, though, I haven't been able to make it work with a script. Currently I am stuck

Parsing text in Ruby

自作多情 提交于 2019-12-04 15:28:17
I'm working on a script for importing component information for SketchUp. A very helpful individual on their help page, assisted me in creating one that works on an "edited" line by line text file. Now I'm ready to take it to the next level - importing directly from the original file created by FreePCB. The portion of the file I wish to use is below: "sample_1.txt" [parts] part: C1 ref_text: 1270000 127000 0 -7620000 1270000 1 package: "CAP-AX-10X18-7X" value: "4.7pF" 1270000 127000 0 1270000 1270000 1 shape: "CAP-AX-10X18-7" pos: 10160000 10160000 0 0 0 part: IC1 ref_text: 1270000 177800 270

Importing Google Sketchup models in Mathematica

江枫思渺然 提交于 2019-12-04 09:01:31
问题 Google's Sketchup is a nice, simple 3D-object modeler. Moreover Google has an enormous warehouse of 3D objects so that you actually don't have to do much modeling yourself if you aren't particularly gifted in this area. Many of the 3D buildings in Google Earth are made with Sketchup. The capability to import Sketchup's SKP files in Mathematica would be very nice, but alas, it doesn't do that yet. The free version of Sketchup doesn't export to any other formats than the KMZ (Google Earth) and

Is there a command line in Google Sketchup to export in 3ds or fbx format?

久未见 提交于 2019-12-03 10:14:44
问题 I am looking for a way to convert several skp, kmz or dae files at once into 3ds or fbx format. In sketchup pro you can do export as...3ds or fbx but that would take too long to open each file and export it. Is there a command line in sketchup, or a script that could be used to perhaps automate this process? Thanks 回答1: you need to invoke sketchup from the command-line specifying a script to run immediately sketchup.exe -RubyStartup d:\scripts\runexport.rb in your ruby script ( runexport.rb )

Embed 3D models on website

点点圈 提交于 2019-12-03 08:27:52
问题 Is there a way to embed Sketchup models on a website? Preferably a free one, if it's a commercial solution I'd like a confirmation that it's actually worth the money... I know about the 3D warehouse thingy where you can rotate it (javascript and some images), but I can't upload anything to the 3D warehouse 'cause it always "resets the connection". 回答1: You can try the upcoming WebGL Functions in modern Browsers. There are some Javascript Libraries that can read model files and show them

Importing Google Sketchup models in Mathematica

馋奶兔 提交于 2019-12-03 01:42:47
Google's Sketchup is a nice, simple 3D-object modeler. Moreover Google has an enormous warehouse of 3D objects so that you actually don't have to do much modeling yourself if you aren't particularly gifted in this area. Many of the 3D buildings in Google Earth are made with Sketchup. The capability to import Sketchup's SKP files in Mathematica would be very nice, but alas, it doesn't do that yet. The free version of Sketchup doesn't export to any other formats than the KMZ (Google Earth) and DAE (Collada) formats. Though MMA can read KMZ/KML files it doesn't read those containing 3D objects.

Is there a command line in Google Sketchup to export in 3ds or fbx format?

守給你的承諾、 提交于 2019-12-03 00:44:50
I am looking for a way to convert several skp, kmz or dae files at once into 3ds or fbx format. In sketchup pro you can do export as...3ds or fbx but that would take too long to open each file and export it. Is there a command line in sketchup, or a script that could be used to perhaps automate this process? Thanks you need to invoke sketchup from the command-line specifying a script to run immediately sketchup.exe -RubyStartup d:\scripts\runexport.rb in your ruby script ( runexport.rb ) you can load your model. See http://code.google.com/apis/sketchup/docs/ourdoc/model.html#import export your