Skip to content

Commit

Permalink
Merge branch 'master' into cont_bug_nan
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonDanisch authored Sep 18, 2023
2 parents 5896ec3 + fdc84b8 commit 2e45332
Show file tree
Hide file tree
Showing 39 changed files with 436 additions and 352 deletions.
12 changes: 5 additions & 7 deletions .github/workflows/Docs.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
name: Docs build and deploy
on:
push:
pull_request:
branches:
- main
- master
- breaking-release
tags: '*'
pull_request:
- sd/beta-20
push:
tags:
- '*'
branches:
- main
- master
- breaking-release

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
Expand Down
11 changes: 3 additions & 8 deletions .github/workflows/cairomakie.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,10 @@ on:
- '*.md'
branches:
- master
- breaking-release
- sd/beta-20
push:
paths-ignore:
- 'docs/**'
- '*.md'
branches:
- master
- breaking-release
tags: '*'
tags:
- '*'

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
Expand Down
9 changes: 3 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,12 @@ on:
- '*.md'
branches:
- master
- breaking-release
- sd/beta-20
push:
paths-ignore:
- 'docs/**'
- '*.md'
tags:
- '*'
branches:
- master
- breaking-release
tags: '*'

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/compilation-benchmark.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- '*.md'
branches:
- master
- breaking-release
- sd/beta-20
jobs:
benchmark:
name: ${{ matrix.package }}
Expand Down
11 changes: 4 additions & 7 deletions .github/workflows/glmakie.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,12 @@ on:
- '*.md'
branches:
- master
- breaking-release
- sd/beta-20
push:
paths-ignore:
- 'docs/**'
- '*.md'
tags:
- '*'
branches:
- master
- breaking-release
tags: '*'

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
Expand Down Expand Up @@ -44,7 +41,7 @@ jobs:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: julia-actions/cache@v1
- run: sudo apt-get update && sudo apt-get install -y xorg-dev mesa-utils xvfb libgl1 freeglut3-dev libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev libxext-dev
- run: sudo apt-get update && sudo apt-get install -y xorg-dev mesa-utils xvfb libgl1 freeglut3-dev libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev libxext-dev xsettingsd x11-xserver-utils
- name: Install Julia dependencies
shell: julia --project=monorepo {0}
run: |
Expand Down
9 changes: 3 additions & 6 deletions .github/workflows/rprmakie.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,12 @@ on:
- '*.md'
branches:
- master
- breaking-release
- sd/beta-20
push:
paths-ignore:
- 'docs/**'
- '*.md'
tags:
- '*'
branches:
- master
- breaking-release
tags: '*'

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
Expand Down
10 changes: 3 additions & 7 deletions .github/workflows/wglmakie.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,12 @@ on:
- '*.md'
branches:
- master
- breaking-release
- sd/beta-20
push:
paths-ignore:
- 'docs/**'
- '*.md'
tags:
- '*'
branches:
- master
- breaking-release
tags: '*'

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
Expand Down
4 changes: 2 additions & 2 deletions CairoMakie/Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "CairoMakie"
uuid = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0"
author = ["Simon Danisch <sdanisch@gmail.com>"]
version = "0.10.8"
version = "0.10.9"

[deps]
Base64 = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f"
Expand All @@ -23,7 +23,7 @@ FFTW = "1"
FileIO = "1.1"
FreeType = "3, 4.0"
GeometryBasics = "0.4.1"
Makie = "=0.19.8"
Makie = "=0.19.9"
PrecompileTools = "1.0"
julia = "1.3"

Expand Down
4 changes: 4 additions & 0 deletions CairoMakie/test/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[deps]
Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a"
ReferenceTests = "d37af2e0-5618-4e00-9939-d430db56ee94"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
4 changes: 1 addition & 3 deletions CairoMakie/test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
using Test
using CairoMakie
using Pkg
using Makie.FileIO
using ReferenceTests

path = normpath(joinpath(dirname(pathof(Makie)), "..", "ReferenceTests"))
Pkg.develop(PackageSpec(path = path))
# Before changing Pkg environment, try the test in #864
@testset "Runs without error" begin
fig = Figure()
Expand Down
4 changes: 2 additions & 2 deletions GLMakie/Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "GLMakie"
uuid = "e9467ef8-e4e7-5192-8a1a-b1aee30e663a"
version = "0.8.8"
version = "0.8.9"

[deps]
ColorTypes = "3da002f7-5984-5a60-b8a6-cbb66c0b333f"
Expand Down Expand Up @@ -29,7 +29,7 @@ FixedPointNumbers = "0.7, 0.8"
FreeTypeAbstraction = "0.10"
GLFW = "3"
GeometryBasics = "0.4.1"
Makie = "=0.19.8"
Makie = "=0.19.9"
MeshIO = "0.4"
ModernGL = "1"
Observables = "0.5.1"
Expand Down
6 changes: 3 additions & 3 deletions GLMakie/src/drawing_primitives.jl
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,9 @@ end

