MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / ExampleImageViewer_DrawOptions

Function ExampleImageViewer_DrawOptions

3rdparty/imgui/src/imgui_demo.cpp:850–859  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

848};
849
850static void ExampleImageViewer_DrawOptions(ExampleImageViewerData* data)
851{
852 ImGui::SetNextItemShortcut(ImGuiKey_G, ImGuiInputFlags_Tooltip); // | ImGuiInputFlags_RouteGlobal
853 ImGui::Checkbox("Grid", &data->GridEnabled);
854 ImGui::SameLine();
855 ImGui::SetNextItemWidth(ImGui::GetFontSize() * 10.0f);
856 float zoom_100 = data->Zoom * 100.0f;
857 if (ImGui::DragFloat("##Zoom", &zoom_100, 5.0f, data->ZoomMin * 100.0f, data->ZoomMax * 100.0f, "%.0f%%", ImGuiSliderFlags_AlwaysClamp))
858 data->Zoom = zoom_100 / 100.0f;
859}
860
861static void ExampleImageViewer_DrawCanvas(ExampleImageViewerData* data, ImVec2 canvas_size, ImTextureRef image_tex_ref, int image_w, int image_h)
862{

Callers 2

DemoWindowWidgetsImagesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected