Compiler warnings
width and height to PlotRawImage
This commit is contained in:
parent
f0ee85d022
commit
2f023ab756
3 changed files with 8 additions and 8 deletions
|
@ -27,7 +27,7 @@ extern "C"
|
||||||
|
|
||||||
unsigned char frame[SSD1306_128x64_BYTES];
|
unsigned char frame[SSD1306_128x64_BYTES];
|
||||||
|
|
||||||
SSD1306::SSD1306(int BSCMaster, u8 address, int width, int height, int flip, LCD_MODEL type)
|
SSD1306::SSD1306(int BSCMaster, u8 address, unsigned width, unsigned height, int flip, LCD_MODEL type)
|
||||||
: BSCMaster(BSCMaster)
|
: BSCMaster(BSCMaster)
|
||||||
, address(address)
|
, address(address)
|
||||||
, type(type)
|
, type(type)
|
||||||
|
@ -135,7 +135,7 @@ void SSD1306::MoveCursorByte(u8 page, u8 col)
|
||||||
|
|
||||||
void SSD1306::RefreshScreen()
|
void SSD1306::RefreshScreen()
|
||||||
{
|
{
|
||||||
int i;
|
unsigned i;
|
||||||
for (i = 0; i < height/8; i++)
|
for (i = 0; i < height/8; i++)
|
||||||
{
|
{
|
||||||
RefreshPage(i);
|
RefreshPage(i);
|
||||||
|
|
|
@ -76,7 +76,7 @@ class SSD1306
|
||||||
public:
|
public:
|
||||||
// 128x32 0x3C
|
// 128x32 0x3C
|
||||||
// 128x64 0x3D or 0x3C (if SA0 is grounded)
|
// 128x64 0x3D or 0x3C (if SA0 is grounded)
|
||||||
SSD1306(int BSCMaster = 1, u8 address = 0x3C, int width = 128, int height = 64, int flip = 0, LCD_MODEL type=LCD_UNKNOWN);
|
SSD1306(int BSCMaster = 1, u8 address = 0x3C, unsigned width = 128, unsigned height = 64, int flip = 0, LCD_MODEL type=LCD_UNKNOWN);
|
||||||
|
|
||||||
void PlotCharacter(int x, int y, char ascii, bool inverse);
|
void PlotCharacter(int x, int y, char ascii, bool inverse);
|
||||||
void PlotText(int x, int y, char* str, bool inverse);
|
void PlotText(int x, int y, char* str, bool inverse);
|
||||||
|
@ -110,8 +110,8 @@ protected:
|
||||||
int type;
|
int type;
|
||||||
int flip;
|
int flip;
|
||||||
int contrast;
|
int contrast;
|
||||||
int width;
|
unsigned width;
|
||||||
int height;
|
unsigned height;
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -381,14 +381,14 @@ void InitialiseLCD()
|
||||||
bool logo_done = false;
|
bool logo_done = false;
|
||||||
if ( (height == 64) && (strcasecmp(options.GetLcdLogoName(), "1541ii") == 0) )
|
if ( (height == 64) && (strcasecmp(options.GetLcdLogoName(), "1541ii") == 0) )
|
||||||
{
|
{
|
||||||
screenLCD->PlotRawImage(logo_ssd_1541ii, 0, 0, 128, 64);
|
screenLCD->PlotRawImage(logo_ssd_1541ii, 0, 0, width, height);
|
||||||
snprintf(tempBuffer, tempBufferSize, "Pi1541 V%d.%02d", versionMajor, versionMinor);
|
snprintf(tempBuffer, tempBufferSize, "Pi1541 V%d.%02d", versionMajor, versionMinor);
|
||||||
screenLCD->PrintText(0, 16, 0, tempBuffer, 0xffffffff);
|
screenLCD->PrintText(0, 16, 0, tempBuffer, 0xffffffff);
|
||||||
logo_done = true;
|
logo_done = true;
|
||||||
}
|
}
|
||||||
else if (( height == 64) && (strcasecmp(options.GetLcdLogoName(), "1541classic") == 0) )
|
else if (( height == 64) && (strcasecmp(options.GetLcdLogoName(), "1541classic") == 0) )
|
||||||
{
|
{
|
||||||
screenLCD->PlotRawImage(logo_ssd_1541classic, 0, 0, 128, 64);
|
screenLCD->PlotRawImage(logo_ssd_1541classic, 0, 0, width, height);
|
||||||
logo_done = true;
|
logo_done = true;
|
||||||
}
|
}
|
||||||
else if (f_stat(options.GetLcdLogoName(), &filLcdIcon) == FR_OK && filLcdIcon.fsize <= LCD_LOGO_MAX_SIZE)
|
else if (f_stat(options.GetLcdLogoName(), &filLcdIcon) == FR_OK && filLcdIcon.fsize <= LCD_LOGO_MAX_SIZE)
|
||||||
|
@ -402,7 +402,7 @@ void InitialiseLCD()
|
||||||
u32 bytesRead;
|
u32 bytesRead;
|
||||||
f_read(&fp, LcdLogoFile, LCD_LOGO_MAX_SIZE, &bytesRead);
|
f_read(&fp, LcdLogoFile, LCD_LOGO_MAX_SIZE, &bytesRead);
|
||||||
f_close(&fp);
|
f_close(&fp);
|
||||||
screenLCD->PlotRawImage(LcdLogoFile, 0, 0, 128, height);
|
screenLCD->PlotRawImage(LcdLogoFile, 0, 0, width, height);
|
||||||
logo_done = true;
|
logo_done = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue