diff --git a/sys/v4l2/v4l2src_calls.c b/sys/v4l2/v4l2src_calls.c
index 6ff5945..fa6eaaa 100644
--- a/sys/v4l2/v4l2src_calls.c
+++ b/sys/v4l2/v4l2src_calls.c
@@ -909,6 +909,7 @@ default_frame_sizes:
 #endif /* defined VIDIOC_ENUM_FRAMESIZES */
   {
     gint min_w, max_w, min_h, max_h, fix_num = 0, fix_denom = 0;
+    GType type_w, type_h;
 
     /* This code is for Linux < 2.6.19 */
     min_w = min_h = 1;
@@ -924,6 +925,9 @@ default_frame_sizes:
           GST_FOURCC_FORMAT, GST_FOURCC_ARGS (pixelformat));
     }
 
+    type_w = (min_w != max_w) ? GST_TYPE_INT_RANGE : G_TYPE_INT;
+    type_h = (min_h != max_h) ? GST_TYPE_INT_RANGE : G_TYPE_INT;
+
     /* Since we can't get framerate directly, try to use the current norm */
     if (v4l2src->v4l2object->norm && v4l2src->v4l2object->norms) {
       GList *norms;
@@ -945,14 +949,14 @@ default_frame_sizes:
     tmp = gst_structure_copy (template);
     if (fix_num) {
       gst_structure_set (tmp,
-          "width", GST_TYPE_INT_RANGE, min_w, max_w,
-          "height", GST_TYPE_INT_RANGE, min_h, max_h,
+          "width", type_w, min_w, max_w,
+          "height", type_h, min_h, max_h,
           "framerate", GST_TYPE_FRACTION, fix_num, fix_denom, NULL);
     } else {
       /* if norm can't be used, copy the template framerate */
       gst_structure_set (tmp,
-          "width", GST_TYPE_INT_RANGE, min_w, max_w,
-          "height", GST_TYPE_INT_RANGE, min_h, max_h,
+          "width", type_w, min_w, max_w,
+          "height", type_h, min_h, max_h,
           "framerate", GST_TYPE_FRACTION_RANGE, 0, 1, 100, 1, NULL);
     }
     gst_caps_append_structure (ret, tmp);
