diff --git a/RGBController/RGBController_AMDWraithPrism.cpp b/RGBController/RGBController_AMDWraithPrism.cpp index 96b9227d..c5022986 100644 --- a/RGBController/RGBController_AMDWraithPrism.cpp +++ b/RGBController/RGBController_AMDWraithPrism.cpp @@ -131,5 +131,18 @@ void RGBController_AMDWraithPrism::SetLED(int led, RGBColor color) void RGBController_AMDWraithPrism::UpdateLEDs() { + unsigned char red = RGBGetRValue(colors[0]); + unsigned char grn = RGBGetGValue(colors[0]); + unsigned char blu = RGBGetBValue(colors[0]); + wraith->SetLogoColor(red, grn, blu); + red = RGBGetRValue(colors[1]); + grn = RGBGetGValue(colors[1]); + blu = RGBGetBValue(colors[1]); + wraith->SetFanColor(red, grn, blu); + + red = RGBGetRValue(colors[2]); + grn = RGBGetGValue(colors[2]); + blu = RGBGetBValue(colors[2]); + wraith->SetRingColor(red, grn, blu); } diff --git a/RGBController/RGBController_Hue2.cpp b/RGBController/RGBController_Hue2.cpp index 6823d71e..c213714a 100644 --- a/RGBController/RGBController_Hue2.cpp +++ b/RGBController/RGBController_Hue2.cpp @@ -134,10 +134,12 @@ void RGBController_Hue2::SetLED(int led, RGBColor color) void RGBController_Hue2::UpdateLEDs() { - std::vector channel_colors; - - for(unsigned int channel = 0; channel < HUE_2_NUM_CHANNELS; channel++) + for(std::size_t zone_idx = 0; zone_idx <= zones.size(); zone_idx++) { + unsigned int channel = zones_channel[zone_idx]; + + std::vector channel_colors; + for(std::size_t color = 0; color < colors.size(); color++) { if(leds_channel[color] == channel) @@ -150,7 +152,5 @@ void RGBController_Hue2::UpdateLEDs() { hue2->SetChannelLEDs(channel, channel_colors); } - - channel_colors.clear(); } } diff --git a/RGBController/RGBController_HuePlus.cpp b/RGBController/RGBController_HuePlus.cpp index 5564aec6..dd3f76a5 100644 --- a/RGBController/RGBController_HuePlus.cpp +++ b/RGBController/RGBController_HuePlus.cpp @@ -136,5 +136,23 @@ void RGBController_HuePlus::SetLED(int led, RGBColor color) void RGBController_HuePlus::UpdateLEDs() { - hueplus->SetChannelLEDs(0, colors); + for(std::size_t zone_idx = 0; zone_idx <= zones.size(); zone_idx++) + { + unsigned int channel = zones_channel[zone_idx]; + + std::vector channel_colors; + + for(std::size_t color = 0; color < colors.size(); color++) + { + if(leds_channel[color] == channel) + { + channel_colors.push_back(colors[color]); + } + } + + if(channel_colors.size() > 0) + { + hueplus->SetChannelLEDs(channel, channel_colors); + } + } } diff --git a/RGBController/RGBController_PatriotViper.cpp b/RGBController/RGBController_PatriotViper.cpp index 6e60edad..445bd622 100644 --- a/RGBController/RGBController_PatriotViper.cpp +++ b/RGBController/RGBController_PatriotViper.cpp @@ -94,7 +94,13 @@ void RGBController_PatriotViper::SetLED(int led, RGBColor color) void RGBController_PatriotViper::UpdateLEDs() { - + for(int led = 0; led < 5; led++) + { + unsigned char red = RGBGetRValue(colors[led]); + unsigned char grn = RGBGetGValue(colors[led]); + unsigned char blu = RGBGetBValue(colors[led]); + viper->SetLEDColor(led, red, grn, blu); + } } RGBController_PatriotViper::RGBController_PatriotViper(PatriotViperController* viper_ptr)