Hello, everyone!
Let's say I have a simple C++ application:
RZRESULT res = Init();
assert(res == RZRESULT_SUCCESS);
ChromaSDK::Keyboard::STATIC_EFFECT_TYPE effect{};
effect.Color = RGB(255, 0, 0);
// std::this_thread::sleep_for(std::chrono::seconds{1}); // This fixes it!
res = CreateKeyboardEffect(ChromaSDK::Keyboard::CHROMA_STATIC, &effect, NULL);
assert(res == RZRESULT_SUCCESS);
getchar();
res = UnInit();
assert(res == RZRESULT_SUCCESS);
Weirdly enough, this application doesn't work, unless I delay setting the effect for roughly a second. All asserts pass, but the effect doesn't apply. Looks like there's some kind of asynchronous initialization happening with no explicit way to control or observe it. Am I doing something wrong? Is there a way to consistently enable an effect immediately after application start?
Sign up
Already have an account? Login
Log in with Razer ID to create new threads and earn badges.
LOG INEnter your E-mail address. We'll send you an e-mail with instructions to reset your password.