Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion impeller/entity/contents/texture_contents.cc
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#include "impeller/entity/entity.h"
#include "impeller/entity/texture_fill.frag.h"
#include "impeller/entity/texture_fill.vert.h"
#include "impeller/geometry/constants.h"
#include "impeller/geometry/path_builder.h"
#include "impeller/renderer/formats.h"
#include "impeller/renderer/render_pass.h"
Expand Down Expand Up @@ -72,7 +73,8 @@ std::optional<Snapshot> TextureContents::RenderToSnapshot(

// Passthrough textures that have simple rectangle paths and complete source
// rects.
if (is_rect_ && source_rect_ == Rect::MakeSize(texture_->GetSize())) {
if (is_rect_ && source_rect_ == Rect::MakeSize(texture_->GetSize()) &&
opacity_ >= 1 - kEhCloseEnough) {
auto scale = Vector2(bounds->size / Size(texture_->GetSize()));
return Snapshot{.texture = texture_,
.transform = entity.GetTransformation() *
Expand Down