From 19e2c186c288c73d041685fdc8f69a3d2a274664 Mon Sep 17 00:00:00 2001 From: focus Date: Tue, 6 Dec 2011 15:50:50 +0000 Subject: [PATCH] Remove second arg from setBlendLevel git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-beta@1953 e54a6e83-5905-42d5-8d5c-058d10e6a962 --- src/driver/fade.cpp | 6 +++--- src/driver/framebuffer.cpp | 14 +++++++------- src/driver/framebuffer.h | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/driver/fade.cpp b/src/driver/fade.cpp index 1fc13472e..3368d97ca 100644 --- a/src/driver/fade.cpp +++ b/src/driver/fade.cpp @@ -50,7 +50,7 @@ void COSDFader::StartFadeIn() fadeOut = false; fadeValue = 100; frameBuffer->setBlendMode(2); // Global alpha multiplied with pixel alpha - frameBuffer->setBlendLevel(fadeValue, fadeValue); + frameBuffer->setBlendLevel(fadeValue); fadeTimer = g_RCInput->addTimer( FADE_TIME, false ); } @@ -92,7 +92,7 @@ bool COSDFader::Fade() g_RCInput->killTimer (fadeTimer); ret = true; } else - frameBuffer->setBlendLevel(fadeValue, fadeValue); + frameBuffer->setBlendLevel(fadeValue); } else { // appears fadeValue -= FADE_STEP; if (fadeValue <= max_alpha) { @@ -101,7 +101,7 @@ bool COSDFader::Fade() fadeIn = false; frameBuffer->setBlendMode(1); // Set back to per pixel alpha } else - frameBuffer->setBlendLevel(fadeValue, fadeValue); + frameBuffer->setBlendLevel(fadeValue); } return ret; } diff --git a/src/driver/framebuffer.cpp b/src/driver/framebuffer.cpp index 19a1fe0cb..d4ae3c40f 100644 --- a/src/driver/framebuffer.cpp +++ b/src/driver/framebuffer.cpp @@ -518,18 +518,18 @@ void CFrameBuffer::setBlendMode(uint8_t mode) #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 + //printf("CFrameBuffer::setBlendLevel %d\n", level); + unsigned char value = 0xFF; + if((level >= 0) && (level <= 100)) + value = convertSetupAlpha2Alpha(level); + if (ioctl(fd, FBIO_SETOPACITY, value)) printf("FBIO_SETOPACITY failed.\n"); #if 1 - if(blev1 == 100) // TODO: sucks. + if(level == 100) // TODO: sucks. usleep(20000); #endif #endif diff --git a/src/driver/framebuffer.h b/src/driver/framebuffer.h index f9e813385..abacc0d4c 100644 --- a/src/driver/framebuffer.h +++ b/src/driver/framebuffer.h @@ -142,7 +142,7 @@ class CFrameBuffer void setTransparency( int tr = 0 ); void setBlendMode(uint8_t mode = 1); - void setBlendLevel(int blev1, int blev2); + void setBlendLevel(int level); //Palette stuff void setAlphaFade(int in, int num, int tr);