Re: [R] Exporting an rgl graph

2010-04-29 Thread cgenolin

I need to use the function saveTriangleAsASY in my package. Does it allready
exist in a package or may I unclude it ?

Christophe
-- 
View this message in context: 
http://r.789695.n4.nabble.com/Exporting-an-rgl-graph-tp1872712p2075086.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.


Re: [R] Exporting an rgl graph

2010-04-20 Thread Christophe Genolini

Thanks a lot
Both Asymptote and  MeshLab work fine. Thanks for this article, Luke.
On my particular case, I need to export lines (1D object in a 3D space) 
and not surfaces (2D objects). Is it possible to draw lines with misc3d ?


Christophe Genolini

Luke Tierney a écrit :

  The current issue of JCGS (Vol 18 No 1,
http://pubs.amstat.org/toc/jcgs/19/1) has an editorial on including
animations, 3D visualizations, and movies in on-line PDF files
supporting JCGS articles. The online supplements to the editorial
include examples.  The 3D examples related to the misc3d packages are
also available in
http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/ 
http://www.stat.uiowa.edu/%7Eluke/R/misc3d/misc3d-pdf/.  At some point

the code there will be added to misc3d.  It should be possible to
adapt these ideas to other objects rendered with rgl.

luke


__
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.


Re: [R] Exporting an rgl graph

2010-04-20 Thread luke

On Fri, 16 Apr 2010, Michael Friendly wrote:


l...@stat.uiowa.edu wrote:

The current issue of JCGS (Vol 18 No 1,
http://pubs.amstat.org/toc/jcgs/19/1) has an editorial on including
animations, 3D visualizations, and movies in on-line PDF files
supporting JCGS articles. The online supplements to the editorial
include examples.  The 3D examples related to the misc3d packages are
also available in
http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
the code there will be added to misc3d.  It should be possible to
adapt these ideas to other objects rendered with rgl.

luke


Luke,
Your misc3d-pdf example is very instructive and the .tex file shows how
to embed in LaTeX.  Thanks! (JCGS 19(1) is actually one of the nicest
issues in a long time.)
Of the two approaches you
describe, the Asymptote route seems easier and more capable than the
MeshLab one.


The Asymptote/PRC route was the only one I could find (with a limited
amoutn of time and effort I could put in) that would support both
color and transparency.  The downside is that PRC suport requires very
new Adobe readers and seems to result in huge files. I know the U3D
format support color but MeshLab doesn't seem to put color into its
U3D exports.  I forget whether U3D supports transparency. Someone with
the energy and motivation to do so can read the binary file format
specs and write these file formats directly usign alltheir
cababilities, but I wasn't up to doing that at the time.

It would be particularly useful to have this capability available for rgl. 
Any plans for this?


Not on my part.  misc3d scenes are very simple -- just triangular mesh
objects with optional color or transparency. rgl handles much richer
scenes so figuring out how to translate such scenes to one of the
binary formats would be a lot more work. On the other hand it may
already have been done in the OpenGL community.



One note:  With Adobe Acrobat Pro 9.3.1, the U3D and PRC images display
on screen, but do not print (replaced by the filename).  Is this your
experience too?


I believe so.  There may well be a way of including a static image in
the LaTeX that would be used by printing and readers that don't
understand the embedded formats, but I haven't had the chance to check
the movie15 documentation for that.

luke



-Michael





--
Luke Tierney
Chair, Statistics and Actuarial Science
Ralph E. Wareham Professor of Mathematical Sciences
University of Iowa  Phone: 319-335-3386
Department of Statistics andFax:   319-335-3017
   Actuarial Science
241 Schaeffer Hall  email:  l...@stat.uiowa.edu
Iowa City, IA 52242 WWW:  http://www.stat.uiowa.edu

__
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.


Re: [R] Exporting an rgl graph

2010-04-20 Thread Duncan Murdoch

On 20/04/2010 10:43 AM, l...@stat.uiowa.edu wrote:

On Fri, 16 Apr 2010, Michael Friendly wrote:

 l...@stat.uiowa.edu wrote:
 The current issue of JCGS (Vol 18 No 1,
 http://pubs.amstat.org/toc/jcgs/19/1) has an editorial on including
 animations, 3D visualizations, and movies in on-line PDF files
 supporting JCGS articles. The online supplements to the editorial
 include examples.  The 3D examples related to the misc3d packages are
 also available in
 http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
 the code there will be added to misc3d.  It should be possible to
 adapt these ideas to other objects rendered with rgl.
 
 luke


 Luke,
 Your misc3d-pdf example is very instructive and the .tex file shows how
 to embed in LaTeX.  Thanks! (JCGS 19(1) is actually one of the nicest
 issues in a long time.)
 Of the two approaches you
 describe, the Asymptote route seems easier and more capable than the
 MeshLab one.

The Asymptote/PRC route was the only one I could find (with a limited
amoutn of time and effort I could put in) that would support both
color and transparency.  The downside is that PRC suport requires very
new Adobe readers and seems to result in huge files. I know the U3D
format support color but MeshLab doesn't seem to put color into its
U3D exports.  I forget whether U3D supports transparency. Someone with
the energy and motivation to do so can read the binary file format
specs and write these file formats directly usign alltheir
cababilities, but I wasn't up to doing that at the time.

 It would be particularly useful to have this capability available for rgl. 
 Any plans for this?


Not on my part.  misc3d scenes are very simple -- just triangular mesh
objects with optional color or transparency. rgl handles much richer
scenes so figuring out how to translate such scenes to one of the
binary formats would be a lot more work. On the other hand it may
already have been done in the OpenGL community.
  


It's on my wish list, but I'm spending too much time fighting to get my 
email working to actually work on anything.


The way the rgl.postcript conversion works (using the gl2ps library) is 
to redirect OpenGL calls into calls to generate Postscript.  Working at 
this level seems like the right approach, but I don't know if anyone has 
done it for these newer formats.


Duncan


 One note:  With Adobe Acrobat Pro 9.3.1, the U3D and PRC images display
 on screen, but do not print (replaced by the filename).  Is this your
 experience too?

I believe so.  There may well be a way of including a static image in
the LaTeX that would be used by printing and readers that don't
understand the embedded formats, but I haven't had the chance to check
the movie15 documentation for that.

luke


 -Michael







__
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.


Re: [R] Exporting an rgl graph

2010-04-16 Thread Michael Friendly

l...@stat.uiowa.edu wrote:

The current issue of JCGS (Vol 18 No 1,
http://pubs.amstat.org/toc/jcgs/19/1) has an editorial on including
animations, 3D visualizations, and movies in on-line PDF files
supporting JCGS articles. The online supplements to the editorial
include examples.  The 3D examples related to the misc3d packages are
also available in
http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
the code there will be added to misc3d.  It should be possible to
adapt these ideas to other objects rendered with rgl.

luke


Luke,
Your misc3d-pdf example is very instructive and the .tex file shows how
to embed in LaTeX.  Thanks! (JCGS 19(1) is actually one of the nicest
issues in a long time.)
Of the two approaches you
describe, the Asymptote route seems easier and more capable than the
MeshLab one.

It would be particularly useful to have this capability available for 
rgl.  Any plans for this?


One note:  With Adobe Acrobat Pro 9.3.1, the U3D and PRC images display
on screen, but do not print (replaced by the filename).  Is this your
experience too?

-Michael


--
Michael Friendly Email: friendly AT yorku DOT ca
Professor, Psychology Dept.
York University  Voice: 416 736-5115 x66249 Fax: 416 736-5814
4700 Keele Streethttp://www.math.yorku.ca/SCS/friendly.html
Toronto, ONT  M3J 1P3 CANADA

__
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.


Re: [R] Exporting an rgl graph

2010-04-16 Thread Greg Snow
The easiest approach may be to just install R onto a USB drive 
(flash/thumb/...) then when you go to your coworkers computer just run R from 
the USB drive and show the rgl plot.  I think there is also a tool to create an 
animation from rgl, it is not interactive, but you could e-mail a movie file 
that they could play to see the plot from many angles.

-- 
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.s...@imail.org
801.408.8111


 -Original Message-
 From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-
 project.org] On Behalf Of cgeno...@u-paris10.fr
 Sent: Thursday, April 15, 2010 6:02 AM
 To: ted.hard...@manchester.ac.uk; Barry Rowlingson
 Cc: r-help@r-project.org
 Subject: Re: [R] Exporting an rgl graph
 
 Thanks for you answer. Let me precise my question.
 
 In fact, I do not want to capture a screen, I want to save an object
 that can be seen in 3D. With rgl, using my mouse, I can make the object
 move. This is what I want to export: an real 3D object that my
 collaborator will have the possibility to see in 3D.
 
 Christophe
 
 
  On 15-Apr-10 10:10:54, Barry Rowlingson wrote:
  On Thu, Apr 15, 2010 at 10:24 AM,  cgeno...@u-paris10.fr wrote:
  Hi the list,
 
  I use rgl to produce a 3D graph. I would like to show this graph
  to some collaborator. Is there a way to save it and send it to
  someone else?
 
  See ?rgl.postscript and ?rgl.snapshot
 
   Or use some kind of screen capture system - on Windows the 'Print
  Screen' key can copy the screen to the clipboard, paste into
 Photoshop
  or other graphics program.
 
   On Linux, I use 'scrot' from the command line - type 'scrot -s',
  click on a window, and it makes a PNG file of it.
 
  Again on Linux, since ImageMagick is installed, I use the 'import'
  programme from that suite. When you start that, it produces a
  +-shaped mouse cursor which you can use (selecting a top-left-hand
  corner to start with, and holding down the left mouse button) to
  drag out a bounding frame for the part of the screen you want to
  save. Then, when you release the button, an image of that portion
  of the screen is saved to a file of your choice, in any graphics
  format of your choice that is supported by ImageMagick (including
  PS and EPS, as well as all the common butmap formats).
 
  See 'man import' for pointers to more information.
 
  I have this set up as an icon on my launch panel, so it is just
  a matter of clicking on that, and then doing the above. The command
  behind the icon is
 
   /usr/local/bin/mkscreengrab
 
  and my script file 'mkscreengrab' contains:
 
   #! /bin/bash
   export ScrGrbTmp=`mktemp /home/ted/Screengrabs/screengrab`
   import $ScrGrbTmp.jpg
   rm $ScrGrbTmp
 
  so this makes JPEGs (I could have chosen somthing else, but that's
  the default I mostly want for that activity). This produces a file
  with a name like screengrab4913.jpg which will be unique in that
  directory, and it can later be renamed to your taste.
 
  If I wanted a different file format, I would use 'import' from
  the command line, with appropriate filenam extension (e.g. .png,
  .ps, .eps, ... ).
 
  I hadn't heard of scrot before, but now I've looked it up it
  seems that its output format is limited to PNG.
 
  I've now also located more info about various ways of taking
  screenshots in Linux:
 
  http://tips.webdesign10.com/how-to-take-a-screenshot-on-ubuntu-linux
 
  Ted.
 
  
  E-Mail: (Ted Harding) ted.hard...@manchester.ac.uk
  Fax-to-email: +44 (0)870 094 0861
  Date: 15-Apr-10   Time: 12:18:25
  -- XFMail --
 
 
 __
 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.

__
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.


[R] Exporting an rgl graph

2010-04-15 Thread cgenolin

Hi the list,

I use rgl to produce a 3D graph. I would like to show this graph to 
some collaborator. Is there a way to save it and send it to someone 
else?


Christophe Genolini

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread Barry Rowlingson
On Thu, Apr 15, 2010 at 10:24 AM,  cgeno...@u-paris10.fr wrote:
 Hi the list,

 I use rgl to produce a 3D graph. I would like to show this graph to some
 collaborator. Is there a way to save it and send it to someone else?

See ?rgl.postscript and ?rgl.snapshot

 Or use some kind of screen capture system - on Windows the 'Print
Screen' key can copy the screen to the clipboard, paste into Photoshop
or other graphics program.

 On Linux, I use 'scrot' from the command line - type 'scrot -s',
click on a window, and it makes a PNG file of it.

-- 
blog: http://geospaced.blogspot.com/
web: http://www.maths.lancs.ac.uk/~rowlings
web: http://www.rowlingson.com/
twitter: http://twitter.com/geospacedman
pics: http://www.flickr.com/photos/spacedman

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread Ted Harding
On 15-Apr-10 10:10:54, Barry Rowlingson wrote:
 On Thu, Apr 15, 2010 at 10:24 AM,  cgeno...@u-paris10.fr wrote:
 Hi the list,

 I use rgl to produce a 3D graph. I would like to show this graph
 to some collaborator. Is there a way to save it and send it to
 someone else?
 
 See ?rgl.postscript and ?rgl.snapshot
 
  Or use some kind of screen capture system - on Windows the 'Print
 Screen' key can copy the screen to the clipboard, paste into Photoshop
 or other graphics program.
 
  On Linux, I use 'scrot' from the command line - type 'scrot -s',
 click on a window, and it makes a PNG file of it.

Again on Linux, since ImageMagick is installed, I use the 'import'
programme from that suite. When you start that, it produces a
+-shaped mouse cursor which you can use (selecting a top-left-hand
corner to start with, and holding down the left mouse button) to
drag out a bounding frame for the part of the screen you want to
save. Then, when you release the button, an image of that portion
of the screen is saved to a file of your choice, in any graphics
format of your choice that is supported by ImageMagick (including
PS and EPS, as well as all the common butmap formats).

See 'man import' for pointers to more information.

I have this set up as an icon on my launch panel, so it is just
a matter of clicking on that, and then doing the above. The command
behind the icon is

  /usr/local/bin/mkscreengrab

and my script file 'mkscreengrab' contains:

  #! /bin/bash
  export ScrGrbTmp=`mktemp /home/ted/Screengrabs/screengrab`
  import $ScrGrbTmp.jpg
  rm $ScrGrbTmp

so this makes JPEGs (I could have chosen somthing else, but that's
the default I mostly want for that activity). This produces a file
with a name like screengrab4913.jpg which will be unique in that
directory, and it can later be renamed to your taste.

If I wanted a different file format, I would use 'import' from
the command line, with appropriate filenam extension (e.g. .png,
.ps, .eps, ... ).

I hadn't heard of scrot before, but now I've looked it up it
seems that its output format is limited to PNG.

I've now also located more info about various ways of taking
screenshots in Linux:

http://tips.webdesign10.com/how-to-take-a-screenshot-on-ubuntu-linux

Ted.


E-Mail: (Ted Harding) ted.hard...@manchester.ac.uk
Fax-to-email: +44 (0)870 094 0861
Date: 15-Apr-10   Time: 12:18:25
-- XFMail --

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread cgenolin

Thanks for you answer. Let me precise my question.

In fact, I do not want to capture a screen, I want to save an object 
that can be seen in 3D. With rgl, using my mouse, I can make the object 
move. This is what I want to export: an real 3D object that my 
collaborator will have the possibility to see in 3D.


Christophe



On 15-Apr-10 10:10:54, Barry Rowlingson wrote:

On Thu, Apr 15, 2010 at 10:24 AM,  cgeno...@u-paris10.fr wrote:

Hi the list,

I use rgl to produce a 3D graph. I would like to show this graph
to some collaborator. Is there a way to save it and send it to
someone else?


See ?rgl.postscript and ?rgl.snapshot

 Or use some kind of screen capture system - on Windows the 'Print
Screen' key can copy the screen to the clipboard, paste into Photoshop
or other graphics program.

 On Linux, I use 'scrot' from the command line - type 'scrot -s',
click on a window, and it makes a PNG file of it.


Again on Linux, since ImageMagick is installed, I use the 'import'
programme from that suite. When you start that, it produces a
+-shaped mouse cursor which you can use (selecting a top-left-hand
corner to start with, and holding down the left mouse button) to
drag out a bounding frame for the part of the screen you want to
save. Then, when you release the button, an image of that portion
of the screen is saved to a file of your choice, in any graphics
format of your choice that is supported by ImageMagick (including
PS and EPS, as well as all the common butmap formats).

See 'man import' for pointers to more information.

I have this set up as an icon on my launch panel, so it is just
a matter of clicking on that, and then doing the above. The command
behind the icon is

 /usr/local/bin/mkscreengrab

and my script file 'mkscreengrab' contains:

 #! /bin/bash
 export ScrGrbTmp=`mktemp /home/ted/Screengrabs/screengrab`
 import $ScrGrbTmp.jpg
 rm $ScrGrbTmp

so this makes JPEGs (I could have chosen somthing else, but that's
the default I mostly want for that activity). This produces a file
with a name like screengrab4913.jpg which will be unique in that
directory, and it can later be renamed to your taste.

If I wanted a different file format, I would use 'import' from
the command line, with appropriate filenam extension (e.g. .png,
.ps, .eps, ... ).

I hadn't heard of scrot before, but now I've looked it up it
seems that its output format is limited to PNG.

I've now also located more info about various ways of taking
screenshots in Linux:

http://tips.webdesign10.com/how-to-take-a-screenshot-on-ubuntu-linux

Ted.


E-Mail: (Ted Harding) ted.hard...@manchester.ac.uk
Fax-to-email: +44 (0)870 094 0861
Date: 15-Apr-10   Time: 12:18:25
-- XFMail --



__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread Barry Rowlingson
On Thu, Apr 15, 2010 at 1:01 PM,  cgeno...@u-paris10.fr wrote:
 Thanks for you answer. Let me precise my question.

 In fact, I do not want to capture a screen, I want to save an object that
 can be seen in 3D. With rgl, using my mouse, I can make the object move.
 This is what I want to export: an real 3D object that my collaborator will
 have the possibility to see in 3D.


 You mean without them having to install R and rgl and run the code
that produces your graphic?

 I guess you could somehow export a VRML or some other 3d file:

 http://en.wikipedia.org/wiki/VRML

 but I suspect of all the billions of people on the planet only Duncan
Murdoch knows enough about rgl to figure that one out...

 The person at the other end would still need a VRML viewer. Just get
them to install R.

Barry

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread baptiste auguie
I have seen pdf files with 3D objects embedded in it, using the U3D format,
http://en.wikipedia.org/wiki/Universal_3D

but I don't think there's a device for this in R; in fact there may
not even exist a third-party post-processing route available at this
time to bridge the gap between rgl and this format. It sure would be
nice, though.

Best,

baptiste



On 15 April 2010 14:12, Barry Rowlingson b.rowling...@lancaster.ac.uk wrote:
 On Thu, Apr 15, 2010 at 1:01 PM,  cgeno...@u-paris10.fr wrote:
 Thanks for you answer. Let me precise my question.

 In fact, I do not want to capture a screen, I want to save an object that
 can be seen in 3D. With rgl, using my mouse, I can make the object move.
 This is what I want to export: an real 3D object that my collaborator will
 have the possibility to see in 3D.


  You mean without them having to install R and rgl and run the code
 that produces your graphic?

  I guess you could somehow export a VRML or some other 3d file:

  http://en.wikipedia.org/wiki/VRML

  but I suspect of all the billions of people on the planet only Duncan
 Murdoch knows enough about rgl to figure that one out...

  The person at the other end would still need a VRML viewer. Just get
 them to install R.

 Barry

 __
 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.


__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread Ted Harding
On 15-Apr-10 12:33:11, baptiste auguie wrote:
 I have seen pdf files with 3D objects embedded in it, using the U3D
 format,
 http://en.wikipedia.org/wiki/Universal_3D

At the bottom of that page is a link to a very nice example:

  http://meshlab.sourceforge.net/wiki/images/c/cc/Laurana.pdf

Embedding interactive 3D object in a PDF using MeshLab and U3D,
 Visual Computing Group. ISTI CNR. Example of an embedded U3D in a pdf.

Nice to play with! (With the mouse cursor over her, hold down the
button, and move around). According to the caption at the bottom:

  This pdf was produced with open source tools. The object
   was converted in the pdf-ready U3D format with MeshLab
   ( http://meshlab.sourceforge.net ) and assembled in a pdf
   with pdfLATEX and the movie15 package.

I think there may be some scope here!
Ted.


 but I don't think there's a device for this in R; in fact there may
 not even exist a third-party post-processing route available at this
 time to bridge the gap between rgl and this format. It sure would be
 nice, though.
 
 Best,
 
 baptiste
 
 
 
 On 15 April 2010 14:12, Barry Rowlingson b.rowling...@lancaster.ac.uk
 wrote:
 On Thu, Apr 15, 2010 at 1:01 PM, _cgeno...@u-paris10.fr wrote:
 Thanks for you answer. Let me precise my question.

 In fact, I do not want to capture a screen, I want to save an
 object that
 can be seen in 3D. With rgl, using my mouse, I can make the object
 move.
 This is what I want to export: an real 3D object that my collaborator
 will
 have the possibility to see in 3D.


 _You mean without them having to install R and rgl and run the code
 that produces your graphic?

 _I guess you could somehow export a VRML or some other 3d file:

 _http://en.wikipedia.org/wiki/VRML

 _but I suspect of all the billions of people on the planet only Duncan
 Murdoch knows enough about rgl to figure that one out...

 _The person at the other end would still need a VRML viewer. Just get
 them to install R.

 Barry

 __
 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.

 
 __
 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.


E-Mail: (Ted Harding) ted.hard...@manchester.ac.uk
Fax-to-email: +44 (0)870 094 0861
Date: 15-Apr-10   Time: 13:54:02
-- XFMail --

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread luke

The current issue of JCGS (Vol 18 No 1,
http://pubs.amstat.org/toc/jcgs/19/1) has an editorial on including
animations, 3D visualizations, and movies in on-line PDF files
supporting JCGS articles. The online supplements to the editorial
include examples.  The 3D examples related to the misc3d packages are
also available in
http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
the code there will be added to misc3d.  It should be possible to
adapt these ideas to other objects rendered with rgl.

luke


On Thu, 15 Apr 2010, baptiste auguie wrote:


I have seen pdf files with 3D objects embedded in it, using the U3D format,
http://en.wikipedia.org/wiki/Universal_3D

but I don't think there's a device for this in R; in fact there may
not even exist a third-party post-processing route available at this
time to bridge the gap between rgl and this format. It sure would be
nice, though.

Best,

baptiste



On 15 April 2010 14:12, Barry Rowlingson b.rowling...@lancaster.ac.uk wrote:

On Thu, Apr 15, 2010 at 1:01 PM,  cgeno...@u-paris10.fr wrote:

Thanks for you answer. Let me precise my question.

In fact, I do not want to capture a screen, I want to save an object that
can be seen in 3D. With rgl, using my mouse, I can make the object move.
This is what I want to export: an real 3D object that my collaborator will
have the possibility to see in 3D.



 You mean without them having to install R and rgl and run the code
that produces your graphic?

 I guess you could somehow export a VRML or some other 3d file:

 http://en.wikipedia.org/wiki/VRML

 but I suspect of all the billions of people on the planet only Duncan
Murdoch knows enough about rgl to figure that one out...

 The person at the other end would still need a VRML viewer. Just get
them to install R.

Barry

__
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.



__
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.



--
Luke Tierney
Chair, Statistics and Actuarial Science
Ralph E. Wareham Professor of Mathematical Sciences
University of Iowa  Phone: 319-335-3386
Department of Statistics andFax:   319-335-3017
   Actuarial Science
241 Schaeffer Hall  email:  l...@stat.uiowa.edu
Iowa City, IA 52242 WWW:  http://www.stat.uiowa.edu__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread David Winsemius


On Apr 15, 2010, at 12:34 PM, l...@stat.uiowa.edu wrote:


The current issue of JCGS (Vol 18 No 1,
http://pubs.amstat.org/toc/jcgs/19/1 ) has an editorial on including
animations, 3D visualizations, and movies in on-line PDF files
supporting JCGS articles. The online supplements to the editorial
include examples.  The 3D examples related to the misc3d packages are
also available in
http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
the code there will be added to misc3d.  It should be possible to
adapt these ideas to other objects rendered with rgl.


Very kewl. On a Mac the greyscale plots opened in Adobe Acrobat Reader  
v8.2.2 displays properly, but the color version supp_j.pdf looks like  
a ménage à trois of three psychedelic sea urchins. I think that Adobe  
may need to do some work on their display engine for this to be a  
fully cross-platform combination. The color version of the volcano  
example is likewise carpeted with spiky artifacts.


(I have not yet tried producing plots de novo with the Mac pdf device.)

--
David.


luke


On Thu, 15 Apr 2010, baptiste auguie wrote:

I have seen pdf files with 3D objects embedded in it, using the U3D  
format,

http://en.wikipedia.org/wiki/Universal_3D

but I don't think there's a device for this in R; in fact there may
not even exist a third-party post-processing route available at this
time to bridge the gap between rgl and this format. It sure would be
nice, though.

Best,

baptiste

On 15 April 2010 14:12, Barry Rowlingson b.rowling...@lancaster.ac.uk 
 wrote:

On Thu, Apr 15, 2010 at 1:01 PM,  cgeno...@u-paris10.fr wrote:

Thanks for you answer. Let me precise my question.

In fact, I do not want to capture a screen, I want to save an  
object that
can be seen in 3D. With rgl, using my mouse, I can make the  
object move.
This is what I want to export: an real 3D object that my  
collaborator will

have the possibility to see in 3D.



 You mean without them having to install R and rgl and run the code
that produces your graphic?

 I guess you could somehow export a VRML or some other 3d file:

 http://en.wikipedia.org/wiki/VRML

 but I suspect of all the billions of people on the planet only  
Duncan

Murdoch knows enough about rgl to figure that one out...

 The person at the other end would still need a VRML viewer. Just  
get

them to install R.

Barry




--
Luke Tierney
Chair, Statistics and Actuarial Science



David Winsemius, MD
West Hartford, CT

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread Gavin Simpson
On Thu, 2010-04-15 at 13:00 -0400, David Winsemius wrote:
 On Apr 15, 2010, at 12:34 PM, l...@stat.uiowa.edu wrote:
 
  The current issue of JCGS (Vol 18 No 1,
  http://pubs.amstat.org/toc/jcgs/19/1 ) has an editorial on including
  animations, 3D visualizations, and movies in on-line PDF files
  supporting JCGS articles. The online supplements to the editorial
  include examples.  The 3D examples related to the misc3d packages are
  also available in
  http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
  the code there will be added to misc3d.  It should be possible to
  adapt these ideas to other objects rendered with rgl.
 
 Very kewl. On a Mac the greyscale plots opened in Adobe Acrobat Reader  
 v8.2.2 displays properly, but the color version supp_j.pdf looks like  
 a ménage à trois of three psychedelic sea urchins. I think that Adobe  
 may need to do some work on their display engine for this to be a  
 fully cross-platform combination. The color version of the volcano  
 example is likewise carpeted with spiky artifacts.
 
 (I have not yet tried producing plots de novo with the Mac pdf device.)
 

Have you tried in Acrobat Reader =9 ? The editorial says you need that
to view the pdfs properly.

G


-- 
%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%
 Dr. Gavin Simpson [t] +44 (0)20 7679 0522
 ECRC, UCL Geography,  [f] +44 (0)20 7679 0565
 Pearson Building, [e] gavin.simpsonATNOSPAMucl.ac.uk
 Gower Street, London  [w] http://www.ucl.ac.uk/~ucfagls/
 UK. WC1E 6BT. [w] http://www.freshwaters.org.uk
%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread baptiste auguie
On 15 April 2010 18:34,  l...@stat.uiowa.edu wrote:
 The current issue of JCGS (Vol 18 No 1,
 http://pubs.amstat.org/toc/jcgs/19/1) has an editorial on including
 animations, 3D visualizations, and movies in on-line PDF files
 supporting JCGS articles. The online supplements to the editorial
 include examples.  The 3D examples related to the misc3d packages are
 also available in
 http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
 the code there will be added to misc3d.  It should be possible to
 adapt these ideas to other objects rendered with rgl.

 luke


 On Thu, 15 Apr 2010, baptiste auguie wrote:

 I have seen pdf files with 3D objects embedded in it, using the U3D
 format,
 http://en.wikipedia.org/wiki/Universal_3D

 but I don't think there's a device for this in R; in fact there may
 not even exist a third-party post-processing route available at this
 time to bridge the gap between rgl and this format. It sure would be
 nice, though.

Very glad to be proven wrong!

Thanks,

baptiste

__
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.


Re: [R] Exporting an rgl graph

2010-04-15 Thread David Winsemius


On Apr 15, 2010, at 1:52 PM, Gavin Simpson wrote:


On Thu, 2010-04-15 at 13:00 -0400, David Winsemius wrote:

On Apr 15, 2010, at 12:34 PM, l...@stat.uiowa.edu wrote:


The current issue of JCGS (Vol 18 No 1,
http://pubs.amstat.org/toc/jcgs/19/1 ) has an editorial on including
animations, 3D visualizations, and movies in on-line PDF files
supporting JCGS articles. The online supplements to the editorial
include examples.  The 3D examples related to the misc3d packages  
are

also available in
http://www.stat.uiowa.edu/~luke/R/misc3d/misc3d-pdf/.  At some point
the code there will be added to misc3d.  It should be possible to
adapt these ideas to other objects rendered with rgl.


Very kewl. On a Mac the greyscale plots opened in Adobe Acrobat  
Reader

v8.2.2 displays properly, but the color version supp_j.pdf looks like
a ménage à trois of three psychedelic sea urchins. I think that Adobe
may need to do some work on their display engine for this to be a
fully cross-platform combination. The color version of the volcano
example is likewise carpeted with spiky artifacts.

(I have not yet tried producing plots de novo with the Mac pdf  
device.)




Have you tried in Acrobat Reader =9 ? The editorial says you need  
that

to view the pdfs properly.


Thank you, that was it. I thought that my version of Acrobat Reader  
was current for my OS, but it was not. Acrobat 9.3 for the Mac renders  
the plots correctly. Now I get quite lovely orientable images.




G

--
%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%
Dr. Gavin Simpson [t] +44 (0)20 7679 0522
ECRC, UCL Geography,  [f] +44 (0)20 7679 0565-


--
David Winsemius, MD
West Hartford, CT

__
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.