cogl/pipeline: Use G_DECLARE_FINAL_TYPE
Lets us get rid of the boilerplate. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/4155>
This commit is contained in:
parent
b0fd29ece2
commit
ac07f10de3
@ -382,11 +382,6 @@ struct _CoglPipeline
|
|||||||
const char *name;
|
const char *name;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct _CoglPipelineClass
|
|
||||||
{
|
|
||||||
GObjectClass parent_class;
|
|
||||||
};
|
|
||||||
|
|
||||||
typedef struct _CoglPipelineFragend
|
typedef struct _CoglPipelineFragend
|
||||||
{
|
{
|
||||||
void (*start) (CoglPipeline *pipeline,
|
void (*start) (CoglPipeline *pipeline,
|
||||||
|
@ -55,20 +55,11 @@ G_BEGIN_DECLS
|
|||||||
* performs fragment processing including depth testing and texture
|
* performs fragment processing including depth testing and texture
|
||||||
* mapping. Finally it blends the result with the framebuffer.
|
* mapping. Finally it blends the result with the framebuffer.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define COGL_TYPE_PIPELINE (cogl_pipeline_get_type ())
|
#define COGL_TYPE_PIPELINE (cogl_pipeline_get_type ())
|
||||||
#define COGL_PIPELINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), COGL_TYPE_PIPELINE, CoglPipeline))
|
|
||||||
#define COGL_PIPELINE_CONST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), COGL_TYPE_PIPELINE, CoglPipeline const))
|
|
||||||
#define COGL_PIPELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), COGL_TYPE_PIPELINE, CoglPipelineClass))
|
|
||||||
#define COGL_IS_PIPELINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), COGL_TYPE_PIPELINE))
|
|
||||||
#define COGL_IS_PIPELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), COGL_TYPE_PIPELINE))
|
|
||||||
#define COGL_PIPELINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), COGL_TYPE_PIPELINE, CoglPipelineClass))
|
|
||||||
|
|
||||||
typedef struct _CoglPipelineClass CoglPipelineClass;
|
|
||||||
|
|
||||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC (CoglPipeline, g_object_unref)
|
|
||||||
|
|
||||||
COGL_EXPORT
|
COGL_EXPORT
|
||||||
GType cogl_pipeline_get_type (void) G_GNUC_CONST;
|
G_DECLARE_FINAL_TYPE (CoglPipeline, cogl_pipeline, COGL, PIPELINE, GObject)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* cogl_pipeline_new: (constructor)
|
* cogl_pipeline_new: (constructor)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user