def setup
createCanvas(100, 100, WEBGL)
end
def draw
background(205, 105, 94)
rotateZ(frameCount * 0.02)
rotateX(frameCount * 0.02)
cylinder(20, 50)
end
def setup
createCanvas(100, 100, WEBGL)
@detailX = createSlider(3, 24, 3)
@detailX.position(10, height + 5)
@detailX.style('width', '80px')
end
def draw
background(205, 105, 94)
rotateY(millis / 1000)
cylinder(20, 75, @detailX.value, 1)
end
def setup
createCanvas(100, 100, WEBGL)
@detailY = createSlider(1, 16, 1)
@detailY.position(10, height + 5)
@detailY.style('width', '80px')
end
def draw
background(205, 105, 94)
rotateY(millis / 1000)
cylinder(20, 75, 16, @detailY.value)
end