Fix more warnings
This commit is contained in:
parent
47877193a7
commit
429068760d
13 changed files with 42 additions and 40 deletions
|
|
@ -179,7 +179,8 @@ void PolychromeUSBController::WriteRGSwap
|
|||
void PolychromeUSBController::WriteHeader
|
||||
(
|
||||
unsigned char cfg,
|
||||
unsigned char configstring[]
|
||||
unsigned char* configstring,
|
||||
unsigned int configsize
|
||||
)
|
||||
{
|
||||
unsigned char usb_buf[65];
|
||||
|
|
@ -194,7 +195,7 @@ void PolychromeUSBController::WriteHeader
|
|||
\*-----------------------------------------------------*/
|
||||
usb_buf[0x01] = POLYCHROME_USB_WRITE_HEADER;
|
||||
usb_buf[0x03] = cfg;
|
||||
memcpy(&usb_buf[4], configstring, sizeof(configstring));
|
||||
memcpy(&usb_buf[4], configstring, configsize);
|
||||
|
||||
/*-----------------------------------------------------*\
|
||||
| Send packet |
|
||||
|
|
@ -207,7 +208,7 @@ PolychromeZoneInfo PolychromeUSBController::GetZoneConfig(unsigned char zone)
|
|||
{
|
||||
unsigned char usb_buf[65];
|
||||
PolychromeZoneInfo zoneinfo;
|
||||
unsigned char all;
|
||||
//unsigned char all;
|
||||
unsigned char r;
|
||||
unsigned char g;
|
||||
unsigned char b;
|
||||
|
|
@ -242,7 +243,7 @@ PolychromeZoneInfo PolychromeUSBController::GetZoneConfig(unsigned char zone)
|
|||
zoneinfo.color = ToRGBColor(r,g,b);
|
||||
zoneinfo.speed = usb_buf[0x08];
|
||||
zoneinfo.zone = usb_buf[0x03];
|
||||
all = usb_buf[0x10];
|
||||
//all = usb_buf[0x10];
|
||||
|
||||
return(zoneinfo);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -128,8 +128,9 @@ public:
|
|||
|
||||
void WriteHeader
|
||||
(
|
||||
unsigned char cfg,
|
||||
unsigned char configstring []
|
||||
unsigned char cfg,
|
||||
unsigned char* configstring,
|
||||
unsigned int configsize
|
||||
);
|
||||
|
||||
protected:
|
||||
|
|
|
|||
|
|
@ -258,8 +258,8 @@ void RGBController_PolychromeUSB::ResizeZone(int zone, int new_size)
|
|||
zonecfg[i]=zones[i].leds_count;
|
||||
}
|
||||
|
||||
unsigned char zonecmd = POLYCHROME_USB_LEDCOUNT_CFG;
|
||||
// WriteHeader(zonecmd, zonecfg);
|
||||
// unsigned char zonecmd = POLYCHROME_USB_LEDCOUNT_CFG;
|
||||
// WriteHeader(zonecmd, zonecfg, sizeof(zonecfg));
|
||||
}
|
||||
|
||||
void RGBController_PolychromeUSB::DeviceUpdateLEDs()
|
||||
|
|
|
|||
|
|
@ -147,7 +147,7 @@ void CMSmallARGBController::SetMode(unsigned char mode, unsigned char speed, RGB
|
|||
SendUpdate();
|
||||
}
|
||||
|
||||
void CMSmallARGBController::SetLedsDirect(RGBColor *led_colours, unsigned int led_count)
|
||||
void CMSmallARGBController::SetLedsDirect(RGBColor* /*led_colours*/, unsigned int /*led_count*/)
|
||||
{
|
||||
// Mode not yet Tested
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -336,7 +336,7 @@ void RGBController_CMARGBController::DeviceUpdateLEDs()
|
|||
}
|
||||
}
|
||||
|
||||
void RGBController_CMARGBController::UpdateZoneLEDs(int zone)
|
||||
void RGBController_CMARGBController::UpdateZoneLEDs(int /*zone*/)
|
||||
{
|
||||
//cmargb->SetLedsDirect( zones[zone].colors, zones[zone].leds_count );
|
||||
}
|
||||
|
|
|
|||
|
|
@ -224,14 +224,14 @@ void RGBController_CMSmallARGBController::DeviceUpdateLEDs()
|
|||
}
|
||||
}
|
||||
|
||||
void RGBController_CMSmallARGBController::UpdateZoneLEDs(int zone)
|
||||
void RGBController_CMSmallARGBController::UpdateZoneLEDs(int /*zone*/)
|
||||
{
|
||||
bool random_colours = (modes[active_mode].color_mode == MODE_COLORS_RANDOM);
|
||||
//bool random_colours = (modes[active_mode].color_mode == MODE_COLORS_RANDOM);
|
||||
|
||||
//cmargb->SetLedsDirect(zones[zone].colors, random_colours);
|
||||
}
|
||||
|
||||
void RGBController_CMSmallARGBController::UpdateSingleLED(int led)
|
||||
void RGBController_CMSmallARGBController::UpdateSingleLED(int /*led*/)
|
||||
{
|
||||
//cmargb->SetMode( modes[active_mode].value, modes[active_mode].speed );
|
||||
//cmargb->SetLedsDirect( zones[0].colors, zones[0].leds_count );
|
||||
|
|
|
|||
|
|
@ -113,7 +113,7 @@ void FanBusInterface::write_queue
|
|||
{
|
||||
unsigned char fanbus_msg[] = { 0x00, int_addr, dev_addr, val, 0xFF };
|
||||
|
||||
for(int i = 0; i < sizeof(fanbus_msg); i++)
|
||||
for(unsigned int i = 0; i < sizeof(fanbus_msg); i++)
|
||||
{
|
||||
fanbus_msg_queued.push_back(fanbus_msg[i]);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ void RGBController_FanBus::SetupZones()
|
|||
led_zone.matrix_map = NULL;
|
||||
zones.push_back(led_zone);
|
||||
|
||||
for(int led_idx = 0; led_idx < led_zone.leds_count; led_idx++)
|
||||
for(unsigned int led_idx = 0; led_idx < led_zone.leds_count; led_idx++)
|
||||
{
|
||||
led new_led;
|
||||
new_led.name = "LED ";
|
||||
|
|
|
|||
|
|
@ -129,7 +129,7 @@ void RGBController_HoltekA1FA::DeviceUpdateMode()
|
|||
if((active_mode < HOLTEK_A1FA_MODE_NEON) && (previous_mode < HOLTEK_A1FA_MODE_NEON))
|
||||
{
|
||||
//If we're switching from and to static and breathing then sync the mode colors
|
||||
for ( int i = 0; i < modes[active_mode].colors_max; i++)
|
||||
for(unsigned int i = 0; i < modes[active_mode].colors_max; i++)
|
||||
{
|
||||
modes[active_mode].colors[i] = modes[previous_mode].colors[i];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -184,7 +184,7 @@ void LEDStripController::SetLEDsKeyboardVisualizer(std::vector<RGBColor> colors)
|
|||
\*-------------------------------------------------------------*/
|
||||
unsigned short sum = 0;
|
||||
|
||||
for (int i = 0; i < (payload_size + 1); i++)
|
||||
for(unsigned int i = 0; i < (payload_size + 1); i++)
|
||||
{
|
||||
sum += serial_buf[i];
|
||||
}
|
||||
|
|
@ -317,4 +317,4 @@ void LEDStripController::SetLEDsTPM2(std::vector<RGBColor> colors)
|
|||
}
|
||||
|
||||
delete[] serial_buf;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -735,7 +735,7 @@ razer_report RazerController::razer_create_mode_breathing_one_color_extended_mat
|
|||
return report;
|
||||
}
|
||||
|
||||
razer_report RazerController::razer_create_mode_breathing_one_color_standard_matrix_report(unsigned char variable_storage, unsigned char led_id, unsigned char red, unsigned char grn, unsigned char blu)
|
||||
razer_report RazerController::razer_create_mode_breathing_one_color_standard_matrix_report(unsigned char /*variable_storage*/, unsigned char /*led_id*/, unsigned char red, unsigned char grn, unsigned char blu)
|
||||
{
|
||||
razer_report report = razer_create_report(0x03, 0x0A, 0x08);
|
||||
|
||||
|
|
@ -790,7 +790,7 @@ razer_report RazerController::razer_create_mode_breathing_two_colors_extended_ma
|
|||
return report;
|
||||
}
|
||||
|
||||
razer_report RazerController::razer_create_mode_breathing_two_colors_standard_matrix_report(unsigned char variable_storage, unsigned char led_id, unsigned char r1, unsigned char g1, unsigned char b1, unsigned char r2, unsigned char g2, unsigned char b2)
|
||||
razer_report RazerController::razer_create_mode_breathing_two_colors_standard_matrix_report(unsigned char /*variable_storage*/, unsigned char /*led_id*/, unsigned char r1, unsigned char g1, unsigned char b1, unsigned char r2, unsigned char g2, unsigned char b2)
|
||||
{
|
||||
razer_report report = razer_create_report(0x03, 0x0A, 0x08);
|
||||
|
||||
|
|
@ -838,7 +838,7 @@ razer_report RazerController::razer_create_mode_none_extended_matrix_report(unsi
|
|||
return report;
|
||||
}
|
||||
|
||||
razer_report RazerController::razer_create_mode_none_standard_matrix_report(unsigned char variable_storage, unsigned char led_id)
|
||||
razer_report RazerController::razer_create_mode_none_standard_matrix_report(unsigned char /*variable_storage*/, unsigned char /*led_id*/)
|
||||
{
|
||||
struct razer_report report = razer_create_report(0x03, 0x0A, 0x01);
|
||||
|
||||
|
|
@ -858,7 +858,7 @@ razer_report RazerController::razer_create_mode_spectrum_cycle_extended_matrix_r
|
|||
return report;
|
||||
}
|
||||
|
||||
razer_report RazerController::razer_create_mode_spectrum_cycle_standard_matrix_report(unsigned char variable_storage, unsigned char led_id)
|
||||
razer_report RazerController::razer_create_mode_spectrum_cycle_standard_matrix_report(unsigned char /*variable_storage*/, unsigned char /*led_id*/)
|
||||
{
|
||||
razer_report report = razer_create_report(0x03, 0x0A, 0x01);
|
||||
|
||||
|
|
@ -883,7 +883,7 @@ razer_report RazerController::razer_create_mode_static_extended_matrix_report(un
|
|||
return report;
|
||||
}
|
||||
|
||||
razer_report RazerController::razer_create_mode_static_standard_matrix_report(unsigned char variable_storage, unsigned char led_id, unsigned char red, unsigned char grn, unsigned char blu)
|
||||
razer_report RazerController::razer_create_mode_static_standard_matrix_report(unsigned char /*variable_storage*/, unsigned char /*led_id*/, unsigned char red, unsigned char grn, unsigned char blu)
|
||||
{
|
||||
razer_report report = razer_create_report(0x03, 0x0A, 0x04);
|
||||
|
||||
|
|
@ -909,7 +909,7 @@ razer_report RazerController::razer_create_mode_wave_extended_matrix_report(unsi
|
|||
return report;
|
||||
}
|
||||
|
||||
razer_report RazerController::razer_create_mode_wave_standard_matrix_report(unsigned char variable_storage, unsigned char led_id, unsigned char direction)
|
||||
razer_report RazerController::razer_create_mode_wave_standard_matrix_report(unsigned char /*variable_storage*/, unsigned char /*led_id*/, unsigned char direction)
|
||||
{
|
||||
razer_report report = razer_create_report(0x03, 0x0A, 0x02);
|
||||
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ union razer_kraken_effect_byte
|
|||
/*---------------------------------------------------------*\
|
||||
| Razer Kraken Report Types (taken from OpenRazer) |
|
||||
\*---------------------------------------------------------*/
|
||||
PACK(typedef struct razer_kraken_request_report
|
||||
PACK(struct razer_kraken_request_report
|
||||
{
|
||||
unsigned char report_id;
|
||||
unsigned char destination;
|
||||
|
|
|
|||
|
|
@ -305,21 +305,21 @@ void RGBController_ZalmanZSync::DeviceUpdateMode()
|
|||
}
|
||||
}
|
||||
|
||||
// controller->SetChannelEffect(channel,
|
||||
// zones[channel].leds_count,
|
||||
// modes[active_mode].value,
|
||||
// modes[active_mode].speed,
|
||||
// direction,
|
||||
// random,
|
||||
// mode_colors[0],
|
||||
// mode_colors[1],
|
||||
// mode_colors[2],
|
||||
// mode_colors[3],
|
||||
// mode_colors[4],
|
||||
// mode_colors[5],
|
||||
// mode_colors[6],
|
||||
// mode_colors[7],
|
||||
// mode_colors[8]);
|
||||
controller->SetChannelEffect(channel,
|
||||
zones[channel].leds_count,
|
||||
modes[active_mode].value,
|
||||
modes[active_mode].speed,
|
||||
direction,
|
||||
random,
|
||||
mode_colors[0],
|
||||
mode_colors[1],
|
||||
mode_colors[2],
|
||||
mode_colors[3],
|
||||
mode_colors[4],
|
||||
mode_colors[5],
|
||||
mode_colors[6],
|
||||
mode_colors[7],
|
||||
mode_colors[8]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue