[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #52413] Qt5 figures background first appears b
From: |
Pantxo Diribarne |
Subject: |
[Octave-bug-tracker] [bug #52413] Qt5 figures background first appears black or transparent |
Date: |
Wed, 15 Nov 2017 05:42:17 -0500 (EST) |
User-agent: |
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:56.0) Gecko/20100101 Firefox/56.0 |
URL:
<http://savannah.gnu.org/bugs/?52413>
Summary: Qt5 figures background first appears black or
transparent
Project: GNU Octave
Submitted by: pantxo
Submitted on: Wed 15 Nov 2017 10:42:16 AM UTC
Category: Plotting with OpenGL
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Regression
Status: None
Assigned to: None
Originator Name:
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: dev
Operating System: GNU/Linux
_______________________________________________________
Details:
The title says it all:
close all;
figure ()
## the figure has a transparent background
close all
plot (1:10)
## the figure has a black background until a paint event is forced by e.g.
switching window with Alt+Tab
I am using nouveau driver with an intel integrated graphics card on linux mint
17.3
I can get rid of this behavior using the following hack:
diff -r f3d754deb41d libinterp/corefcn/gl-render.cc
--- a/libinterp/corefcn/gl-render.cc Wed Nov 08 16:34:23 2017 +0100
+++ b/libinterp/corefcn/gl-render.cc Wed Nov 15 11:31:06 2017 +0100
@@ -829,7 +829,13 @@
if (c.numel () >= 3)
{
- glClearColor (c(0), c(1), c(2), 1);
+ glClearColor (c(0), c(1), c(2), 1.0F);
+ // FIXME: hack to have the first glClear work even when nothing has
+ // been drawn.
+ glBegin (GL_LINES);
+ glVertex2d (-1.0, -1.0);
+ glVertex2d (1.0, -1.0);
+ glEnd ();
glClear (GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?52413>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #52413] Qt5 figures background first appears black or transparent,
Pantxo Diribarne <=