Commit a1140503 authored by Thiago Santini's avatar Thiago Santini

Uses frame info for resolution

parent cdc634a1
......@@ -43,7 +43,7 @@ void UVCCameraSession::callback(uvc_frame_t *frame)
QVideoFrame qFrame;
switch(frame->frame_format) {
qFrame = QVideoFrame( (int) frame->data_bytes, QSize(settings.resolution().width(), settings.resolution().height()), 0, QVideoFrame::Format_Jpeg);
qFrame = QVideoFrame( (int) frame->data_bytes, QSize(frame->width, frame->height), 0, QVideoFrame::Format_Jpeg);;
memcpy( qFrame.bits(), frame->data, frame->data_bytes); // copied; safe to retun from callback now
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment