Skip to contentSkip to conversation

v4l2-compliance: add tests for VIDIOC_S_FBUF/OVERLAY and selection flags

PATCH Superseded Rivka Bukchin 1 participant 1 message Mar 9 Media (V4L/DVB)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 v4l2-compliance: add tests for VIDIOC_S_FBUF/OVERLAY and selection flags

Add compliance tests for VIDIOC_S_FBUF and VIDIOC_OVERLAY to verify basic framebuffer and overlay handling.

Add tests for VIDIOC_S_SELECTION flag handling to ensure that valid flags (V4L2_SEL_FLAG_GE and V4L2_SEL_FLAG_LE) are accepted and that invalid flag combinations are rejected.

These tests extend the coverage of the format and selection ioctl compliance checks.

---
 utils/v4l2-compliance/v4l2-compliance.cpp   |  7 +-
 utils/v4l2-compliance/v4l2-compliance.h     |  3 +
 utils/v4l2-compliance/v4l2-test-formats.cpp | 78 +++++++++++++++++++++
 3 files changed, 83 insertions(+), 5 deletions(-)
utils/v4l2-compliance/v4l2-compliance.cpp +2 -5
index 4e5c9d00..8e242efd 100644
@@ -1464,6 +1464,8 @@ void testNode(struct node &node, struct node &node_m2m_cap, struct node &expbuf_
 		printf("\ttest Cropping: %s\n", ok(testCropping(&node)));
 		printf("\ttest Composing: %s\n", ok(testComposing(&node)));
 		printf("\ttest Scaling: %s\n", ok(testScaling(&node)));
+		printf("\ttest Overlay: %s\n", ok(testOverlay(&node)));
+		printf("\ttest Selection Flags: %s\n", ok(testSelectionFlags(&node)));
 		printf("\n");
 
 		/* Codec ioctls */
@@ -1608,11 +1610,6 @@ void testNode(struct node &node, struct node &node_m2m_cap, struct node &expbuf_
 		}
 	}
 
-	/*
-	 * TODO: VIDIOC_S_FBUF/OVERLAY
-	 * 	 S_SELECTION flags tests
-	 */
-
 	if (is_vivid &&
 	    node.controls.find(VIVID_CID_DISCONNECT) != node.controls.end()) {
 		if (node.node2)
utils/v4l2-compliance/v4l2-compliance.h +3 -0
index 4a7af5f5..958d22a0 100644
@@ -375,6 +375,9 @@ int testSlicedVBICap(struct node *node);
 int testCropping(struct node *node);
 int testComposing(struct node *node);
 int testScaling(struct node *node);
+int testOverlay(struct node *node);
+int testSelectionFlags(struct node *node);
+
 
 // Codec ioctl tests
 int testEncoder(struct node *node);
utils/v4l2-compliance/v4l2-test-formats.cpp +78 -0

81 lines not on this page · raw message

Signature · 1 line
2.34.1