mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
media: rockchip: vicap fixes crop sync error
while two camera link to a device tree, if the link relationship is switched from one sensor to another, there may be error messages in crop information Signed-off-by: Zefa Chen <zefa.chen@rock-chips.com> Change-Id: I6b6aa3efcf8f862b5b1b6e41fb2b4c2fcead2282
This commit is contained in:
@@ -5356,6 +5356,7 @@ static void rkcif_sync_crop_info(struct rkcif_stream *stream)
|
||||
stream->crop_mask |= CROP_SRC_SENSOR_MASK;
|
||||
dev->terminal_sensor.selection = input_sel;
|
||||
} else {
|
||||
stream->crop_mask &= ~CROP_SRC_SENSOR_MASK;
|
||||
dev->terminal_sensor.selection.r = dev->terminal_sensor.raw_rect;
|
||||
}
|
||||
}
|
||||
@@ -5376,8 +5377,10 @@ static void rkcif_sync_crop_info(struct rkcif_stream *stream)
|
||||
stream->crop[CROP_SRC_ACT].top = stream->crop[CROP_SRC_USR].top +
|
||||
stream->crop[CROP_SRC_SENSOR].top;
|
||||
}
|
||||
} else {
|
||||
} else if (stream->crop_mask & CROP_SRC_SENSOR_MASK) {
|
||||
stream->crop[CROP_SRC_ACT] = stream->crop[CROP_SRC_SENSOR];
|
||||
} else {
|
||||
stream->crop[CROP_SRC_ACT] = dev->terminal_sensor.raw_rect;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user