Remove second arg from setBlendLevel

git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@1953 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
focus
2011-12-06 15:50:50 +00:00
parent 9674a05733
commit 19e2c186c2
3 changed files with 11 additions and 11 deletions

View File

@@ -50,7 +50,7 @@ void COSDFader::StartFadeIn()
fadeOut = false; fadeOut = false;
fadeValue = 100; fadeValue = 100;
frameBuffer->setBlendMode(2); // Global alpha multiplied with pixel alpha frameBuffer->setBlendMode(2); // Global alpha multiplied with pixel alpha
frameBuffer->setBlendLevel(fadeValue, fadeValue); frameBuffer->setBlendLevel(fadeValue);
fadeTimer = g_RCInput->addTimer( FADE_TIME, false ); fadeTimer = g_RCInput->addTimer( FADE_TIME, false );
} }
@@ -92,7 +92,7 @@ bool COSDFader::Fade()
g_RCInput->killTimer (fadeTimer); g_RCInput->killTimer (fadeTimer);
ret = true; ret = true;
} else } else
frameBuffer->setBlendLevel(fadeValue, fadeValue); frameBuffer->setBlendLevel(fadeValue);
} else { // appears } else { // appears
fadeValue -= FADE_STEP; fadeValue -= FADE_STEP;
if (fadeValue <= max_alpha) { if (fadeValue <= max_alpha) {
@@ -101,7 +101,7 @@ bool COSDFader::Fade()
fadeIn = false; fadeIn = false;
frameBuffer->setBlendMode(1); // Set back to per pixel alpha frameBuffer->setBlendMode(1); // Set back to per pixel alpha
} else } else
frameBuffer->setBlendLevel(fadeValue, fadeValue); frameBuffer->setBlendLevel(fadeValue);
} }
return ret; return ret;
} }

View File

@@ -518,18 +518,18 @@ void CFrameBuffer::setBlendMode(uint8_t mode)
#endif #endif
} }
void CFrameBuffer::setBlendLevel(int blev1, int /*blev2*/) void CFrameBuffer::setBlendLevel(int level)
{ {
//printf("CFrameBuffer::setBlendLevel %d\n", blev1);
unsigned char value = 0xFF;
if((blev1 >= 0) && (blev1 <= 100))
value = convertSetupAlpha2Alpha(blev1);
#ifdef HAVE_COOL_HARDWARE #ifdef HAVE_COOL_HARDWARE
//printf("CFrameBuffer::setBlendLevel %d\n", level);
unsigned char value = 0xFF;
if((level >= 0) && (level <= 100))
value = convertSetupAlpha2Alpha(level);
if (ioctl(fd, FBIO_SETOPACITY, value)) if (ioctl(fd, FBIO_SETOPACITY, value))
printf("FBIO_SETOPACITY failed.\n"); printf("FBIO_SETOPACITY failed.\n");
#if 1 #if 1
if(blev1 == 100) // TODO: sucks. if(level == 100) // TODO: sucks.
usleep(20000); usleep(20000);
#endif #endif
#endif #endif

View File

@@ -142,7 +142,7 @@ class CFrameBuffer
void setTransparency( int tr = 0 ); void setTransparency( int tr = 0 );
void setBlendMode(uint8_t mode = 1); void setBlendMode(uint8_t mode = 1);
void setBlendLevel(int blev1, int blev2); void setBlendLevel(int level);
//Palette stuff //Palette stuff
void setAlphaFade(int in, int num, int tr); void setAlphaFade(int in, int num, int tr);