Duncan Murdoch-2 wrote: > > On 11/12/2009 4:56 AM, kvarpun wrote: >> Hi, >> >> Is there an R package that reads and writes 3D images having the >> extension >> PLY (PLY images of Stanford University)? >> >> Currently, I installed the package misc3d. This package displays these >> images PLY, but it can neither read nor write PLY images. > > This doesn't make sense. How can it display PLY images if it can't read > them? Could you give an example? > > Duncan Murdoch > >> >> Thank you to tell me the name of a package that will read and write such >> images. > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > >
Thank you for quick answer. I have to inform you that the only available functions in the package misc3d are: contour3d Draw an Isosurface, a Three Dimension Contour Plot drawScene Rendering of Triangular Mesh Surface Data image3d Draw Points on a 3D Grid kde3d Compute a Three Dimension Kernel Density Estimate makeTriangles Triangle Mesh Functions parametric3d Draw a 3D Parametric Plot perspLighting Lighting Functions phongLighting Lighting Functions pointsTetrahedra Create a Set of Tetrahetra Centered at Data Points scaleTriangles Triangle Mesh Functions slices3d Interactive Image Slices of 3D or 4D Volume Data surfaceTriangles Create a Triangle Mesh Representing a Surface teapot Utah Teapot translateTriangles Triangle Mesh Functions updateTriangles Triangle Mesh Functions None of them does read/write a PLY file. You will find below a simple code for drawing a 3D image. The displayed image is stored in the package misc3d (not read from a file). library(misc3d) data(teapot) haveRGL <- suppressWarnings(require(rgl,quietly=TRUE)) ttri <- makeTriangles(teapot$vertices, teapot$edges, color = "red", color2 = "green") ## draw the teapot drawScene(ttri,screen=list(y=-30,x=40), scale = FALSE) str(teapot) # > str(teapot) # List of 2 # $ vertices: num [1:3, 1:1976] -3,00 1,65 0,00 -2,99 1,65 ... # $ edges : int [1:3, 1:3751] 1455 1469 1459 1449 1455 1459 1462 1449 1459 1469 ... # My images (PLY images) have vertices and edges like the teapot image in the example. If PLY images are read by R, I will be able to manipulate them. Thanks. -- View this message in context: http://old.nabble.com/R-package-for-reading---writing-3D-file-%28.-PLY%29-tp26315292p26321925.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.