Trying to run through directory, and re-texture a surface. Eventually want to Render w/ Ruby script

Yes, It should be, as I said it likely a sync issue. You have two options, to change the texture of the material gloabally, or change the material of specific faces. The first is likely to be easier, especially if you know the name of the material in the materials collection.

The trick is to wait long enough for SketchUp to update the view, before writing the image, and then to wait again while the image is being processed for the file write (before changing the material’s texture for the next “frame”.)

I just thought of another idea. There is an abstract Animation class that might help in the sync’ing department. Ie, although it’s common, it is not absolutely necessary to change the camera position in a nextFrame() callback method.

Ruby is multi-paradigm. Don’t sweat it.

See my Ruby learning wiki thread:
Ruby Learning Resources [WikiLists]

1 Like