Display target FPS also as time available.

This commit is contained in:
Bartosz Taudul 2021-06-08 22:56:06 +02:00
parent c79bfa349f
commit 66318bdb3b
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3

View File

@ -8510,12 +8510,14 @@ void View::DrawOptions()
m_vd.drawFrameTargets = val;
ImGui::Indent();
int tmp = m_vd.frameTarget;
ImGui::SetNextItemWidth( 120 );
ImGui::SetNextItemWidth( 90 );
if( ImGui::InputInt( "Target FPS", &tmp ) )
{
if( tmp < 1 ) tmp = 1;
m_vd.frameTarget = tmp;
}
ImGui::SameLine();
TextDisabledUnformatted( TimeToString( 1000*1000*1000 / tmp ) );
ImGui::Unindent();
if( m_worker.HasContextSwitches() )
{