/*
 * g++ fixme.cpp `wx-config --cflags --libs` `pkg-config --cflags --libs gstreamer-1.0`
 */
#include <wx/wx.h>
#include <gst/gst.h>

class app : public wxApp
{
	virtual bool OnInit()
	{
		wxFrame *frame = new wxFrame(NULL, wxID_ANY, "");

		frame->Show();

		gst_init(NULL, NULL);

		GError *err = NULL;
		GstElement *pipe = gst_parse_launch("videotestsrc ! autovideoconvert ! autovideosink", &err);
		if (err != NULL)
		{
			g_print("error: %s\n", err->message);
		}

		gst_element_set_state(pipe, GST_STATE_PLAYING);

		return true;
	}
};

DECLARE_APP(app)
IMPLEMENT_APP(app)
