[R-SIG-Mac] rgl on OSX

Jorge Manuel de Almeida Magalhães jmagalhaes at oninetspeed.pt
Thu Apr 21 12:12:46 CEST 2005

Dear Sir,

I would like make some 3D graphics with RGL.

Did you know how i can fix this related problem.

Your post tmessage:

Looking at the .FirstLib code of rgl I saw

.First.lib <- function(lib, pkg)
    # For MacOS X we have to remove /usr/X11R6/lib from the
    # because it would override Apple's OpenGL framework


    # load shared library

    library.dynam( "rgl", pkg, lib)

    ret <- .C( symbol.C("rgl_init"),

    if (!ret$success) {
      dyn.unload( file.path( libpath, "libs", paste( "rgl",
.Platform$dynlib.ext, sep="") ) )
      stop("error rgl_init")


If I suppress the line starting with Sys.putenv ("....
than I get the same error as you.
If I leave as it is, I simply cannot load the library.

More information about the R-SIG-Mac mailing list