Skip to content

Commit

Permalink
fix detection of small RGB images
Browse files Browse the repository at this point in the history
  • Loading branch information
olaf-rogalsky committed Jan 7, 2024
1 parent 340ebeb commit 2ef436b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ImageInTerminal.jl
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ function choose_sixel(img::AbstractArray)
# Small images really do not need sixel encoding.
# `60` is a randomly chosen value (10 sixel); it's not the best because
# 60x60 image will be very small in terminal after sixel encoding.
any(size(img) .≤ 12) && return false
all(size(img) .≤ 60) && return false
any(size(img)[1:2] .≤ 12) && return false
all(size(img)[1:2] .≤ 60) && return false
return true
end
end
Expand Down

0 comments on commit 2ef436b

Please sign in to comment.