• Mathias Agopian's avatar
    fix part of [2017702] OpenGL bugs with alpha values of 1.0 in the source... · 9d881764
    Mathias Agopian authored
    fix part of [2017702] OpenGL bugs with alpha values of 1.0 in the source during blending into 8888 buffers
    
    when ONE / ONE_MINUS_SRC_ALPHA blending mode was used, the code wasn't saturating the color component.
    the reason was that this mode is used for premltiplied alpha blending, however, if used with a non
    premultiplied source, the color component would wrap.
    
    unfortunately, this costs 6 extra cycles per pixels, however... "correctness" prevails.
    
    this should not impact the UI since it's using h/w acceleration most of the time it also doesn't
    impact games which should be using h/w GL. This change will slow the emulator down a bit.
    9d881764
t32cb16blend.S 4.73 KB