Slow performance
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins
Re: Slow performance
by DennisBergkamp » 18 Feb 2010, 20:57
Hmm, I'm still not convinced, what was the old way of blurring/resizing ?
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Slow performance
by silly freak » 18 Feb 2010, 21:16
i think there was no blurring previously, but it looks really good. you can start a game and resize the picture panel to the 0.5 scale limit and compare with/-out blur. it really is a gain for small sizes. the configuration also seems very good
i think we just jeave it as it currently is until it makes problems
i think we just jeave it as it currently is until it makes problems
___
where's the "trust me, that will work!" switch for the compiler?
Laterna Magica - blog, forum, project, 2010/09/06 release!
where's the "trust me, that will work!" switch for the compiler?
Laterna Magica - blog, forum, project, 2010/09/06 release!
- silly freak
- DEVELOPER
- Posts: 598
- Joined: 26 Mar 2009, 07:18
- Location: Vienna, Austria
- Has thanked: 93 times
- Been thanked: 25 times
Re: Slow performance
by DennisBergkamp » 18 Feb 2010, 23:29
I see... but there's no way to do it the same way it was done originally?
It looked much better at first, I think. The small card images just looked completely smooth, now they're really jaggy. Or maybe this is just happening on my system?
It looked much better at first, I think. The small card images just looked completely smooth, now they're really jaggy. Or maybe this is just happening on my system?
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Slow performance
by silly freak » 18 Feb 2010, 23:57
do you have a screen? it shouldn't look as crappy as previously any more, and I can't confirm they're "really jaggy"
___
where's the "trust me, that will work!" switch for the compiler?
Laterna Magica - blog, forum, project, 2010/09/06 release!
where's the "trust me, that will work!" switch for the compiler?
Laterna Magica - blog, forum, project, 2010/09/06 release!
- silly freak
- DEVELOPER
- Posts: 598
- Joined: 26 Mar 2009, 07:18
- Location: Vienna, Austria
- Has thanked: 93 times
- Been thanked: 25 times
Re: Slow performance
by DennisBergkamp » 19 Feb 2010, 07:37
Actually, in ImageCache.java if you change the radius int parameter value that's passed into getBlurredImage from 3 to 6, things look awesome again
I just hope this won't cause too bad of a slowdown.
I just hope this won't cause too bad of a slowdown.
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Slow performance
by Huggybaby » 19 Feb 2010, 08:16
I don't know what kind of scaling algorithm you guys are using, but (if applicable) it's possible to provide the end user a selection from a variety of well known high speed varieties, and the code is readily available. See http://en.wikipedia.org/wiki/Pixel_art_ ... algorithms.
-
Huggybaby - Administrator
- Posts: 3207
- Joined: 15 Jan 2006, 19:44
- Location: Finally out of Atlanta
- Has thanked: 701 times
- Been thanked: 594 times
Re: Slow performance
by Snacko » 19 Feb 2010, 09:46
Those NxSai and Hqnx filters work good only for pixel art, like the one used in the snes games plus they are designed to enlarge only. Also they're quite slow and need quite a beefy computer (as in any core2).
Personally for me at radius 6 it looks like a blurred mess but each to his own.
Personally for me at radius 6 it looks like a blurred mess but each to his own.
Re: Slow performance
by DennisBergkamp » 19 Feb 2010, 18:08
Ok, I guess it's all personal preference then
Or perhaps it's system specific? On my computer 6 - 7 looks almost exactly the same it was the original way, using medium - large card sizes. 3 is just too jaggy (i'll post a screenshot).
I'll try to turn it into an menu option then ("blur radius"?), with values of something like 2 - 8.
Or perhaps it's system specific? On my computer 6 - 7 looks almost exactly the same it was the original way, using medium - large card sizes. 3 is just too jaggy (i'll post a screenshot).
I'll try to turn it into an menu option then ("blur radius"?), with values of something like 2 - 8.
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Slow performance
by DennisBergkamp » 19 Feb 2010, 20:47
Also, using LQ pics will definitely turn the small sized pics into a blurry mess when using a radius of 6.
HQ pics look jaggy though.
HQ pics look jaggy though.
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Slow performance
by Snacko » 19 Feb 2010, 21:23
Yes, I haven't thought about HQ pics.
It is true that as the size increases the blur radius needs to increase as well to preserve the same relative blurriness.
~3 looks good for LQ and you need ~6-7 for HQ as you said
edit:
I've been testing scaling with a external library which does Lanczos scaling and the results are even better. However I'm not sure you want to make dependency on another jar.
It is true that as the size increases the blur radius needs to increase as well to preserve the same relative blurriness.
~3 looks good for LQ and you need ~6-7 for HQ as you said
edit:
I've been testing scaling with a external library which does Lanczos scaling and the results are even better. However I'm not sure you want to make dependency on another jar.
-
Huggybaby - Administrator
- Posts: 3207
- Joined: 15 Jan 2006, 19:44
- Location: Finally out of Atlanta
- Has thanked: 701 times
- Been thanked: 594 times
Re: Slow performance
by DennisBergkamp » 19 Feb 2010, 23:03
How big is the Jar?
If it looks even better, it is probably worth it
If it looks even better, it is probably worth it
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Slow performance
by Snacko » 20 Feb 2010, 14:05
It's like 40kB. I've also used a maven build of google collections which is a single jar, that's why I've removed jsr jar.
Re: Slow performance
by DennisBergkamp » 20 Feb 2010, 19:15
Very cool, Lanczos3 looks beautiful (also for HQ images scaling)
Definitely worth the 40kb in my opinion.
Definitely worth the 40kb in my opinion.
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Slow performance
by DennisBergkamp » 20 Feb 2010, 19:27
Hmm, except, for some reason tapped images don't show anymore?
And performance seems pretty slow
And performance seems pretty slow
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
42 posts
• Page 2 of 3 • 1, 2, 3
Who is online
Users browsing this forum: No registered users and 97 guests