surface fix
This commit is contained in:
parent
1f1ccd81bb
commit
1636587a82
@ -458,7 +458,7 @@ function _add_series(pkg::PyPlotBackend, plt::Plot; kw...)
|
|||||||
handle
|
handle
|
||||||
|
|
||||||
elseif lt in (:surface,:wireframe)
|
elseif lt in (:surface,:wireframe)
|
||||||
x, y, z = d[:x], d[:y], Array(d[:z])
|
x, y, z = Array(d[:x]), Array(d[:y]), Array(d[:z])
|
||||||
if !ismatrix(x) || !ismatrix(y)
|
if !ismatrix(x) || !ismatrix(y)
|
||||||
x = repmat(x', length(y), 1)
|
x = repmat(x', length(y), 1)
|
||||||
y = repmat(y, 1, length(d[:x]))
|
y = repmat(y, 1, length(d[:x]))
|
||||||
|
|||||||
@ -310,7 +310,8 @@ end
|
|||||||
# surfaces-like... general x, y grid
|
# surfaces-like... general x, y grid
|
||||||
function process_inputs{T<:Number}(plt::AbstractPlot, d::KW, x::AMat{T}, y::AMat{T}, zmat::AMat{T})
|
function process_inputs{T<:Number}(plt::AbstractPlot, d::KW, x::AMat{T}, y::AMat{T}, zmat::AMat{T})
|
||||||
@assert size(zmat) == size(x) == size(y)
|
@assert size(zmat) == size(x) == size(y)
|
||||||
d[:x], d[:y], d[:z] = Any[x], Any[y], Surface{Matrix{Float64}}(zmat)
|
# d[:x], d[:y], d[:z] = Any[x], Any[y], Surface{Matrix{Float64}}(zmat)
|
||||||
|
d[:x], d[:y], d[:z] = map(Surface{Matrix{Float64}}, (x, y, zmat))
|
||||||
if !like_surface(get(d, :linetype, :none))
|
if !like_surface(get(d, :linetype, :none))
|
||||||
d[:linetype] = :contour
|
d[:linetype] = :contour
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user