If you can take split images for left and right just do that and add them up to your own video stream.
You can run a loop, with every itteration you take a snapshot from the left and right side and then move them to a video player.
For one camera it would be:
cam = webcam();
videoFrame = snapshot(cam);
frameSize = size(videoFrame);
videoPlayer = vision.VideoPlayer('Position', [100 100 [frameSize(2), frameSize(1)]+30]);
runLoop = true;
FrameCount = 0;
while runLoop && FrameCount < 100
FrameCount = FrameCount + 1
videoFrame = snapshot(cam);
videoFrame = rgb2gray(videoFrame);
step(videoPlayer, videoFrame);
runLoop = isOpen(videoPlayer);
end
If you say you can take images or snapshots from both cameras you can modify the code so you make two snapshots and use them then. Keep in mind to create a camera object and videoPlayer object for each camera.
댓글 수: 0
댓글을 달려면 로그인하십시오.