*Sub-Thread* Dithering in GTA4

Discussion in 'Console Technology' started by Laa-Yosh, Apr 28, 2008.

  1. Asher

    Regular

    Joined:
    Jul 1, 2005
    Messages:
    972
    Likes Received:
    8
    Location:
    Calgary, Alberta
    Maybe the dithering came up as they implemented some performance optimizations late in the game? (No pun intended)
     
  2. chachi

    Newcomer

    Joined:
    Sep 15, 2004
    Messages:
    120
    Likes Received:
    3
    Some of the dithering is intentional, they definitely do some kind of grain producing shader (didn't Mass Effect do something like that?), seemingly LOD biased so it breaks up more the further you get from the camera. I'm not sure if the texture scrambling (affecting mostly signs but you can see it on that billboard shot and maybe the railing) is a separate thing or if it's just the dithering shader running amok when asked to work on an alpha blended surface.

    What we really need is someone from R* to spill their guts. :)
     
  3. nAo

    nAo Nutella Nutellae
    Veteran

    Joined:
    Feb 6, 2002
    Messages:
    4,333
    Likes Received:
    125
    Location:
    San Francisco
    Mintmaster's theory makes sense to me, though we have no elements to tell if these supposedly screwed mip maps are being loaded from disc or generated in realtime.
     
  4. Fafalada

    Veteran

    Joined:
    Feb 8, 2002
    Messages:
    2,773
    Likes Received:
    49
    Considering how many other much worse, even game breaking bugs, are in both versions of the game, I don't think it would be shocking at all. It's patently obvious the Q&A for this needed more time.

    That said, I am on the side of "it looks intentional" with this one. Whether it was an accepted visual tradeoff for something, or an experiment with visual direction, nothing in how it poped up in media few months back and stayed until release suggests it's a bug.
     
    #184 Fafalada, May 7, 2008
    Last edited by a moderator: May 7, 2008
  5. Sc4freak

    Newcomer

    Joined:
    Dec 28, 2004
    Messages:
    233
    Likes Received:
    2
    Location:
    Melbourne, Australia
    Generating the mipmaps is easy enough; compressing them is not. Recall that textures would be stored on disk in compressed format - almost certainly DXT. In addition to decompression and downsampling of the images, you also need to perform compression on the new downsampled surfaces. DXT compression is, well, very slow.

    If they were using a software-based compressor, I don't think they'd be able to perform mipmap generation + compression on all of their textures, simply due to the sheer volume of data.
     
  6. Shifty Geezer

    Shifty Geezer uber-Troll!
    Moderator Legend

    Joined:
    Dec 7, 2004
    Messages:
    43,577
    Likes Received:
    16,028
    Location:
    Under my bridge
    Are you talking about the dithering or the noise? I don't see how the texture-destroying noise could be an artistic choice! Same question to Laa-Yosh too.
     
  7. Jawed

    Legend

    Joined:
    Oct 2, 2004
    Messages:
    10,876
    Likes Received:
    768
    Location:
    London
    All minified textures have this noise in them - signs, due to their highly-detailed, high-contrast appearance simply make the noise easier to see.

    Separately there appears to be alpha-to-coverage noise.

    Jawed
     
  8. Arwin

    Arwin Now Officially a Top 10 Poster
    Moderator Legend

    Joined:
    May 17, 2006
    Messages:
    18,063
    Likes Received:
    1,660
    Location:
    Maastricht, The Netherlands
    AlStrong previously posted something that made me wonder if this is relevant here:

     
  9. Simon F

    Simon F Tea maker
    Moderator Veteran

    Joined:
    Feb 8, 2002
    Messages:
    4,560
    Likes Received:
    157
    Location:
    In the Island of Sodor, where the steam trains lie
    I haven't read through this whole thread but, am I right in understanding that when running in a 640x480 mode the images look good but look dithered at 1080x720?

    Since that represents a > 2.5x increase in frame buffer costs (not to mention Z costs), could it simply be that the coders have opted for a 16-bit frame buffer just for the HD case?
     
  10. Laa-Yosh

    Laa-Yosh I can has custom title?
    Legend Subscriber

    Joined:
    Feb 12, 2002
    Messages:
    9,568
    Likes Received:
    1,455
    Location:
    Budapest, Hungary
    It's not that kind of dithering that you get from lack of color precision, take a look at all the screenshots.
     
  11. Jawed

    Legend

    Joined:
    Oct 2, 2004
    Messages:
    10,876
    Likes Received:
    768
    Location:
    London
    Are GTA4's textures generally encoded in DXT1?

    Does RSX do the blurry/low-precision rendering of DTX1 textures described here?:

    http://udn.epicgames.com/Two/TextureComparison.html#NVIDIA DXT1 Issue

    This post by Wolfgang:

    http://diaryofagraphicsprogrammer.blogspot.com/2007/12/normal-map-data-ii.html

    says something intriguing about RSX DXT1:

    Would that tend towards implying that most textures (albedo at least) are DXT1?

    So, erm, dumb question time, if you start with a DXT1 base texture and generate mipmaps from it, is this noise likely to arise?

    Jawed
     
  12. Mintmaster

    Veteran

    Joined:
    Mar 31, 2002
    Messages:
    3,897
    Likes Received:
    87
    True, but there might be a way to speed up compression of lower levels when you have the top level already compressed.

    There's also the (slim?) possibility of GTA not using DXT. I haven't seen any tile boundaries at all, though I suppose they're pretty subtle. The specifics of my theory about the garbling (i.e. the data tiling) doesn't fit with texture compression, but I guess one can find an alternative explanation that does.
     
  13. Rockster

    Regular

    Joined:
    Nov 5, 2003
    Messages:
    973
    Likes Received:
    129
    Location:
    On my rock
    I can tell you. On RSX, DXT1 textures remain compressed in cache while other texture formats are expanded. Xenos expands everything.
     
  14. paawl

    Newcomer

    Joined:
    Feb 3, 2007
    Messages:
    113
    Likes Received:
    0
    If what you say about Xenos is true, then why would MS state that "uncompressed textures" are a "texture cache pain point"?
     
  15. Rockster

    Regular

    Joined:
    Nov 5, 2003
    Messages:
    973
    Likes Received:
    129
    Location:
    On my rock
    Not sure. Just listen to the actual talk, 28 minutes or so in.
     
  16. Sc4freak

    Newcomer

    Joined:
    Dec 28, 2004
    Messages:
    233
    Likes Received:
    2
    Location:
    Melbourne, Australia
    It's almost certain that they're using DXT1 for opaque textures, and DXT3/DXT5 for textures with an alpha channel. DXT is pretty much your only choice when it comes to texture compression - all other formats are uncompressed. With DXT1 being 6x smaller than an uncompressed R8G8B8 image, Rockstar would be insane not to use it considering the already low memory available on consoles.
     
  17. Simon F

    Simon F Tea maker
    Moderator Veteran

    Joined:
    Feb 8, 2002
    Messages:
    4,560
    Likes Received:
    157
    Location:
    In the Island of Sodor, where the steam trains lie
    Hmm. yes. Very curious. I can't imagine that it would be a texture compression artefact, at least, not from DXT*, since the texture should compress fairly trivially. (At least putting the PS3 image through DXT1 results in utterly negligible differences)
     
  18. maluraq

    Newcomer

    Joined:
    Nov 21, 2007
    Messages:
    9
    Likes Received:
    0
    Location:
    Canada
    Oh please don't start. I haven't met any normal person who can't hear the difference between CD, DD, dts, and uncompressed 7.1 96kHz PCM. CDs are not the pinnacle of audio quality to the human ear, they're just good enough to not make most people care any more (just like a Ford Focus, lol, or insert your favourite mediocre car here).

    There are plenty of semi-deaf people out there who shouldn't be pushed into buying things they can't discern, but shouldn't be making judgements about others' hearing either. There are also people (like my wife) who can't tell whether she's looking at 720p, 1080p or 480p unless you flip it back and forth repeatedly so she notices the PQ change.
     
  19. grandmaster

    Veteran

    Joined:
    Feb 6, 2007
    Messages:
    1,159
    Likes Received:
    0
    OK I referred this dithering issue to one of the best cross-format developers in the world. Bear in mind that the response is based on screenshots, I've no idea to what extent they've played the game.

    The response is basically this:

    - the effect isn't a bug, it has to be deliberate
    - there are no DXT compression issues or anything similar, it looks to be an artistic choice
    - it doesn't look like a post-processing effect as it doesn't seem to affect edges
    - most likely it's a jittered texture sample in the shaders to achieve a grainy look or depth-of-field effect
    - the reason it's not in the PS3 version is that, most likely, it would impact performance to implement it

    Further, it's very likely that the game led development-wise on 360 as the devkits etc would've been around much earlier than the PS3 ones would have been, so logically the PS3 version was always going to be a port.

    The good news I suppose is that it's an effect that can be turned off!
     
  20. Mize

    Mize 3dfx Fan
    Moderator Legend Veteran

    Joined:
    Feb 6, 2002
    Messages:
    5,079
    Likes Received:
    1,149
    Location:
    Cincinnati, Ohio USA
    They made the textures ugly on purpose?
    Why not just use ugly textures to begin with :)
     
Loading...

Share This Page

  • About Us

    Beyond3D has been around for over a decade and prides itself on being the best place on the web for in-depth, technically-driven discussion and analysis of 3D graphics hardware. If you love pixels and transistors, you've come to the right place!

    Beyond3D is proudly published by GPU Tools Ltd.
Loading...