Skip to content

Commit

Permalink
Revert "Fix ViewportPreview upside-down in 3.x."
Browse files Browse the repository at this point in the history
This reverts commit 1426df6.
  • Loading branch information
timothyqiu committed Feb 4, 2022
1 parent 4a52016 commit aeb9925
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions editor/plugins/viewport_preview_editor_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@ void EditorInspectorPluginViewportPreview::parse_begin(Object *p_object) {
Viewport *viewport = Object::cast_to<Viewport>(p_object);

TexturePreview *viewport_preview = memnew(TexturePreview(viewport->get_texture(), false));
viewport_preview->get_texture_display()->set_flip_v(true); // flip as ViewportTexture in 3.x is upside-down.

// Otherwise `viewport_preview`'s `texture_display` doesn't update properly when `viewport`'s size changes.
viewport->connect("size_changed", viewport_preview->get_texture_display(), "update");
add_custom_control(viewport_preview);
Expand Down

0 comments on commit aeb9925

Please sign in to comment.