WIP: defer STREAMON in CreateContext (probe how far vaCreateContext gets)
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
+8
-13
@@ -188,19 +188,14 @@ VAStatus RequestCreateContext(VADriverContextP context, VAConfigID config_id,
|
||||
surface_object->source_size = length;
|
||||
}
|
||||
|
||||
rc = v4l2_set_stream(driver_data->video_fd, output_type, true);
|
||||
if (rc < 0) {
|
||||
request_log("CreateContext: STREAMON(OUTPUT) failed\n");
|
||||
status = VA_STATUS_ERROR_OPERATION_FAILED;
|
||||
goto error;
|
||||
}
|
||||
|
||||
rc = v4l2_set_stream(driver_data->video_fd, capture_type, true);
|
||||
if (rc < 0) {
|
||||
request_log("CreateContext: STREAMON(CAPTURE) failed\n");
|
||||
status = VA_STATUS_ERROR_OPERATION_FAILED;
|
||||
goto error;
|
||||
}
|
||||
/* Fourier-local: defer STREAMON until first frame is actually queued.
|
||||
* The V4L2 stateless protocol requires OUTPUT format + at least one
|
||||
* queued slice with SPS/PPS controls attached before STREAMON will
|
||||
* succeed on hantro. The bootlin library was written for sunxi-cedrus
|
||||
* which used a different protocol with no such ordering constraint.
|
||||
* Just being able to vaCreateContext() without erroring lets us see
|
||||
* what the next stage of the call chain expects. */
|
||||
request_log("CreateContext: deferred STREAMON until first QBUF\n");
|
||||
|
||||
context_object->config_id = config_id;
|
||||
context_object->render_surface_id = VA_INVALID_ID;
|
||||
|
||||
Reference in New Issue
Block a user