summaryrefslogtreecommitdiffstats
path: root/gst/videofilter/gstvideobalance.c
diff options
context:
space:
mode:
Diffstat (limited to 'gst/videofilter/gstvideobalance.c')
-rw-r--r--gst/videofilter/gstvideobalance.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/gst/videofilter/gstvideobalance.c b/gst/videofilter/gstvideobalance.c
index 2acad7c3..083e5e8a 100644
--- a/gst/videofilter/gstvideobalance.c
+++ b/gst/videofilter/gstvideobalance.c
@@ -107,12 +107,12 @@ gst_videobalance_get_type (void)
};
videobalance_type = g_type_register_static (GST_TYPE_VIDEOFILTER,
- "GstVideobalance", &videobalance_info, 0);
+ "GstVideobalance", &videobalance_info, 0);
g_type_add_interface_static (videobalance_type,
- GST_TYPE_IMPLEMENTS_INTERFACE, &iface_info);
+ GST_TYPE_IMPLEMENTS_INTERFACE, &iface_info);
g_type_add_interface_static (videobalance_type, GST_TYPE_COLOR_BALANCE,
- &colorbalance_info);
+ &colorbalance_info);
}
return videobalance_type;
}
@@ -138,7 +138,7 @@ gst_videobalance_base_init (gpointer g_class)
for (i = 0; i < G_N_ELEMENTS (gst_videobalance_formats); i++) {
gst_videofilter_class_add_format (videofilter_class,
- gst_videobalance_formats + i);
+ gst_videobalance_formats + i);
}
gst_videofilter_class_add_pad_templates (GST_VIDEOFILTER_CLASS (g_class));
@@ -189,15 +189,15 @@ gst_videobalance_class_init (gpointer g_class, gpointer class_data)
g_object_class_install_property (gobject_class, ARG_CONTRAST,
g_param_spec_double ("contrast", "Contrast", "contrast",
- 0, 2, 1, G_PARAM_READWRITE));
+ 0, 2, 1, G_PARAM_READWRITE));
g_object_class_install_property (gobject_class, ARG_BRIGHTNESS,
g_param_spec_double ("brightness", "Brightness", "brightness",
- -1, 1, 0, G_PARAM_READWRITE));
+ -1, 1, 0, G_PARAM_READWRITE));
g_object_class_install_property (gobject_class, ARG_HUE,
g_param_spec_double ("hue", "Hue", "hue", -1, 1, 0, G_PARAM_READWRITE));
g_object_class_install_property (gobject_class, ARG_SATURATION,
g_param_spec_double ("saturation", "Saturation", "saturation",
- 0, 2, 1, G_PARAM_READWRITE));
+ 0, 2, 1, G_PARAM_READWRITE));
gobject_class->set_property = gst_videobalance_set_property;
gobject_class->get_property = gst_videobalance_get_property;
@@ -473,13 +473,13 @@ gst_videobalance_update_tables_planar411 (GstVideobalance * vb)
u = 128 + ((i * hue_cos + j * hue_sin) * vb->saturation);
v = 128 + ((-i * hue_sin + j * hue_cos) * vb->saturation);
if (u < 0)
- u = 0;
+ u = 0;
else if (u > 255)
- u = 255;
+ u = 255;
if (v < 0)
- v = 0;
+ v = 0;
else if (v > 255)
- v = 255;
+ v = 255;
vb->tableu[i + 128][j + 128] = rint (u);
vb->tablev[i + 128][j + 128] = rint (v);
}
@@ -526,7 +526,7 @@ gst_videobalance_planar411 (GstVideofilter * videofilter, void *dest, void *src)
for (y = 0; y < height; y++) {
tablelookup_u8 (cdest + y * width, 1, csrc + y * width, 1,
- videobalance->tabley, 1, width);
+ videobalance->tabley, 1, width);
}
}
@@ -542,10 +542,10 @@ gst_videobalance_planar411 (GstVideofilter * videofilter, void *dest, void *src)
for (y = 0; y < height / 2; y++) {
for (x = 0; x < width / 2; x++) {
- u1 = usrc[y * (width / 2) + x];
- v1 = vsrc[y * (width / 2) + x];
- udest[y * (width / 2) + x] = videobalance->tableu[u1][v1];
- vdest[y * (width / 2) + x] = videobalance->tablev[u1][v1];
+ u1 = usrc[y * (width / 2) + x];
+ v1 = vsrc[y * (width / 2) + x];
+ udest[y * (width / 2) + x] = videobalance->tableu[u1][v1];
+ vdest[y * (width / 2) + x] = videobalance->tablev[u1][v1];
}
}
}