pixelated graphics on Monkey sland 3 and Broken Swords

Subforum for discussion and help with ScummVM's iPhone port

Moderator: ScummVM Team

jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

pixelated graphics on Monkey sland 3 and Broken Swords

Post by jamesson »

I have a problem in the graphics of Monkey sland 3 and Broken Sword 1. They have the image distorted and twisted legends. It is impossible to read the subtitles and the picture is ugly .. this problem is only in these two games. the others tested are perfect.

Not tested on Windows ScummVM. only in Iphone.

have any version of those two games that run well? or any provision for a new version that fixes this?

I'm using the latest version: 1.1.148890
User avatar
Vinterstum
ScummVM Developer
Posts: 580
Joined: Sun Oct 16, 2005 6:59 am

Post by Vinterstum »

Can you take a screenshot to show what you mean? (I.e. push both the home button and the power button down at the same time).

EDIT: The games are scaled down to fit the iPhone screen, not sure if that's what you mean by "distorted".
jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

Post by jamesson »

Ok
Image

Image
Last edited by jamesson on Tue Jul 27, 2010 2:39 pm, edited 1 time in total.
jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

Post by jamesson »

Vinterstum wrote:Can you take a screenshot to show what you mean? (I.e. push both the home button and the power button down at the same time).

EDIT: The games are scaled down to fit the iPhone screen, not sure if that's what you mean by "distorted".
probably.. rss
we improve it?
User avatar
Vinterstum
ScummVM Developer
Posts: 580
Joined: Sun Oct 16, 2005 6:59 am

Post by Vinterstum »

jamesson wrote:
Vinterstum wrote:Can you take a screenshot to show what you mean? (I.e. push both the home button and the power button down at the same time).

EDIT: The games are scaled down to fit the iPhone screen, not sure if that's what you mean by "distorted".
probably.. rss
we improve it?
Not sure how, to be honest. The aspect ratio is already preserved, the only thing left to do would be to apply some algorithm that can downscale an image better than OpenGL ES can. And that'd likely be too computationally heavy for the iPhone (not that I've looked into it much).

EDIT: Alternate solution: Get an iPhone 4, its screen is high res enough to avoid downscaling :P.
jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

Post by jamesson »

Iphone 4 would be the solution to all problems .. :?
but I will not change my 3GS now .. it is new yet. . :lol:

This problem also occurs in the NDS, or PSP?
The 3GS has almost the same power of the PSP and is more potent than the NDS ..
ScummVM for the iPhone could have an option to activate a filter of scale that would only work in 3G Iphone or 4, not the old model economies. or it could put a message saying "only recommended for 3GS or newer"

But anyway, you did an excellent job in ScummVM for iPhone.
I discovered it this week! Congratulations"
Last edited by jamesson on Tue Jul 27, 2010 5:18 pm, edited 1 time in total.
jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

Post by jamesson »

Iphone 4 would be the solution to all problems ..
but I will not change my 3GS now .. it is new yet. . :lol:

This problem also occurs in the NDS, or PSP?
The 3GS has almost the same power of the PSP and is more potent than the NDS ..
ScummVM for the iPhone could have an option to activate a filter of scale that would only work in 3GS Iphone or 4, not the old model economies. or it could put a message saying "only recommended for 3GS or newer!

But anyway, you did an excellent job in ScummVM for iPhone.
I discovered it this week! Congratulations!
Last edited by jamesson on Tue Jul 27, 2010 5:18 pm, edited 1 time in total.
fingolfin
Retired
Posts: 1452
Joined: Wed Sep 21, 2005 4:12 pm

Post by fingolfin »

COMI and other large screen games does not work on the NDS at all.

The screen of your phone is too small. We have to shrink the graphics. It will never look great, no matter what. Though I admit those screen shots look really bad, not like the bilinear filtering I would expect from OpenGL...
jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

Post by jamesson »

so that's it .. I think it's impossible ...
Thanks for the answer! and keep up the excellent work!
User avatar
Vinterstum
ScummVM Developer
Posts: 580
Joined: Sun Oct 16, 2005 6:59 am

Post by Vinterstum »

fingolfin wrote:COMI and other large screen games does not work on the NDS at all.

The screen of your phone is too small. We have to shrink the graphics. It will never look great, no matter what. Though I admit those screen shots look really bad, not like the bilinear filtering I would expect from OpenGL...
GL_TEXTURE_MAG_FILTER isn't explicitly set, but the default is GL_LINEAR, so it should definitely be using bilinear.
jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

Post by jamesson »

another question: in ScummVM for Android, the games with high-resolution work better than the iPhone? because I can install Android on iPhone
Bluddy
ScummVM Developer
Posts: 145
Joined: Sun Nov 18, 2007 8:43 am

Post by Bluddy »

You do get a little bit of this effect on the PSP, but in general it looks much better.

My guess is that because you're trying to preserve the aspect ratio, you end up reducing the usable screen real estate too much, causing heavy downsampling. My advice to the iphone porter is to forget the aspect ratio for the high resolution games -- use every inch of screen real estate you have. A little bit of stretching will not be noticeable, and will probably make the game look much better.
fingolfin
Retired
Posts: 1452
Joined: Wed Sep 21, 2005 4:12 pm

Post by fingolfin »

For reference I made a screenshot of COMI on my Mac, then used Photoshop to downscale it to 427x320, once using a bilinear filter, once using a cubic one. The result IMO is pretty readable and looks good, much better than those iPhone screenshots.

So I still wonder what scaling the iPhone port does there -- it certainly doesn't look like bilinear. More as if some pixel columns are being skipped completely. Hm, or as if bilinear scaling was done on a 256 color surface, not on a 16/32bit surface. Here are my shots:

Bilinear:
Image

Cubic:
Image
jamesson
Posts: 15
Joined: Tue Jul 27, 2010 1:07 pm

Post by jamesson »

The Cubic got better. But if the iPhone remain as the bilinear shown by you, would be great
Bluddy
ScummVM Developer
Posts: 145
Joined: Sun Nov 18, 2007 8:43 am

Post by Bluddy »

The problem is here

iphone_video.m:
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST);

It needs to be changed to GL_LINEAR
Post Reply