[R-SIG-Mac] rgl crashes after one successful draw on R.app
Prof Brian Ripley
ripley at stats.ox.ac.uk
Thu May 30 10:05:05 CEST 2013
On 30/05/2013 02:27, Bryan Hanson wrote:
> Unfortunately, I already have XQuartz 2.7.4 and it gives the problem I reported. :-( Bryan
But as I said way back in this thread, there are two different rgl
devices and this trhead has conflated two problems, on in each.
Roger was using the X11-based version, and that seemed to be an Xquartz
issue.
You are using the AGL-based version in R.app, which does not use X11 AFAIK.
> On May 29, 2013, at 7:16 PM, Robert J Goedman <goedman at icloud.com> wrote:
>
>> Great, like with Rcmdr, example(rgl) seems to work well.
>>
>> Repeatedly just 'example(plot3d)' and each time removing all rgl windows, will lead to the same problem Bryan mentioned this morning.
>>
>> Rob J. Goedman
>> goedman at icloud.com
>>
>>
>>
>>
>> On May 29, 2013, at 3:57 PM, Roger Koenker <rkoenker at illinois.edu> wrote:
>>
>>> Rob,
>>>
>>> Well, that was easy.... I upgraded to XQuartz 2.7.4 and now can run example(rgl)
>>> and also close the windows that are created. ;-). Many thanks!
>>>
>>> Roger
>>>
>>> url: www.econ.uiuc.edu/~roger Roger Koenker
>>> email rkoenker at uiuc.edu Department of Economics
>>> vox: 217-333-4558 University of Illinois
>>> fax: 217-244-6678 Urbana, IL 61801
>>>
>>> On May 29, 2013, at 5:41 PM, Robert J Goedman wrote:
>>>
>>>> Roger,
>>>>
>>>> Not sure if that would fix it, but my system is the patched R.3.0.1, using XQuartz 2.7.4 and a slightly newer version of rgl (rgl_0.93.940).
>>>>
>>>> Rob J. Goedman
>>>> goedman at icloud.com
>>>>
>>>>
>>>>
>>>>
>>>> On May 29, 2013, at 3:19 PM, Roger Koenker <rkoenker at illinois.edu> wrote:
>>>>
>>>>> no, I never get a window.... I get an immediate segfault as soon as
>>>>> rgl.open() is called.
>>>>>
>>>>>
>>>>> url: www.econ.uiuc.edu/~roger Roger Koenker
>>>>> email rkoenker at uiuc.edu Department of Economics
>>>>> vox: 217-333-4558 University of Illinois
>>>>> fax: 217-244-6678 Urbana, IL 61801
>>>>>
>>>>> On May 29, 2013, at 5:17 PM, Robert J Goedman wrote:
>>>>>
>>>>>> Roger,
>>>>>>
>>>>>> Do you ever see an rgl window pop-up? Just wondering if this is the same issue.
>>>>>>
>>>>>> Rob J. Goedman
>>>>>> goedman at icloud.com
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On May 29, 2013, at 2:49 PM, Roger Koenker <rkoenker at illinois.edu> wrote:
>>>>>>
>>>>>>> I doubt that this is helpful, but I get:
>>>>>>>
>>>>>>>> rgl.open()
>>>>>>> Reading symbols for shared libraries . done
>>>>>>>
>>>>>>> Program received signal EXC_BAD_ACCESS, Could not access memory.
>>>>>>> Reason: KERN_INVALID_ADDRESS at address: 0x00000000000000e8
>>>>>>> 0x0000000102e31a90 in gui::X11GUIFactory::createWindowImpl (this=0x1006871d0,
>>>>>>> window=0x7fff5fbfd330) at x11gui.cpp:612
>>>>>>> 612 ::Window xparent = RootWindow(xdisplay, DefaultScreen(xdisplay));
>>>>>>> (gdb) Quit
>>>>>>>
>>>>>>> url: www.econ.uiuc.edu/~roger Roger Koenker
>>>>>>> email rkoenker at uiuc.edu Department of Economics
>>>>>>> vox: 217-333-4558 University of Illinois
>>>>>>> fax: 217-244-6678 Urbana, IL 61801
>>>>>>>
>>>>>>> On May 29, 2013, at 4:37 PM, Duncan Murdoch wrote:
>>>>>>>
>>>>>>>> On 13-05-29 11:19 AM, Bryan Hanson wrote:
>>>>>>>>> [originally on R-help, reposted here as the most relevent place]
>>>>>>>>>
>>>>>>>>> NOTE: problem is with R.app, looks OK on command line R
>>>>>>>>>
>>>>>>>>> This is really odd, and probably 100% local to me, but I'm at a loss as to a next step.
>>>>>>>>>
>>>>>>>>> After narrowing things down, here's how to reproduce:
>>>>>>>>
>>>>>>>> I don't see it, but it looks to me like it may be a timing problem. I'm
>>>>>>>> guessing the destruction of the old window triggers events in the wrong
>>>>>>>> order and leaves rgl in an unstable state. Unfortunately, without being
>>>>>>>> able to reproduce this, it looks really hard to track down. Can anyone
>>>>>>>> reproduce it while running in gdb or some other debugger?
>>>>>>>>
>>>>>>>> Duncan Murdoch
>>>>>>>>
>>>>>>>>>
>>>>>>>>> library("rgl")
>>>>>>>>> showSomething <- function() {
>>>>>>>>> open3d()
>>>>>>>>> points3d(rnorm(10),rnorm(10),rnorm(10))
>>>>>>>>> axes3d()
>>>>>>>>> title3d('main','sub','xlab','ylab','zlab')
>>>>>>>>> }
>>>>>>>>> showSomething() # works as expected.
>>>>>>>>> # Close the current rgl window
>>>>>>>>> showSomething() # crashes R with the following report:
>>>>>>>>>
>>>>>>>>> *** caught segfault ***
>>>>>>>>> address 0x0, cause 'unknown'
>>>>>>>>>
>>>>>>>>> Traceback:
>>>>>>>>> 1: .C(rgl_dev_open, success = FALSE)
>>>>>>>>> 2: rgl.open()
>>>>>>>>> 3: open3d()
>>>>>>>>> 4: showSomething()
>>>>>>>>>
>>>>>>>>> This will probably work fine for any of you, it's so simple and fundamental. If I don't close the open rgl windows, it doesn't crash, and I can execute the function over and over successfully. And the same thing happens if I just do the commands inside the function individually. SessionInfo() below.
>>>>>>>>>
>>>>>>>>> Perhaps something is corrupt with my X11 window system? Thanks, Bryan
>>>>>>>>>
>>>>>>>>> R version 3.0.1 (2013-05-16)
>>>>>>>>> Platform: x86_64-apple-darwin10.8.0 (64-bit)
>>>>>>>>>
>>>>>>>>> locale:
>>>>>>>>> [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
>>>>>>>>>
>>>>>>>>> attached base packages:
>>>>>>>>> [1] stats graphics grDevices utils datasets methods base
>>>>>>>>>
>>>>>>>>> other attached packages:
>>>>>>>>> [1] rgl_0.93.940 sos_1.3-5 brew_1.0-6
>>>>>>>>> _______________________________________________
>>>>>>>>> R-SIG-Mac mailing list
>>>>>>>>> R-SIG-Mac at r-project.org
>>>>>>>>> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>>>>>>>>>
>>>>>>>>
>>>>>>>> _______________________________________________
>>>>>>>> R-SIG-Mac mailing list
>>>>>>>> R-SIG-Mac at r-project.org
>>>>>>>> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> R-SIG-Mac mailing list
>>>>>>> R-SIG-Mac at r-project.org
>>>>>>> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>>>>>>
>>>>>
>>>>
>>>
>>
>>
>> [[alternative HTML version deleted]]
>>
>> _______________________________________________
>> R-SIG-Mac mailing list
>> R-SIG-Mac at r-project.org
>> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-SIG-Mac
mailing list