*Sub-Thread* Dithering in GTA4

It's almost like we're seeing some undersampled, jittered image sampling in a post-process. Again, does anyone see this in motion in areas that aren't shadowed?
Quaz51 has said it's shimmering in motion. I've asked Dot50Cal for some screenies of these artefacted surfaces at different distances, though he may be too busy. It's be good to pin down if the noise is introduced at mip-map levels, viewing angles, and any other triggers.

Is it DMC with the same artefacts? What are the render modes of these games, do we know? The developers are completely independent, and whatever's causing it hasn't manifest itself on PS3, so it must be something to do with the hardware. Perhaps a rounding error on some samples? I really don't know, but I can't think of a software cause. Unless the developers have access to the individual MSAA samples for post-processing, which they do, don't they. So it could be a bug in code that's using the MSAA samples in post. :???:
 
Quaz51 has said it's shimmering in motion. I've asked Dot50Cal for some screenies of these artefacted surfaces at different distances, though he may be too busy. It's be good to pin down if the noise is introduced at mip-map levels, viewing angles, and any other triggers.
That would definately help, especially a shot of when you're really close to the sign.

Is it DMC with the same artefacts? What are the render modes of these games, do we know? The developers are completely independent, and whatever's causing it has manifest itself on PS3, so it must be something to do with the hardware.
Did you mean it hasn't manifested itself on PS3? I'd like to see this other game with similar artifacts.

