Skip to content

Commit 5ed7aac

Browse files
authored
Merge pull request #487 from dmurdoch/arrowbug
Fix arrow3d: extrude3d no longer accepts repeated vertices.
2 parents d88c75b + 2215a6c commit 5ed7aac

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Package: rgl
2-
Version: 1.3.28
2+
Version: 1.3.29
33
Title: 3D Visualization Using OpenGL
44
Authors@R: c(person("Duncan", "Murdoch", role = c("aut", "cre"),
55
email = "[email protected]"),

NEWS.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1-
# rgl 1.3.28
1+
# rgl 1.3.29
22

33
* Support for classes defined in the `tripack` package
44
has been dropped at the request of CRAN.
55
* Added the `latex3d()` function to draw LaTeX text using the
66
`xdvir` package.
77
* Both `plotmath3d()` and `latex3d()` now use default
88
`cex = par3d("cex")`, and have new argument `polygon_offset`.
9+
* `arrow3d(type = "extrusion")` was broken by the changes to triangulation in version 1.3.16.
910

1011
# rgl 1.3.24
1112

R/arrow3d.R

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,8 @@ arrow3d <- function(p0=c(1,1,1), p1=c(0,0,0), barblen, s=1/3, theta=pi/12,
8181
xyz <- xyz %*% t(gs)
8282
if (type == "extrusion") {
8383
thickness <- thickness*sqrt(sum((xyz[2,]-xyz[8,])^2))
84-
ext <- extrude3d(xyz[,c(1,3)], thickness = thickness)
84+
# extrude3d no longer accepts repeated vertices
85+
ext <- extrude3d(xyz[-1,c(1,3)], thickness = thickness)
8586
} else {
8687
mid <- xyz[1,3]
8788
xyz[,3] <- abs(xyz[,3] - mid)

0 commit comments

Comments
 (0)