Skip to content

Commit 44ac8a2

Browse files
committed
fix: removed deprecated function
1 parent 63bba19 commit 44ac8a2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

imgui-SFML.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -803,7 +803,7 @@ void Image(const sf::Texture& texture, const sf::Vector2f& size, const sf::Color
803803
{
804804
ImTextureID textureID = convertGLTextureHandleToImTextureID(texture.getNativeHandle());
805805

806-
ImGui::Image(textureID, toImVec2(size), ImVec2(0, 0), ImVec2(1, 1), toImColor(tintColor), toImColor(borderColor));
806+
ImGui::ImageWithBg(textureID, toImVec2(size), ImVec2(0, 0), ImVec2(1, 1), toImColor(tintColor), toImColor(borderColor));
807807
}
808808

809809
/////////////// Image Overloads for sf::RenderTexture
@@ -816,7 +816,7 @@ void Image(const sf::RenderTexture& texture, const sf::Vector2f& size, const sf:
816816
{
817817
ImTextureID textureID = convertGLTextureHandleToImTextureID(texture.getTexture().getNativeHandle());
818818

819-
ImGui::Image(textureID,
819+
ImGui::ImageWithBg(textureID,
820820
toImVec2(size),
821821
ImVec2(0, 1),
822822
ImVec2(1, 0), // flipped vertically,
@@ -837,7 +837,7 @@ void Image(const sf::Sprite& sprite, const sf::Color& tintColor, const sf::Color
837837
void Image(const sf::Sprite& sprite, const sf::Vector2f& size, const sf::Color& tintColor, const sf::Color& borderColor)
838838
{
839839
auto [uv0, uv1, textureID] = getSpriteTextureData(sprite);
840-
ImGui::Image(textureID, toImVec2(size), uv0, uv1, toImColor(tintColor), toImColor(borderColor));
840+
ImGui::ImageWithBg(textureID, toImVec2(size), uv0, uv1, toImColor(tintColor), toImColor(borderColor));
841841
}
842842

843843
/////////////// Image Button Overloads for sf::Texture

0 commit comments

Comments
 (0)