Merge branch 'gallium-msaa'
[mesa.git] / src / gallium / state_trackers / vega / vg_manager.c
index 8a62a191207280eadb0183fb70360e12ffbdd8ae..3b04816df04dfc8533040b92aa88e5356307e799 100644 (file)
 #include "util/u_format.h"
 #include "util/u_sampler.h"
 
+#include "vg_api.h"
 #include "vg_manager.h"
 #include "vg_context.h"
 #include "image.h"
 #include "mask.h"
+#include "api.h"
 
 static struct pipe_resource *
 create_texture(struct pipe_context *pipe, enum pipe_format format,
@@ -526,17 +528,15 @@ vg_api_is_visual_supported(struct st_api *stapi,
 static st_proc_t
 vg_api_get_proc_address(struct st_api *stapi, const char *procname)
 {
-   /* TODO */
-   return (st_proc_t) NULL;
+   return api_get_proc_address(procname);
 }
 
 static void
 vg_api_destroy(struct st_api *stapi)
 {
-   free(stapi);
 }
 
-struct st_api st_vg_api = {
+static const struct st_api vg_api = {
    vg_api_destroy,
    vg_api_get_proc_address,
    vg_api_is_visual_supported,
@@ -545,8 +545,8 @@ struct st_api st_vg_api = {
    vg_api_get_current,
 };
 
-struct st_api *
-st_api_create_OpenVG(void)
+const struct st_api *
+vg_api_get(void)
 {
-   return &st_vg_api;
+   return &vg_api;
 }