Skip to content

Commit

Permalink
Avoid using the deprecated ColorView type (#185)
Browse files Browse the repository at this point in the history
It's been deprecated a long time, but only as a call, not as a binding.
  • Loading branch information
timholy authored Aug 28, 2020
1 parent 39cf88a commit ec0f7a3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/ImageMagick.jl
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,9 @@ mapIM(x::Normed) = x
to_contiguous(A::Array) = A
to_contiguous(A::AbstractArray) = collect(A)
to_contiguous(A::BitArray) = convert(Array{Bool}, A)
to_contiguous(A::ColorView) = to_contiguous(channelview(A))
if isdefined(ImageCore, :ColorView)
to_contiguous(A::ColorView) = to_contiguous(channelview(A))
end

to_explicit(A::Array{C}) where {C<:Colorant} = to_explicit(channelview(A))
function to_explicit(A::AbstractArray)
Expand Down

0 comments on commit ec0f7a3

Please sign in to comment.