From e82dbd9e5de782fea05043597115e00708f4eacc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maximilian=20K=C3=B6hler?= Date: Thu, 11 Apr 2024 09:54:00 +0200 Subject: [PATCH] remove minsmax check in favour of automatic --- src/makieplotting.jl | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/src/makieplotting.jl b/src/makieplotting.jl index 5ae9e22..dd7daeb 100644 --- a/src/makieplotting.jl +++ b/src/makieplotting.jl @@ -330,19 +330,6 @@ function Makie.plot!(SF::Surface{<:Tuple{<:MakiePlotter{2}}}) coords = @lift begin Point3f[Point3f(coord[1], coord[2], $(solution)[idx]) for (idx, coord) in enumerate(plotter.physical_coords)] end - mins = @lift(minimum(x->isnan(x) ? 1e10 : x, $solution)) - maxs = @lift(maximum(x->isnan(x) ? -1e10 : x, $solution)) - SF[:colorrange] = @lift begin - if isapprox($mins,$maxs) - if isapprox($mins,zero($mins)) && isapprox($maxs,zero($maxs)) - (1e-18,2e-18) - else - ($mins,1.01($maxs)) - end - else - ($mins,$maxs) - end - end return Makie.mesh!(SF, coords, plotter.vis_triangles, color=solution, scale_plot=SF[:scale_plot], shading=SF[:shading], colormap=SF[:colormap], colorrange=SF[:colorrange], nan_color=SF[:nan_color]) end