Python script for generating gcode for simple 3D objects