summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/vega
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/state_trackers/vega')
-rw-r--r--src/gallium/state_trackers/vega/api_text.c15
-rw-r--r--src/gallium/state_trackers/vega/mask.c4
2 files changed, 10 insertions, 9 deletions
diff --git a/src/gallium/state_trackers/vega/api_text.c b/src/gallium/state_trackers/vega/api_text.c
index 2a62da0a1de..d8264f7c969 100644
--- a/src/gallium/state_trackers/vega/api_text.c
+++ b/src/gallium/state_trackers/vega/api_text.c
@@ -27,6 +27,7 @@
#include "VG/openvg.h"
#include "vg_context.h"
+#include "api.h"
#include "util/u_memory.h"
@@ -73,8 +74,8 @@ void vegaSetGlyphToPath(VGFont font,
VGuint glyphIndex,
VGPath path,
VGboolean isHinted,
- VGfloat glyphOrigin [2],
- VGfloat escapement[2])
+ const VGfloat glyphOrigin[2],
+ const VGfloat escapement[2])
{
struct vg_context *ctx = vg_current_context();
struct vg_object *pathObj;
@@ -109,8 +110,8 @@ void vegaSetGlyphToPath(VGFont font,
void vegaSetGlyphToImage(VGFont font,
VGuint glyphIndex,
VGImage image,
- VGfloat glyphOrigin [2],
- VGfloat escapement[2])
+ const VGfloat glyphOrigin[2],
+ const VGfloat escapement[2])
{
struct vg_context *ctx = vg_current_context();
struct vg_object *img_obj;
@@ -213,9 +214,9 @@ void vegaDrawGlyph(VGFont font,
void vegaDrawGlyphs(VGFont font,
VGint glyphCount,
- VGuint *glyphIndices,
- VGfloat *adjustments_x,
- VGfloat *adjustments_y,
+ const VGuint *glyphIndices,
+ const VGfloat *adjustments_x,
+ const VGfloat *adjustments_y,
VGbitfield paintModes,
VGboolean allowAutoHinting)
{
diff --git a/src/gallium/state_trackers/vega/mask.c b/src/gallium/state_trackers/vega/mask.c
index e40df063470..ce81280dd08 100644
--- a/src/gallium/state_trackers/vega/mask.c
+++ b/src/gallium/state_trackers/vega/mask.c
@@ -38,6 +38,7 @@
#include "util/u_inlines.h"
#include "util/u_format.h"
#include "util/u_memory.h"
+#include "util/u_sampler.h"
struct vg_mask_layer {
struct vg_object base;
@@ -355,7 +356,6 @@ struct vg_mask_layer * mask_layer_create(VGint width, VGint height)
pt.height0 = height;
pt.depth0 = 1;
pt.bind = PIPE_BIND_SAMPLER_VIEW;
- pt.compressed = 0;
texture = screen->resource_create(screen, &pt);
@@ -377,7 +377,7 @@ void mask_layer_destroy(struct vg_mask_layer *layer)
struct vg_context *ctx = vg_current_context();
vg_context_remove_object(ctx, VG_OBJECT_MASK, layer);
- pipe_resource_release(&layer->texture);
+ pipe_sampler_view_reference(&layer->sampler_view, NULL);
FREE(layer);
}