sysclk: reformat kip editor and add fan speed to info
This commit is contained in:
@@ -126,16 +126,14 @@ static s32 drawDynamicUltraText(
|
||||
tsl::Color color(r, g, b, 15);
|
||||
|
||||
// ---------------------------------------------
|
||||
// Vertical Water Wobble
|
||||
// Static Position (no vertical wobble)
|
||||
// ---------------------------------------------
|
||||
s32 wobbleY = y + sin(phase) * 3;
|
||||
|
||||
std::string ls(1, letter);
|
||||
|
||||
if (useNotificationMethod)
|
||||
currentX += renderer->drawNotificationString(ls, false, currentX, wobbleY, fontSize, color).first;
|
||||
currentX += renderer->drawNotificationString(ls, false, currentX, y, fontSize, color).first;
|
||||
else
|
||||
currentX += renderer->drawString(ls, false, currentX, wobbleY, fontSize, color).first;
|
||||
currentX += renderer->drawString(ls, false, currentX, y, fontSize, color).first;
|
||||
}
|
||||
|
||||
return currentX;
|
||||
@@ -172,4 +170,4 @@ tsl::elm::Element* BaseGui::createUI()
|
||||
void BaseGui::update()
|
||||
{
|
||||
this->refresh();
|
||||
}
|
||||
}
|
||||
@@ -55,8 +55,8 @@ void BaseMenuGui::preDraw(tsl::gfx::Renderer* renderer) {
|
||||
if(!this->context) [[unlikely]] return;
|
||||
|
||||
// All constants pre-calculated and cached
|
||||
static constexpr const char* const labels[10] = {
|
||||
"App ID", "Profile", "CPU", "GPU", "MEM", "SoC", "Board", "Skin", "Now", "Avg"
|
||||
static constexpr const char* const labels[11] = {
|
||||
"App ID", "Profile", "CPU", "GPU", "MEM", "SoC", "Board", "Skin", "Now", "Avg", "Fan"
|
||||
};
|
||||
|
||||
static constexpr u32 dataPositions[6] = {63-3+3, 200-1, 344-1-3, 200-1, 342-1, 321-1};
|
||||
@@ -144,6 +144,13 @@ void BaseMenuGui::preDraw(tsl::gfx::Renderer* renderer) {
|
||||
|
||||
renderer->drawString(displayStrings[15], false, dataPositions[3], y, SMALL_TEXT_SIZE, tsl::infoTextColor); // Power now
|
||||
renderer->drawString(displayStrings[16], false, dataPositions[4], y, SMALL_TEXT_SIZE, tsl::infoTextColor); // Power avg
|
||||
|
||||
y+=20;
|
||||
|
||||
renderer->drawString(labels[10], false, positions[5], y, SMALL_TEXT_SIZE, tsl::sectionTextColor);
|
||||
|
||||
renderer->drawString(displayStrings[19], false, dataPositions[0], y, SMALL_TEXT_SIZE, tsl::infoTextColor); // Power now
|
||||
|
||||
}
|
||||
|
||||
// Optimized refresh - now does all the string formatting once per second
|
||||
@@ -233,6 +240,7 @@ void BaseMenuGui::refresh()
|
||||
|
||||
sprintf(displayStrings[17], "%u%%", context->PartLoad[HocClkPartLoad_GPU] / 10);
|
||||
sprintf(displayStrings[18], "%u%%", context->PartLoad[SysClkPartLoad_EMC] / 10);
|
||||
sprintf(displayStrings[19], "%hhu%%", context->fanLevel);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -124,9 +124,9 @@ void FreqChoiceGui::listUI()
|
||||
this->configList->values[HocClkConfigValue_MarikoMaxCpuClock] < mhz)
|
||||
continue;
|
||||
|
||||
if (moduleName == "gpu" &&
|
||||
this->configList->values[HocClkConfigValue_MarikoMaxGpuClock] < mhz)
|
||||
continue;
|
||||
// if (moduleName == "gpu" &&
|
||||
// this->configList->values[HocClkConfigValue_MarikoMaxGpuClock] < mhz)
|
||||
// continue;
|
||||
|
||||
// if (moduleName == "mem" &&
|
||||
// this->configList->values[HocClkConfigValue_MarikoMaxMemClock] < mhz)
|
||||
|
||||
@@ -34,17 +34,17 @@
|
||||
|
||||
void MainGui::listUI()
|
||||
{
|
||||
this->enabledToggle = new tsl::elm::ToggleListItem("Enable", false);
|
||||
enabledToggle->setStateChangedListener([this](bool state) {
|
||||
Result rc = sysclkIpcSetEnabled(state);
|
||||
if(R_FAILED(rc))
|
||||
{
|
||||
FatalGui::openWithResultCode("sysclkIpcSetEnabled", rc);
|
||||
}
|
||||
// this->enabledToggle = new tsl::elm::ToggleListItem("Enable", false);
|
||||
// enabledToggle->setStateChangedListener([this](bool state) {
|
||||
// Result rc = sysclkIpcSetEnabled(state);
|
||||
// if(R_FAILED(rc))
|
||||
// {
|
||||
// FatalGui::openWithResultCode("sysclkIpcSetEnabled", rc);
|
||||
// }
|
||||
|
||||
this->lastContextUpdate = armGetSystemTick();
|
||||
this->context->enabled = state;
|
||||
});
|
||||
// this->lastContextUpdate = armGetSystemTick();
|
||||
// this->context->enabled = state;
|
||||
// });
|
||||
// this->listElement->addItem(this->enabledToggle);
|
||||
|
||||
tsl::elm::ListItem* appProfileItem = new tsl::elm::ListItem("Edit App Profile");
|
||||
@@ -59,7 +59,6 @@ void MainGui::listUI()
|
||||
});
|
||||
this->listElement->addItem(appProfileItem);
|
||||
|
||||
this->listElement->addItem(new tsl::elm::CategoryHeader("Advanced"));
|
||||
|
||||
tsl::elm::ListItem* globalProfileItem = new tsl::elm::ListItem("Edit Global Profile");
|
||||
globalProfileItem->setClickListener([this](u64 keys) {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user