Is there any way to work with camera with QCamera class in Nokia N9 (Meego 1.2 Harmattan) or I should use another one?
Here's my problem: simple application that works fine on Nokia C6-01 (Symbian Anna) doesn't do anything useful on N9.
Here're code snipets:
testmobile.pro
<...>
CONFIG += mobility
MOBILITY += multimedia
LIBS += -lQtMultimediaKit
<...>
mainwindow.h
class MainWindow : public QWidget
{
Q_OBJECT
<...>
private:
QCamera* camera_;
QGraphicsView *view;
QGraphicsVideoItem *videoItem;
QGraphicsScene *scene;
<...>
}
mainwindow.cpp
MainWindow::MainWindow(QWidget *parent)
: QWidget(parent)
{
<...>
camera_ = new QCamera;
view = new QGraphicsView(this);
scene = new QGraphicsScene(view);
videoItem = new QGraphicsVideoItem;
view->setScene(scene);
scene->addItem(videoItem);
QVBoxLayout *lay = new QVBoxLayout(this);
lay->addWidget(view);
this->setLayout(lay);
view->show();
camera_->setViewfinder(videoItem);
camera_->start();
}
<...>
So after MainWindow object is constructed and shown we'll se a simple viewfinder on Nokia C6-01 and black screen on Nokia N9.
Any ideas?