mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2025-03-23 13:25:40 -04:00
Cleanup.
This commit is contained in:
parent
167a6717c5
commit
167ec3e1bc
1 changed files with 20 additions and 20 deletions
|
@ -1558,7 +1558,7 @@ struct Imgui
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void colorWheelWidget(float _color[3], bool _respectIndentation, bool _enabled)
|
void colorWheelWidget(float _rgb[3], bool _respectIndentation, bool _enabled)
|
||||||
{
|
{
|
||||||
m_widgetId++;
|
m_widgetId++;
|
||||||
const uint32_t wheelId = (m_areaId << 16) | m_widgetId;
|
const uint32_t wheelId = (m_areaId << 16) | m_widgetId;
|
||||||
|
@ -1593,7 +1593,7 @@ struct Imgui
|
||||||
float sel[2];
|
float sel[2];
|
||||||
|
|
||||||
float hsv[3];
|
float hsv[3];
|
||||||
rgbToHsv(hsv, _color);
|
rgbToHsv(hsv, _rgb);
|
||||||
|
|
||||||
if (_enabled)
|
if (_enabled)
|
||||||
{
|
{
|
||||||
|
@ -1690,7 +1690,7 @@ struct Imgui
|
||||||
const float sat = bx::fclamp(uu/val, 0.0001f, 1.0f);
|
const float sat = bx::fclamp(uu/val, 0.0001f, 1.0f);
|
||||||
|
|
||||||
const float out[3] = { hsv[0], sat, val };
|
const float out[3] = { hsv[0], sat, val };
|
||||||
hsvToRgb(_color, out);
|
hsvToRgb(_rgb, out);
|
||||||
|
|
||||||
// Draw widget.
|
// Draw widget.
|
||||||
nvgSave(m_nvg);
|
nvgSave(m_nvg);
|
||||||
|
|
Loading…
Add table
Reference in a new issue