Comments (13)
I've added some debug information, please could you check what the latest version (0.8.3) prints when run in a terminal?
from plots.
This is what I'm getting:
$ flatpak run app/com.github.alexhuntley.Plots/x86_64/master
OpenGL version: 3.2
from plots.
Looks like you aren't using OpenGL ES then.
So either I could lower the minimum version for the warning (assuming the app still works for you?), or remove it completely. I imagine on GTK 4 it's safe to assume we have a relatively modern OpenGL.
from plots.
So either I could lower the minimum version for the warning (assuming the app still works for you?)
It still works as far as I can tell
or remove it completely. I imagine on GTK 4 it's safe to assume we have a relatively modern OpenGL.
Not necessarily. GTK 4 supports OpenGL ES 2.0 as its minimum. Not sure about "desktop" OpenGL.
from plots.
It seems like OpenGL 3.0 is the lowest "legacy" OpenGL version GTK 4 tries to pick (not sure what legacy means), OpenGL 3.2 is the lowest OpenGL version it tries to pick, and OpenGL ES 2.0 is the lowest OpenGL ES version: https://gitlab.gnome.org/GNOME/gtk/-/blob/cefb0a3eb8f9a52283ce4368ccc78425db0914b0/gdk/gdkglcontextprivate.h#L36-50
from plots.
Okay, so I tried building GTK with this stupid patch applied: 4.6-required-opengl.patch.txt
And after applying this, lo and behold:
$ flatpak run app/com.github.alexhuntley.Plots/x86_64/master
OpenGL version: 4.6
As well as no warning in Plots:
So I guess GTK just picks the lowest supported non-legacy version on my system. I really wonder why it wouldn't do this on other systems.
from plots.
Very interesting. Presumably it's due to some quirk in the NVIDIA driver.
So I need to look into whether Plots really needs 3.3, or whether a lower version would be acceptable.
We could also try using GLArea.set_required_version
to request a more recent context. What happens if you add a call to it in GraphArea.__init__
in graph.py
? (with the unpatched GTK)
from plots.
Does this look like what you had in mind:
diff --git a/plots/graph.py b/plots/graph.py
index 9605bdb..2243584 100644
--- a/plots/graph.py
+++ b/plots/graph.py
@@ -35,6 +35,7 @@ class GraphArea(Gtk.GLArea):
def __init__(self):
super().__init__()
+ self.set_required_version(3, 3)
self.scale = self._target_scale = self.INIT_SCALE
self._translation = np.array([0, 0], 'f')
self.vertex_template = jinja_env.get_template('vertex.glsl')
It does not seem to help unfortunately:
$ python3 -m plots
OpenGL version: 3.2
from plots.
That's surprising. What if you request 4.6?
from plots.
That's surprising. What if you request 4.6?
Same result. Could it be that it has no affect since the Area already is realised when this is called?
from plots.
It's possible. Try printing self.get_realized()
?
from plots.
diff --git a/plots/graph.py b/plots/graph.py
index 9605bdb..ec0d499 100644
--- a/plots/graph.py
+++ b/plots/graph.py
@@ -35,6 +35,8 @@ class GraphArea(Gtk.GLArea):
def __init__(self):
super().__init__()
+ self.set_required_version(4, 6)
+ print(self.get_realized())
self.scale = self._target_scale = self.INIT_SCALE
self._translation = np.array([0, 0], 'f')
self.vertex_template = jinja_env.get_template('vertex.glsl')
$ python3 -m plots
False
OpenGL version: 3.2
So I guess it isn't realised when this happens. Wonder what it could be then.
from plots.
I'm getting this issue myself on ubuntu (22.10) using the flatpak install.
Anyone know the fix?
OpenGL version string: 4.6.0 NVIDIA 530.41.03
this an nwidia probwem?
from plots.
Related Issues (20)
- Snap package ready
- Complex or Imaginary plane HOT 1
- GNOME 42 runtime is no longer supported HOT 1
- plots crashes on startup HOT 4
- Plots does not launch on Gnome 44.1 (when installed via the AUR) HOT 2
- some strings are not translatable HOT 2
- 3d graphs HOT 2
- Sidebar: nicer button styling HOT 2
- Port to new About window HOT 1
- Close with Ctrl+Q
- Tests broken since 0.8.0
- Asahi Linux Support (OpenGL 3.1-ish)
- Feature request: indicate missing value for parameter, allow defining different sets of parameters per function
- Feature Request: Allow limiting zooming to certain direction
- Crash on start due to not supported locale HOT 1
- Hebrew text in English description
- Plotting section completly black
- Upgrade from GNOME 44 runtime
- Shader compile failure: GLSL 3.30 is not supported HOT 1
- Feature request: Bit manipulation
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from plots.