[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #54797] getframe fails with consecutive figure
From: |
Juan Pablo Carbajal |
Subject: |
[Octave-bug-tracker] [bug #54797] getframe fails with consecutive figures |
Date: |
Sat, 6 Oct 2018 08:28:32 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:62.0) Gecko/20100101 Firefox/62.0 |
URL:
<https://savannah.gnu.org/bugs/?54797>
Summary: getframe fails with consecutive figures
Project: GNU Octave
Submitted by: juanpi
Submitted on: Sat 06 Oct 2018 12:28:30 PM UTC
Category: Plotting
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Unexpected Error
Status: Confirmed
Assigned to: None
Originator Name: juanpi
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: dev
Operating System: GNU/Linux
_______________________________________________________
Details:
The following code
n = 10000;
for i=1:4
figure(i)
plot (randn(n,1), randn(n,1), '.')
endfor
for i=1:4
figure(i)
set (gcf, 'units', 'normalized', 'position', [0 0 0.9 0.9]);
drawnow
imwrite (frame2im (getframe (gcf)), sprintf("/tmp/tstfig-%d.png", i));
endfor
gives
warning: called from
getframe at line 102 column 11
warning: opengl_renderer: Error 'invalid value' (1281) occurred
drawing 'line' object
and the images are empty.
Pantxo found a workaround by modifying the figure resize command to
set (gcf, 'units', 'normalized', 'position', [0 0 0.9 0.9],
'units','pixels');
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?54797>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #54797] getframe fails with consecutive figures,
Juan Pablo Carbajal <=