Sha256: 4166b56738a9a5025db451c3ccdcb2b1fa2a786ac1996bd5169dd0dbc0f6c68a
Contents?: true
Size: 410 Bytes
Versions: 6
Compression:
Stored size: 410 Bytes
Contents
# # Save One Image # # The save function allows you to save an image from the # display window. In this example, save is run when a mouse # button is pressed. The image 'line.tif' is saved to the # same folder as the sketch's program file. # def setup size(200, 200) end def draw background(204) line(0, 0, mouse_x, height) line(width, 0, 0, mouse_y) end def mouse_pressed save('line.tif') end
Version data entries
6 entries across 6 versions & 1 rubygems