diff options
| author | Tom Black <[email protected]> | 2021-04-26 19:33:08 -0500 |
|---|---|---|
| committer | Tom Black <[email protected]> | 2021-04-26 19:33:08 -0500 |
| commit | 2f194a30ff9d6cdf281d35c3b7b93182436650d2 (patch) | |
| tree | 793669c629a2222b01f6e11e8670448f7eba9c51 /test/render.rb | |
| parent | 426f677cb4c1543c62f0a1eafba34777c6525646 (diff) | |
| download | ruby2d-direct-draw.tar.gz ruby2d-direct-draw.zip | |
Direct draw imagesdirect-draw
Diffstat (limited to 'test/render.rb')
| -rw-r--r-- | test/render.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/render.rb b/test/render.rb index 47667f0..c9ec808 100644 --- a/test/render.rb +++ b/test/render.rb @@ -1,15 +1,12 @@ require 'ruby2d' -# set width: 1280, height: 770 - - Quad.new(x3: 125, x4: 25) Rectangle.new(y: 125) Square.new(y: 250) Line.new(x1: 5, y1: 375, x2: 95, y2: 475, width: 5) Triangle.new(x1: 325, y1: 0, x2: 375, y2: 100, x3: 275, y3: 100) Circle.new(x: 400, y: 175) - +img = Image.new('media/image.png', x: 250, y: 250) render do @@ -72,6 +69,9 @@ render do color: [0.8, 0.3, 0.7, 0.8] ) + img.draw(x: 375, y: 250) + img.draw(x: 500, y: 250, width: 90, height: 110, rotate: 10, color: [0.8, 0.5, 0.4, 0.7]) + end show |