function handle_intensities!(attributes, plot)
color = plot.calculated_colors
if color[] isa Makie.ColorMap
if color[] isa Makie.ColorMapping
attributes[:intensity] = color[].color_scaled
interp = color[].categorical[] ? :nearest : :linear
interp = color[].color_mapping_type[] === Makie.continuous ? :linear : :nearest
attributes[:color_map] = Texture(color[].colormap; minfilter=interp)
attributes[:color_norm] = color[].colorrange_scaled
attributes[:nan_color] = color[].nan_color
Expand Down Expand Up @@ -417,7 +417,7 @@ function draw_atomic(screen::Screen, scene::Scene, heatmap::Heatmap)
t = Makie.transform_func_obs(heatmap)
mat = heatmap[3]
space = heatmap.space # needs to happen before connect_camera! call
xypos = map(t, heatmap[1], heatmap[2], space) do t, x, y, space
xypos = lift(t, heatmap[1], heatmap[2], space) do t, x, y, space
x1d = xy_convert(x, size(mat[], 1))
y1d = xy_convert(y, size(mat[], 2))
# Only if transform doesn't do anything, we can stay linear in 1/2D
Expand Down
2 changes: 2 additions & 0 deletions GLMakie/test/Project.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
[deps]
FileIO = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549"
GLMakie = "e9467ef8-e4e7-5192-8a1a-b1aee30e663a"
GeometryBasics = "5c1252a2-5f33-56bf-86c9-59e7332b4326"
ImageMagick = "6218d12a-5da1-5696-b52f-db25d2ecc6d1"
Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a"
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
ReferenceTests = "d37af2e0-5618-4e00-9939-d430db56ee94"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
8 changes: 2 additions & 6 deletions GLMakie/test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@
using Makie
using GLMakie, Test
using FileIO
using GeometryBasics
using GeometryBasics: origin
using Makie
using ImageMagick
using Pkg
using Random
using ReferenceTests

if !GLMakie.ModernGL.enable_opengl_debugging
# can't error, since we can't enable debugging for users
@warn("TESTING WITHOUT OPENGL DEBUGGING")
end

reference_tests_dir = normpath(joinpath(dirname(pathof(Makie)), "..", "ReferenceTests"))
Pkg.develop(PackageSpec(path = reference_tests_dir))
using ReferenceTests

GLMakie.activate!(framerate=1.0)

Expand Down
2 changes: 1 addition & 1 deletion MakieCore/Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
authors = ["Simon Danisch"]
name = "MakieCore"
uuid = "20f20a25-4f0e-4fdf-b5d1-57303727442b"
version = "0.6.5"
version = "0.6.6"