Perhaps a rounding error on some samples? I really don't know, but I can't think of a software cause. Unless the devlopers have access to the individual MSAA samples for post-processing, which they do, don't they. So it could be a bug in code that's using the MSAA samples in post. :???:
The thing is that for non-edge pixels, MSAA assigns the same value to all subsamples, except if you have alpha-to-coverage enabled (which they shouldn't here).

The hardest thing to figure out is why it happens in some places but not others.
 
Did you mean it hasn't manifested itself on PS3? I'd like to see this other game with similar artifacts.
Yeah, typo :oops:

The thing is that for non-edge pixels, MSAA assigns the same value to all subsamples, except if you have alpha-to-coverage enabled (which they shouldn't here).

The hardest thing to figure out is why it happens in some places but not others.
Exactly. If it was just on the textures I'd think it was a texture sampling thing. But then it happens on a few edges too. If you look at the green and pink neons where AA isn't apparent, presumably because of HDR, generally the edge is well defined, but then suddenly there are displaced pixels, or a few faded pixels floating off from the edge where, with a little rearrangement, they'd be AA samples. It's like two pixels are being swapped. But the major culprit is on the textures, and only some of them.

This is the best technical mystery we've had in yonks!
 
On my old and new PJ the PS3 version is way to dark, or at least it seems that way. Using the ingame contrast/brightness and basicly turning them way up helps. I wish Rockstar would have included an actual Test pattern instead of the almost usless ingame example. You have to find something you know for certain is black and some shadow and some very bright stuff. And then you can try and dial it in.
 
Exactly. If it was just on the textures I'd think it was a texture sampling thing. But then it happens on a few edges too. If you look at the green and pink neons where AA isn't apparent, presumably because of HDR, generally the edge is well defined, but then suddenly there are displaced pixels, or a few faded pixels floating off from the edge where, with a little rearrangement, they'd be AA samples. It's like two pixels are being swapped. But the major culprit is on the textures, and only some of them.
Even when it happens on edges, it can easily be a texture sampling thing on the post process, and I'm leaning in this direction for several reasons. The source textures can't be messed up (via compression issues or otherwise) because then when you zoom in the dither would be expanded too. MSAA can't be an issue because we see problems where the MSAA samples are identical (non-edge pixels). All theories have to account for differences with PS3 and 360, though GTA4 clearly has a fair number of differences in display code.

This is the best technical mystery we've had in yonks!
Indeed... :???:
 
On my old and new PJ the PS3 version is way to dark, or at least it seems that way. Using the ingame contrast/brightness and basicly turning them way up helps. I wish Rockstar would have included an actual Test pattern instead of the almost usless ingame example. You have to find something you know for certain is black and some shadow and some very bright stuff. And then you can try and dial it in.
is your projector DVI or HDMI? if its dvi, you may want to try setting RGB to full if you haven't already. if its HDMI, you may want to try the opposite. reason being, if its DVI, it may be expecting a PC colorspace, therefore, setting it to limited might be clipping black detail. and if its HDMI, the opposite would be the case.
 
Personally I think it's a design choice it lies in a few different things :

1. Shadow mapping. The 'dithering' effect people have seen on the shadows in this game remind me of the way the shadow maps are dithered in GRAW1 and 2. I think they're filtering these shadow maps because otherwise you get a 'texelly' or 'pixelly' artifact. The way the 360 and PS3 do shadow mapping is different, I don't know how, but the difference is visible in games. The Infinity Ward developers said they liked the PS3's shadow mapping effect better too.

2. Fill Rate. There has been a effect that LOOKS like dithering in many 360 games, and I've had some people tell me it was a way of reducing fill rate costs on the 360. I know it's present in Burnout Paradise (look at trees, direct feeded and zoomed), and early Battlefield Bad Company screens showed it too.

Now when you get those two things together, both that look like 'dithering' maybe Rockstar decided to implement the 'look' to everything on the 360 version? I can't be sure, but this is just what I'm thinking.

[edit : one more note, take a look at the DOF effect in Switchball on XBLA, once the DOF kicks in you get a 'dithering' like effect there too, this may also factor into the overall design decision...]
 
1. Shadow mapping. The 'dithering' effect people have seen on the shadows in this game remind me of the way the shadow maps are dithered in GRAW1 and 2. I think they're filtering these shadow maps because otherwise you get a 'texelly' or 'pixelly' artifact. The way the 360 and PS3 do shadow mapping is different, I don't know how, but the difference is visible in games. The Infinity Ward developers said they liked the PS3's shadow mapping effect better too.
360 can do the exact same shadowing algorithm of PS3 (bilinear PCF), but it's a bit slower. It's not a particularly favoured algorithm among the graphics community anyway (although Rockstar's choice is not very good either).

Besides, from what everyone is saying, PS3 has the same shadow dithering as 360 (if not worse), so I don't think they used different shadowing algorithms.

2. Fill Rate. There has been a effect that LOOKS like dithering in many 360 games, and I've had some people tell me it was a way of reducing fill rate costs on the 360. I know it's present in Burnout Paradise (look at trees, direct feeded and zoomed), and early Battlefield Bad Company screens showed it too.
Burnout doesn't have anything like this. There are spotty areas from alpha testing (and probably alpha to coverage) in trees and fences, but that's always there regardless of platform:

PS3: http://yoda.dip.jp/Game/BurnoutP/BurnOutP_01_PS3.png
360: http://yoda.dip.jp/Game/BurnoutP/BurnOutP_01_360.png

Looking at the fences and trees, there are some subtle differences, but both have what could be called dithering. Nothing here is like what you see with GTA4 where it affects objects that aren't alpha blended and messes up textures.
 
360 can do the exact same shadowing algorithm of PS3 (bilinear PCF), but it's a bit slower. It's not a particularly favoured algorithm among the graphics community anyway (although Rockstar's choice is not very good either).

Do you know any place to look up different shadowing algorithms? Personally my overall impression of the GTAIV technique seems like one of the better I've seen. The range of the shadow maps (in tiers) reaches further than something like Burnout Paradise. Not as many artifacts as COD4 either.

Besides, from what everyone is saying, PS3 has the same shadow dithering as 360 (if not worse), so I don't think they used different shadowing algorithms.

Yea, I haven't tried the PS3 version, but if that's true that's a big point.

Burnout doesn't have anything like this. There are spotty areas from alpha testing (and probably alpha to coverage) in trees and fences, but that's always there regardless of platform:

PS3: http://yoda.dip.jp/Game/BurnoutP/BurnOutP_01_PS3.png
360: http://yoda.dip.jp/Game/BurnoutP/BurnOutP_01_360.png

Looking at the fences and trees, there are some subtle differences, but both have what could be called dithering. Nothing here is like what you see with GTA4 where it affects objects that aren't alpha blended and messes up textures.

Well I'm just repeating what I've heard, to me the 360 shot there seems to be doing far less layers, it seems almost every other pixel isn't being rendered in the layers of the trees.

There's quite a bit of visual difference in those shots IMO, however you don't notice the difference much at all during actual gameplay (even if you're looking for it)
 
is your projector DVI or HDMI? if its dvi, you may want to try setting RGB to full if you haven't already. if its HDMI, you may want to try the opposite. reason being, if its DVI, it may be expecting a PC colorspace, therefore, setting it to limited might be clipping black detail. and if its HDMI, the opposite would be the case.

HDMI, and i played around with this quite alot, it just seems extremely dark.
 
Hello everyone. Shifty pmed me asking for some shots, so here you all are. I took many shots so I hope they are of some use. I can take more if needed. I was particularly interested in the building shots. The red brick seems to have the same effect on it until you are very close to it. So this seems to affect all textures??

http://dot50cal.the-horror.com/b3d/gta4/dithering/

Perhaps this is the way the LOD system switches between low resolution and high resolution textures?? Since this seems to affect even shadows though, I'd guess its something to do with the Depth of Field. But that is only of course my uneducated guess :p
 
Last edited by a moderator:
Okay, I think I've figured it out.

Part of the dithering is from the shadowing, as I suggested before. Wherever an object is near a shadow edge (and the edges are quite wide), there are only 4 levels of shadows, so this causes dithering. GTA appears to use 4 jittered point samples from the shadow map. A few more shader instructions and fetch4 would make nicer shadows, but they obviously didn't bother and/or didn't think it made much difference. PS3 appears to have less of this aliasing in still screenshots, so maybe PCF samples were used instead of point samples, but it's hard to say for sure. I suspect that this dithering is not as objectionable as in the blowups of Dot50Cal's screenshots unless you have good eyes and 1:1 pixel mapping on a native 720p HDTV.

The other problem is more serious, as it affects texture details. It looks like Rockstar accidentally enabled alpha-to-coverage for decal textures. That means wherever you have an alpha value in the decals (which is used to blend into the object it's being pasted on), you will have either 0, 1, or 2 samples in each pixel updated with the decal, depending on the alpha value and the alpha-to-coverage dither algorithm.

Because the PS3 doesn't have AA, there is no alpha to coverage option. For bushes/trees and fences, the PS3 version would either use regular alpha testing, which would have even more aliasing, or alpha blending, which should have been used on 360 as well if this is the case. For decals, I'm sure that PS3 uses alpha blending as every other game does. Maybe alpha blending was enabled on 360 for the decals too, but they forgot to turn the alpha to coverage setting off.

In the "BurgerShot" sign, I think the pinkish areas on the PS3 shot (e.g. the text) is white with ~50% alpha, leading to the jumbly mess in the 360 zoom when alpha-to-coverage is used.
 
xbox 360 at 480p

High first post

Wow, could someone else with an xbox lower the console resolution to 480p and tell me what you think? On the xbox at least, I have to think this looks more like what Rockstar had in mind when they designed the game.
 
As always, thanks for the shots Dot50Cal.
Shadow filtering looks nice btw.
The other problem is more serious, as it affects texture details. It looks like Rockstar accidentally enabled alpha-to-coverage for decal textures. That means wherever you have an alpha value in the decals (which is used to blend into the object it's being pasted on), you will have either 0, 1, or 2 samples in each pixel updated with the decal, depending on the alpha value and the alpha-to-coverage dither algorithm.

Because the PS3 doesn't have AA, there is no alpha to coverage option. For bushes/trees and fences, the PS3 version would either use regular alpha testing, which would have even more aliasing, or alpha blending, which should have been used on 360 as well if this is the case. For decals, I'm sure that PS3 uses alpha blending as every other game does. Maybe alpha blending was enabled on 360 for the decals too, but they forgot to turn the alpha to coverage setting off.

In the "BurgerShot" sign, I think the pinkish areas on the PS3 shot (e.g. the text) is white with ~50% alpha, leading to the jumbly mess in the 360 zoom when alpha-to-coverage is used.

Why do you think it has transparency inside the font?
I could understand the outline, but inside? Does it give better results when texels are small or something?
 
PS3 appears to have less of this aliasing in still screenshots, so maybe PCF samples were used instead of point samples, but it's hard to say for sure. I suspect that this dithering is not as objectionable as in the blowups of Dot50Cal's screenshots unless you have good eyes and 1:1 pixel mapping on a native 720p HDTV.

Actually it's very much more noticably on 360 in movement because it causes this flimmering (and that's what Quaz and others are saying).
 
Both games are poor image wise. Yep I can see the dithering on the 360 version everyones on about, but I'd take that anyday over the blurred iamge you get on the PS3 version. Personally I can't play it on the PS3, I keep having to refocus my eyes which makes it really tiring to play.
 
HDMI, and i played around with this quite alot, it just seems extremely dark.

I know what you mean, follow this guide
1. calibrate your TV with pictures from this site.
2. use this image for brightness (black level) calibration
3. and use this image for contrast (white level) calibration (Colour setting can also have influence on contrast setting, so play with both colour and contrast)
4. in GTA4, we have two options, contrast and brightness, but R* is so uneducated they switched brightness and contrast, I don`t know what they thinking, but on well calibrated TV we only need gamma curve correction (maybe those sliders called brightness and contrast are gamma modifiers just undercover :LOL: ). So what u need is move up contrast setting little bit.
 
Back
Top