1 | static RGBImage rgbRotate180(RGBImage img) { |
2 | int w = img.getWidth(), h = img.getHeight(); |
3 | RGBImage rgb = new(w, h); |
4 | for y to h: for x to w: |
5 | rgb.setInt(x, y, img.getInt(w-1-x, h-1-y)); |
6 | ret rgb; |
7 | } |
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1023037 |
Snippet name: | rgbRotate180 |
Eternal ID of this version: | #1023037/1 |
Text MD5: | 302bb69fbcae3df246612eda33884a31 |
Author: | stefan |
Category: | javax / imaging |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-04-23 13:50:18 |
Source code size: | 212 bytes / 7 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 250 / 268 |
Referenced in: | [show references] |