1 | w, h = img.width, img.height |
2 | pixels = {}
|
3 | for y = 0, h-1 do |
4 | for x = 0, w-1 do |
5 | pixels[y*w+x+1] = img.getInt(w-1-x, h-1-y) |
6 | end |
7 | end |
Same script as #311, just different type
test run test run with input download show line numbers
Travelled to 12 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #492 |
| Snippet name: | Rotate 180° (image transformer) |
| Eternal ID of this version: | #492/1 |
| Text MD5: | f7a7ce0e13428c071d9314bf1c3d4ead |
| Author: | stefan |
| Category: | |
| Type: | Lua code - Image transformer |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2015-03-08 17:55:12 |
| Source code size: | 141 bytes / 7 lines |
| Pitched / IR pitched: | No / Yes |
| Views / Downloads: | 1013 / 230 |
| Referenced in: | [show references] |