Skip to content

Commit

Permalink
rename Tesselation -> Tessellation
Browse files Browse the repository at this point in the history
  • Loading branch information
ffreyer committed Nov 4, 2024
1 parent 41a1f12 commit d109ff1
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion docs/src/curves.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ M, N = size(z)
points = map(x-> x ./ Point3f(4, 4, 1.0) .+ Point3f(0, 0, 1.0), vec(Point3f.(x, y', z)))
# Connect the vetices with faces, as one would use for a 2D Rectangle
# grid with M,N grid points
faces = decompose(LineFace{GLIndex}, Tesselation(Rect2(0, 0, 1, 1), (M, N)))
faces = decompose(LineFace{GLIndex}, Tessellation(Rect2(0, 0, 1, 1), (M, N)))
indices = RPR.rpr_int[]
for elem in faces
push!(indices, first(elem)-1, first(elem)-1, last(elem)-1, last(elem)-1)
Expand Down
2 changes: 1 addition & 1 deletion docs/src/surface_mesh.jl
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function create_mesh(DN = 512, dphi=pi/200.0f0, dtheta=dphi)
z = @. r * sin(phi) * sin(theta)

xyz = Point3f[Point3f(x[i, j], y[i, j], z[i, j]) for i in 1:size(x, 1), j in 1:size(x, 2)]
r = Tesselation(Rect2f((0, 0), (1, 1)), size(x))
r = Tessellation(Rect2f((0, 0), (1, 1)), size(x))
# decomposing a rectangle into uv and triangles is what we need to map the z coordinates on
# since the xyz data assumes the coordinates to have the same neighouring relations
# like a grid
Expand Down
4 changes: 2 additions & 2 deletions examples/basic-uber.jl
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ mesh, mat = add_shape!(scene, context, matsys, Rect3f(Vec3f(0, -2, 0), Vec3f(5,
mesh, mat = add_shape!(scene, context, matsys, Rect3f(Vec3f(0, 2, 0), Vec3f(5, 0.1, 5));
color=colorant"white")

mesh, mat = add_shape!(scene, context, matsys, Tesselation(Sphere(Point3f(2, 0, 2), 0.95f0), 100);
mesh, mat = add_shape!(scene, context, matsys, Tessellation(Sphere(Point3f(2, 0, 2), 0.95f0), 100);
color=colorant"white")
rpr_mesh = RPR.Shape(context, Tesselation(Sphere(Point3f(2, 0, 2), 1.0f0), 100))
rpr_mesh = RPR.Shape(context, Tessellation(Sphere(Point3f(2, 0, 2), 1.0f0), 100))
push!(scene, rpr_mesh)
material = RPR.MaterialNode(matsys, RPR.RPR_MATERIAL_NODE_UBERV2)

Expand Down
2 changes: 1 addition & 1 deletion examples/basic.jl
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ mesh, mat = add_shape!(scene, context, matsys, Rect3f(Vec3f(0, -2, 0), Vec3f(5,
mesh, mat = add_shape!(scene, context, matsys, Rect3f(Vec3f(0, 2, 0), Vec3f(5, 0.1, 5));
color=colorant"white")

mesh, mat_sphere = add_shape!(scene, context, matsys, Tesselation(Sphere(Point3f(2, 0, 2), 1.0f0), 100);
mesh, mat_sphere = add_shape!(scene, context, matsys, Tessellation(Sphere(Point3f(2, 0, 2), 1.0f0), 100);
material=RPR.RPR_MATERIAL_NODE_MICROFACET, roughness=0.2, color=colorant"red")

fb_size = (800, 600)
Expand Down
2 changes: 1 addition & 1 deletion examples/curves.jl
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ M, N = size(z)
points = map(x-> x ./ Point3f(4, 4, 1.0) .+ Point3f(0, 0, 1.0), vec(Point3f.(x, y', z)))
# Connect the vetices with faces, as one would use for a 2D Rectangle
# grid with M,N grid points
faces = decompose(LineFace{GLIndex}, Tesselation(Rect2(0, 0, 1, 1), (M, N)))
faces = decompose(LineFace{GLIndex}, Tessellation(Rect2(0, 0, 1, 1), (M, N)))
indices = RPR.rpr_int[]
for elem in faces
push!(indices, first(elem)-1, first(elem)-1, last(elem)-1, last(elem)-1)
Expand Down
2 changes: 1 addition & 1 deletion examples/surfacemesh.jl
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function create_mesh(DN = 512, dphi=pi/200.0f0, dtheta=dphi)
z = @. r * sin(phi) * sin(theta)

xyz = Point3f[Point3f(x[i, j], y[i, j], z[i, j]) for i in 1:size(x, 1), j in 1:size(x, 2)]
r = Tesselation(Rect2f((0, 0), (1, 1)), size(x))
r = Tessellation(Rect2f((0, 0), (1, 1)), size(x))
# decomposing a rectangle into uv and triangles is what we need to map the z coordinates on
# since the xyz data assumes the coordinates to have the same neighouring relations
# like a grid
Expand Down
2 changes: 1 addition & 1 deletion test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ mesh, mat = add_shape!(scene, context, matsys, Rect3f(Vec3f(0, -2, 0), Vec3f(5,
mesh, mat = add_shape!(scene, context, matsys, Rect3f(Vec3f(0, 2, 0), Vec3f(5, 0.1, 5));
color=colorant"blue")

mesh, mat_sphere = add_shape!(scene, context, matsys, Tesselation(Sphere(Point3f(2, 0, 2), 1.0f0), 100); color=colorant"red")
mesh, mat_sphere = add_shape!(scene, context, matsys, Tessellation(Sphere(Point3f(2, 0, 2), 1.0f0), 100); color=colorant"red")
fb_size = (800, 600)
frame_buffer = RPR.FrameBuffer(context, RGBA, fb_size)
frame_bufferSolved = RPR.FrameBuffer(context, RGBA, fb_size)
Expand Down

0 comments on commit d109ff1

Please sign in to comment.