[deps]
Observables = "510215fc-4207-5dde-b226-833fc4488ee2"
Expand Down
1 change: 1 addition & 0 deletions MakieCore/src/attributes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ Attributes(pairs::AbstractVector) = Attributes(Dict{Symbol, Observable}(node_pai
Attributes(pairs::Iterators.Pairs) = Attributes(collect(pairs))
Attributes(nt::NamedTuple) = Attributes(; nt...)
attributes(x::Attributes) = getfield(x, :attributes)
attributes(x::AbstractPlot) = getfield(x, :attributes)
Base.keys(x::Attributes) = keys(x.attributes)
Base.values(x::Attributes) = values(x.attributes)
function Base.iterate(x::Attributes, state...)
Expand Down
4 changes: 3 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# News

## master
- Allow arbitrary reversible scale functions through `ReversibleScale`.

## v0.19.9

- Allow arbitrary reversible scale functions through `ReversibleScale`.
- Deprecated `linestyle=vector_of_gaps` in favor of `linestyle=Linestyle(vector_of_gaps)` [3135](https://github.com/MakieOrg/Makie.jl/pull/3135), [3193](https://github.com/MakieOrg/Makie.jl/pull/3193).
- Fixed some errors around dynamic changes of `ax.xscale` or `ax.yscale` [#3084](https://github.com/MakieOrg/Makie.jl/pull/3084)
- Improved Barplot Label Alignment [#3160](https://github.com/MakieOrg/Makie.jl/issues/3160).
Expand Down
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "Makie"
uuid = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a"
authors = ["Simon Danisch", "Julius Krumbiegel"]
version = "0.19.8"
version = "0.19.9"

[deps]
Animations = "27a7e980-b3e6-11e9-2bcd-0b925532e340"
Expand Down Expand Up @@ -82,7 +82,7 @@ Isoband = "0.1"
KernelDensity = "0.5, 0.6"
LaTeXStrings = "1.2"
MacroTools = "0.5"
MakieCore = "=0.6.5"
MakieCore = "=0.6.6"
Match = "1.1"
MathTeXEngine = "0.5"
Observables = "0.5.3"
Expand Down
4 changes: 2 additions & 2 deletions RPRMakie/Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "RPRMakie"
uuid = "22d9f318-5e34-4b44-b769-6e3734a732a6"
authors = ["Simon Danisch"]
version = "0.5.8"
version = "0.5.9"

[deps]
Colors = "5ae59095-9a9b-59fe-a467-6f913c188581"
Expand All @@ -17,7 +17,7 @@ julia = "1.3"
Colors = "0.9, 0.10, 0.11, 0.12"
FileIO = "1.6"
GeometryBasics = "0.4.1"
Makie = "=0.19.8"
Makie = "=0.19.9"
RadeonProRender = "0.3.0"

[extras]
Expand Down
42 changes: 37 additions & 5 deletions ReferenceTests/src/tests/figures_and_makielayout.jl
Original file line number Diff line number Diff line change
Expand Up @@ -151,13 +151,13 @@ end
f = Figure(resolution = (800, 400))
ax1 = PolarAxis(f[1, 1], title = "No spine", spinevisible = false)
scatterlines!(ax1, range(0, 1, length=100), range(0, 10pi, length=100), color = 1:100)

ax2 = PolarAxis(f[1, 2], title = "Modified spine")
ax2.spinecolor[] = :red
ax2.spinestyle[] = :dash
ax2.spinewidth[] = 5
scatterlines!(ax2, range(0, 1, length=100), range(0, 10pi, length=100), color = 1:100)

f
end

Expand All @@ -166,9 +166,9 @@ end
@reference_test "PolarAxis decorations" begin
f = Figure(resolution = (400, 400), backgroundcolor = :black)
ax = PolarAxis(
f[1, 1],
f[1, 1],
backgroundcolor = :black,
rminorgridvisible = true, rminorgridcolor = :red,
rminorgridvisible = true, rminorgridcolor = :red,
rminorgridwidth = 1.0, rminorgridstyle = :dash,
thetaminorgridvisible = true, thetaminorgridcolor = :blue,
thetaminorgridwidth = 1.0, thetaminorgridstyle = :dash,
Expand All @@ -179,7 +179,6 @@ end
thetaticklabelsize = 18, thetaticklabelcolor = :blue,
thetaticklabelstrokewidth = 1, thetaticklabelstrokecolor = :white,
)

f
end

Expand All @@ -192,3 +191,36 @@ end
end
f
end

@reference_test "Colorbar for recipes" begin
fig, ax, pl = barplot(1:3; color=1:3, colormap=Makie.Categorical(:viridis), figure=(;resolution=(800, 800)))
Colorbar(fig[1, 2], pl; size=100)
x = LinRange(-1, 1, 20)
y = LinRange(-1, 1, 20)
z = LinRange(-1, 1, 20)
values = [sin(x[i]) * cos(y[j]) * sin(z[k]) for i in 1:20, j in 1:20, k in 1:20]

# TO not make this fail in CairoMakie, we dont actually plot the volume
_f, ax, cp = contour(x, y, z, values; levels=10, colormap=:viridis)
Colorbar(fig[2, :], cp; size=300)

# horizontal colorbars
Colorbar(fig[1, 3][2, 1]; limits=(0, 10), colormap=:viridis,
vertical=false)
Colorbar(fig[1, 3][3, 1]; limits=(0, 5), size=25,
colormap=cgrad(:Spectral, 5; categorical=true), vertical=false)
Colorbar(fig[1, 3][4, 1]; limits=(-1, 1), colormap=:heat, vertical=false, flipaxis=false,
highclip=:cyan, lowclip=:red)
xs = LinRange(0, 20, 50)
ys = LinRange(0, 15, 50)
zs = [cos(x) * sin(y) for x in xs, y in ys]
ax, hm = contourf(fig[2, 3][1, 1], xs, ys, zs;
colormap=:Spectral, levels=[-1, -0.5, -0.25, 0, 0.25, 0.5, 1])
Colorbar(fig[2, 3][1, 2], hm; ticks=-1:0.25:1)

ax, hm = contourf(fig[3, :][1, 1], xs, ys, zs;
colormap=:Spectral, colorscale=sqrt, levels=[ 0, 0.25, 0.5, 1])
Colorbar(fig[3, :][1, 2], hm; width=200)

fig
end
4 changes: 2 additions & 2 deletions WGLMakie/Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "WGLMakie"
uuid = "276b4fcb-3e11-5398-bf8b-a0c2d153d008"
authors = ["SimonDanisch <sdanisch@gmail.com>"]
version = "0.8.12"
version = "0.8.13"

[deps]
Colors = "5ae59095-9a9b-59fe-a467-6f913c188581"
Expand All @@ -26,7 +26,7 @@ FreeTypeAbstraction = "0.10"
GeometryBasics = "0.4.1"
Hyperscript = "0.0.3, 0.0.4"
JSServe = "2.2"
Makie = "=0.19.8"
Makie = "=0.19.9"
Observables = "0.5.1"
RelocatableFolders = "0.1, 0.2, 0.3, 1.0"
ShaderAbstractions = "0.3"
Expand Down
Loading

0 comments on commit 2e45332

Please sign in to comment.