From df78bc04d64c0304efd891ffc583f73cb2f054f3 Mon Sep 17 00:00:00 2001 From: Vadim Pisarevsky Date: Sat, 23 Jul 2011 19:11:17 +0000 Subject: [PATCH] converted book samples from ch4; fixed potential alignment problems in QTKit video capturing module --- modules/highgui/src/cap_qtkit.mm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/highgui/src/cap_qtkit.mm b/modules/highgui/src/cap_qtkit.mm index 17737c0..3cbcb75 100644 --- a/modules/highgui/src/cap_qtkit.mm +++ b/modules/highgui/src/cap_qtkit.mm @@ -733,7 +733,7 @@ IplImage* CvCaptureFile::retrieveFramePixelBuffer() { image->height = height; image->nChannels = 4; image->depth = IPL_DEPTH_8U; - image->widthStep = width*4; + image->widthStep = rowBytes; image->imageData = imagedata; image->imageSize = currSize; @@ -746,7 +746,7 @@ IplImage* CvCaptureFile::retrieveFramePixelBuffer() { bgr_image->height = height; bgr_image->nChannels = 3; bgr_image->depth = IPL_DEPTH_8U; - bgr_image->widthStep = width*4; + bgr_image->widthStep = rowBytes; bgr_image->imageData = bgr_imagedata; bgr_image->imageSize = currSize; -- 2.7.4