mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-04 10:03:36 +00:00
Use correct screen scale when native resolution used.
This commit is contained in:
parent
f6be5fd39f
commit
16f5bfa423
|
@ -408,7 +408,10 @@ void ShaderCombiner::updateDitherMode(bool _bForce)
|
|||
|
||||
const int nDither = (gDP.otherMode.cycleType < G_CYC_COPY) && (gDP.otherMode.alphaCompare == G_AC_DITHER) ? 1 : 0;
|
||||
if ((m_nInputs & (1 << NOISE)) + nDither != 0) {
|
||||
m_uniforms.uScreenScale.set(video().getScaleX(), video().getScaleY(), _bForce);
|
||||
if (config.frameBufferEmulation.nativeResFactor == 0)
|
||||
m_uniforms.uScreenScale.set(video().getScaleX(), video().getScaleY(), _bForce);
|
||||
else
|
||||
m_uniforms.uScreenScale.set(float(config.frameBufferEmulation.nativeResFactor), float(config.frameBufferEmulation.nativeResFactor), _bForce);
|
||||
noiseTex.update();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -664,7 +664,10 @@ void ShaderCombiner::updateDitherMode(bool _bForce)
|
|||
|
||||
const int nDither = (gDP.otherMode.cycleType < G_CYC_COPY) && (gDP.otherMode.colorDither == G_CD_NOISE || gDP.otherMode.alphaDither == G_AD_NOISE || gDP.otherMode.alphaCompare == G_AC_DITHER) ? 1 : 0;
|
||||
if ((m_nInputs & (1 << NOISE)) + nDither != 0) {
|
||||
m_uniforms.uScreenScale.set(video().getScaleX(), video().getScaleY(), _bForce);
|
||||
if (config.frameBufferEmulation.nativeResFactor == 0)
|
||||
m_uniforms.uScreenScale.set(video().getScaleX(), video().getScaleY(), _bForce);
|
||||
else
|
||||
m_uniforms.uScreenScale.set(float(config.frameBufferEmulation.nativeResFactor), float(config.frameBufferEmulation.nativeResFactor), _bForce);
|
||||
noiseTex.update();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -846,7 +846,10 @@ void OGLRender::drawLine(int _v0, int _v1, float _width)
|
|||
unsigned short elem[2];
|
||||
elem[0] = _v0;
|
||||
elem[1] = _v1;
|
||||
glLineWidth(_width * video().getScaleX());
|
||||
if (config.frameBufferEmulation.nativeResFactor == 0)
|
||||
glLineWidth(_width * video().getScaleX());
|
||||
else
|
||||
glLineWidth(_width * config.frameBufferEmulation.nativeResFactor);
|
||||
glDrawElements(GL_LINES, 2, GL_UNSIGNED_SHORT, elem);
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user