Index Algorithmic SketchesCAD/3DComputer GeometryDraw by ScriptingGeneral ToolsGraphOtherVisualisation +

Script sequencer WIP


A short video record of current internal test version (B20130404) https://vimeo.com/67574839 using a similar basic example as previous video https://vimeo.com/22764739. Many changes since previous video – from building it within a web dialog to external standalone executing ruby scripts to current implementation with standalone 3d class objects. In a way it’s no longer a script sequencer as I have now focus on building all functions internally without dependencies on existing software – while scripts can still be executed in them it no longer resolve the connections between nodes.

The main difficulty working with sketchup is that its API is currently very limited – ruby and C++ API for writing and reading skp only, meaning that most aspect of sketchup in run time is not exposed through its official C++. It would be interesting to see how LightUp work with the opengl window and how the vray plugin incorporates C++ and python into sketchup.

From my experience, its rather slow to perform geometrical operations (or any intense operation like cellular automata test in sketchup, having said that my implementation for transient drawing is quite slow at the moment) through a scripting API like ruby (or python in Maya) as I tried earlier before moving away from purely running script on destination software (pre 2012) . There are possibilities and potentials to extend ruby as C extensions (as some amazing advanced plugin developer already started this) to overcome the speed issues, but the environment setup and the debugging process is not that smooth as I last tried.

As an external software that executes functions internally, the primary bottleneck in current implementation is that it requires methods to communicate back and forth between sketchup and the nodegraph i.e. to acquire geometrical entities, drawing opengl transient geometry, to respond to callbacks from sketchup observers. This is currently implemented as server/client passing signals to execute scripts – this conversion of data between c++ and ruby works but in terms of speed the issue remains unresolved. As a comparison the equivalent in maya is easier as c++ objects can be passed to a separate process using shared memory.

June 2013