gsk: Remove gsk_render_node_set_scaling_filters()

This is a leftover from the very early rendernode that we forgot to delete.

This can be seen by the fact that it is settable on an immutable object.
This commit is contained in:
Benjamin Otte 2017-12-03 21:56:24 +01:00
parent 794a2bfd00
commit 52b1cd40d1
5 changed files with 2 additions and 70 deletions

View File

@ -35,7 +35,6 @@ gsk_render_node_serialize
gsk_render_node_deserialize
gsk_render_node_write_to_file
GskScalingFilter
gsk_render_node_set_scaling_filters
gsk_render_node_set_name
gsk_render_node_get_name
gsk_render_node_get_bounds

View File

@ -650,39 +650,8 @@ get_gl_scaling_filters (GskRenderNode *node,
int *min_filter_r,
int *mag_filter_r)
{
switch (node->min_filter)
{
case GSK_SCALING_FILTER_NEAREST:
*min_filter_r = GL_NEAREST;
break;
case GSK_SCALING_FILTER_LINEAR:
*min_filter_r = GL_LINEAR;
break;
case GSK_SCALING_FILTER_TRILINEAR:
*min_filter_r = GL_LINEAR_MIPMAP_LINEAR;
break;
default:
break;
}
switch (node->mag_filter)
{
case GSK_SCALING_FILTER_NEAREST:
*mag_filter_r = GL_NEAREST;
break;
/* There's no point in using anything above GL_LINEAR for
* magnification filters
*/
case GSK_SCALING_FILTER_LINEAR:
case GSK_SCALING_FILTER_TRILINEAR:
default:
*mag_filter_r = GL_LINEAR;
break;
}
*min_filter_r = GL_NEAREST;
*mag_filter_r = GL_NEAREST;
}
#if 0

View File

@ -93,9 +93,6 @@ gsk_render_node_new (const GskRenderNodeClass *node_class, gsize extra_size)
self->ref_count = 1;
self->min_filter = GSK_SCALING_FILTER_NEAREST;
self->mag_filter = GSK_SCALING_FILTER_NEAREST;
return self;
}
@ -177,30 +174,6 @@ gsk_render_node_get_bounds (GskRenderNode *node,
graphene_rect_init_from_rect (bounds, &node->bounds);
}
/**
* gsk_render_node_set_scaling_filters:
* @node: a #GskRenderNode
* @min_filter: the filter for scaling down
* @mag_filter: the filter for scaling up
*
* Sets filters to be used when a node must be scaled up
* or down.
*
* Since: 3.90
*/
void
gsk_render_node_set_scaling_filters (GskRenderNode *node,
GskScalingFilter min_filter,
GskScalingFilter mag_filter)
{
g_return_if_fail (GSK_IS_RENDER_NODE (node));
if (node->min_filter != min_filter)
node->min_filter = min_filter;
if (node->mag_filter != mag_filter)
node->mag_filter = mag_filter;
}
/**
* gsk_render_node_set_name:
* @node: a #GskRenderNode

View File

@ -66,11 +66,6 @@ void gsk_render_node_unref (GskRenderNode *
GDK_AVAILABLE_IN_3_90
GskRenderNodeType gsk_render_node_get_node_type (GskRenderNode *node);
GDK_AVAILABLE_IN_3_90
void gsk_render_node_set_scaling_filters (GskRenderNode *node,
GskScalingFilter min_filter,
GskScalingFilter mag_filter);
GDK_AVAILABLE_IN_3_90
void gsk_render_node_set_name (GskRenderNode *node,
const char *name);

View File

@ -19,10 +19,6 @@ struct _GskRenderNode
/* Use for debugging */
char *name;
/* Scaling filters */
GskScalingFilter min_filter;
GskScalingFilter mag_filter;
graphene_rect_t bounds;
};