I am trying to derive a widget off of Gtk::GLArea,
when I do, I get GLib-GObject-CRITICAL **: g_value_take_object:
assertion 'G_IS_OBJECT (v_object)' failed
and "OpenGL context creation failed.
I have tracked this to
GdkGLContext* GLArea_Class::create_context_callback(GtkGLArea* self)
where a different path is taken whether or not the GtkGLArea self is
derived or not.
However, I don't know if I am not doing something correctly, or if this
is a bug.
Any help would be apprectiate.
the following example demonstrates the problem under a ubuntu 16.04.
TIA
Bill
#include <gtkmm.h>
class SimpleWindow : public Gtk::Window
{
public:
SimpleWindow();
virtual ~SimpleWindow();
};
class MyArea : public Gtk::GLArea
{
public:
MyArea() :Gtk::GLArea() {};
virtual ~MyArea() {};
};
SimpleWindow::SimpleWindow()
{
using Gtk::manage;
MyArea *myArea = manage(new MyArea());
//Gtk::GLArea *myArea = manage(new Gtk::GLArea());
add(*manage(myArea));
show_all();
}
SimpleWindow::~SimpleWindow()
{
}
int main (int argc, char *argv[])
{
auto app = Gtk::Application::create(argc, argv, "org.gtkmm.example");
SimpleWindow simple;
return app->run(simple);
}
_______________________________________________
gtkmm-list mailing list
[email protected]
https://mail.gnome.org/mailman/listinfo/gtkmm-list