// Tip: if we don't call ImGui::Begin()/ImGui::End() the widgets automatically appears in a window called "Debug".
{
ImGui::SetNextWindowPos(ImVec2(650,20),ImGuiCond_FirstUseEver);// Normally user code doesn't need/want to call this because positions are saved in .ini file anyway. Here we just want to make the demo initial state a bit more friendly!
ImGui::ShowDemoWindow(&hud->show_demo_window);
staticfloatf=0.0f;
staticintcounter=0;
ImGui::Text("Hello, world!");// Display some text (you can use a format string too)
ImGui::SliderFloat("float",&f,0.0f,1.0f);// Edit 1 float using a slider from 0.0f to 1.0f
ImGui::ColorEdit3("clear color",(float*)&clear_color);// Edit 3 floats representing a color
ImGui::Checkbox("Demo Window",&hud->show_demo_window);// Edit bools storing our windows open/close state
// 3. Show the ImGui demo window. Most of the sample code is in ImGui::ShowDemoWindow(). Read its code to learn more about Dear ImGui!
if(hud->show_demo_window)
{
ImGui::SetNextWindowPos(ImVec2(650,20),ImGuiCond_FirstUseEver);// Normally user code doesn't need/want to call this because positions are saved in .ini file anyway. Here we just want to make the demo initial state a bit more friendly!