basecamerasrc: Make construct_pipeline optional
Construct pipeline should be optional. Subclasses that don't have internal elements don't need it.
This commit is contained in:
parent
ba2368d0bc
commit
80ff930012
@ -390,11 +390,11 @@ construct_pipeline (GstBaseCameraSrc * self)
|
||||
{
|
||||
GstBaseCameraSrcClass *bclass = GST_BASE_CAMERA_SRC_GET_CLASS (self);
|
||||
|
||||
g_return_val_if_fail (bclass->construct_pipeline, FALSE);
|
||||
|
||||
if (!bclass->construct_pipeline (self)) {
|
||||
GST_ERROR_OBJECT (self, "pipeline construction failed");
|
||||
return FALSE;
|
||||
if (bclass->construct_pipeline) {
|
||||
if (!bclass->construct_pipeline (self)) {
|
||||
GST_ERROR_OBJECT (self, "pipeline construction failed");
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
|
Loading…
x
Reference in New Issue
Block a user