Skip to content

Commit 0f573b6

Browse files
committed
Fix texture overlay example add-on not building due to imgui update
1 parent 47af426 commit 0f573b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/10-texture_overlay/texture_overlay_addon.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ static void draw_overlay(effect_runtime *runtime)
389389
const ImVec2 pos = ImGui::GetCursorScreenPos();
390390
const ImVec2 size = aspect_ratio > 1 ? ImVec2(single_image_max_size, single_image_max_size / aspect_ratio) : ImVec2(single_image_max_size * aspect_ratio, single_image_max_size);
391391

392-
ImGui::Image(tex_data.last_view.handle, size, ImVec2(0, 0), ImVec2(1, 1), ImGui::IsMouseHoveringRect(pos, ImVec2(pos.x + size.x, pos.y + size.y)) ? ImColor(0.0f, 1.0f, 0.0f) : ImColor(1.0f, 1.0f, 1.0f), ImColor(0.0f, 0.0f, 0.0f, 0.0f));
392+
ImGui::ImageWithBg(tex_data.last_view.handle, size, ImVec2(0, 0), ImVec2(1, 1), ImColor(0.0f, 0.0f, 0.0f, 0.0f), ImGui::IsMouseHoveringRect(pos, ImVec2(pos.x + size.x, pos.y + size.y)) ? ImColor(0.0f, 1.0f, 0.0f) : ImColor(1.0f, 1.0f, 1.0f));
393393

394394
if (ImGui::IsItemHovered())
395395
data->replaced_texture_srv = tex_data.last_view;

0 commit comments

Comments
 (0)