Summary: | [Gtk] WebGL not enabled | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Deepu S <ashoka.deepu> | ||||
Component: | WebGL | Assignee: | Nobody <webkit-unassigned> | ||||
Status: | NEW --- | ||||||
Severity: | Major | CC: | ashoka.deepu, dino, kbr, kkinnunen | ||||
Priority: | P2 | ||||||
Version: | Other | ||||||
Hardware: | PC | ||||||
OS: | Linux | ||||||
Attachments: |
|
Description
Deepu S
2024-04-02 23:06:49 PDT
import gi gi.require_version('Gtk', '3.0') gi.require_version('WebKit2', '4.0') from gi.repository import Gtk, WebKit2 window = Gtk.Window() window.set_default_size(800, 600) window.connect("destroy", Gtk.main_quit) scrolled_window = Gtk.ScrolledWindow() webview = WebKit2.WebView() settings = webview.get_settings() settings.set_enable_webgl(True) settings.set_enable_accelerated_2d_canvas(True) settings.set_hardware_acceleration_policy(WebKit2.HardwareAccelerationPolicy.ALWAYS) webview.set_settings(settings) webview.load_uri("https://get.webgl.org") scrolled_window.add(webview) window.add(scrolled_window) window.show_all() Gtk.main() here is the python code used. libwebkit2gtk-4.0-dev is installed. |