paulguy
 Green Birdo
Level: 93
   

Posts: 527/2294
EXP: 8033460 For next: 19350
Since: 09-14-07
From: Buffalo, NY
Since last post: 9.7 years Last activity: 9.7 years
|
| Posted on 02-17-10 10:30:37 PM (last edited by paulguy at 02-19-10 08:56 PM) |
Link | Quote
| |
Paulguy's Post configuration
|
Gabu
 Star Mario Placeholder Ikachan until :effort: is found
Level: 172
   

Posts: 2443/9981
EXP: 68000048 For next: 102186
Since: 08-10-09
Pronouns: they/them, she/her
From: Santa Cruisin' USA
Since last post: 57 days Last activity: 5 days
|
|
Sweet! This looks like something that certain use where they put in small photos together to make one larger photo. Would especially look interesting in puzzles.
____________________
|
|  |
|
dirbaio
For future reference, "Responsible disclosure" isn't "acting like a douche about an exploit and demanding compensation".
Level: NaN
 
Posts: 415/-1288
EXP: NaN For next: 0
Since: 07-28-09
From: Spain
Since last post: 10.9 years Last activity: 9.9 years
|
| Posted on 02-19-10 05:18:52 PM (last edited by dirbaio at 02-19-10 02:22 PM) |
Link | Quote
| |
Nice piece of software...
I had to deal with exactly this same thing for NSMB Editor, for importing backgrounds...
What I did is to cut the whole image into 8x8 blocks, take the two most similar and "merge" them. When I merge them, the new block is the mean of the other two, taking into account how many blocks of each are on the image... It is very slow, probably because it's in C#, and i use the get/setPixel methods, which are known to be very slow.
My solution: http://code.google.com/p/nsmb-editor/source/browse/trunk/NSMBe4/ImageTiler.cs
An example image: http://img12.imageshack.us/img12/859/bgtiles.jpg. The one on the right is the compressed one, with only 320 8x8 tiles.
EDIT: That image took 15 min to be processed, on my 4-year-old laptop... |
paulguy
 Green Birdo
Level: 93
   

Posts: 533/2294
EXP: 8033460 For next: 19350
Since: 09-14-07
From: Buffalo, NY
Since last post: 9.7 years Last activity: 9.7 years
|
|
Paulguy's Post configuration
|
dirbaio
For future reference, "Responsible disclosure" isn't "acting like a douche about an exploit and demanding compensation".
Level: NaN
 
Posts: 416/-1288
EXP: NaN For next: 0
Since: 07-28-09
From: Spain
Since last post: 10.9 years Last activity: 9.9 years
|
|
oh, no!
You can improve it
I was getting results like that, or worse, before implementing the "merging" of blocks
It's a hard thing to implement properly. I spent more or less a week doing that, and it can still be improved (on output quality and on speed ) |
Hectamatatortron
Member
Level: 35
   
Posts: 201/232
EXP: 258252 For next: 21684
Since: 09-19-07
Since last post: 7.2 years Last activity: 5.3 years
|
| Posted on 02-20-10 11:49:54 PM (last edited by Hectamatatortron at 02-20-10 09:03 PM) |
Link | Quote
| |
I've written an image color and palette (but not tile) reducer that I use for creating images formatted appropriately for "Fire Emblem CGs".
The input/output combo in the first post is eerily similar in appearance to what might be seen with my utility, except my utility, while still having much trouble with tile boundaries, does not currently reduce the number of tiles (though I will need to add support for that later because of another image type in GBA Fire Emblem games), and therefore the output is less choppy around edges of things.
Here's the relevant post.
Edit: My application only works on images already sized the way the GBA screen is.
So let me just modify the original image to be 240x160 px, and I'll show an input/output pair for comparison.
| Before | After |
|---|
 |  |
____________________  |