Sha256: 29ecad1d2bed7e85d39e4d7db6686d5742f7c070567ec3882f5a672fae85c25b
Contents?: true
Size: 512 Bytes
Versions: 5
Compression:
Stored size: 512 Bytes
Contents
load_library :vecmath attr_reader :my_cube def setup size(600, 600, P3D) smooth(8) ArcBall.init(self) @my_cube = create_shape(BOX, 400, 400, 400) my_cube.set_fill(color(100, 10, 100)) end def draw background(50, 50, 100) define_lights lights stroke(0) shape(my_cube) end def define_lights ambient(20, 20, 20) ambient_light(50, 50, 50) point_light(30, 30, 30, 200, -150, 0) directional_light(0, 30, 50, 1, 0, 0) spot_light(30, 30, 30, 0, 40, 200, 0, -0.5, -0.5, PI / 2, 2) end
Version data entries
5 entries across 5 versions & 1 rubygems