Important: Please read the Qt Code of Conduct -

Camera Problem on Symbain^3

  • Yes and better develop the complete app in Symbian than Qt as you need to put it on Ovi. You will have to develop the engine in native Symbian and if you develop the ui part also in Symbian instead of Qt - probably your app will support wider range of devices.

  • [quote author="tamhanna" date="1291440958"]The Qt has the most benefits if you later want to port to Maemo or desktop at some point in the future...[/quote]

    But then again you Qt mobility is mainly for mobile devices and these API's won't be supported on Desktop right. And N900 being the only maemo device with Qt updates the target audience is very few. Maybe once meego comes in the scenario might change.

  • [quote author="QtK" date="1291441234"]
    But then again you Qt mobility is mainly for mobile devices and these API's won't be supported on Desktop right. [/quote]

    Read the first post from here:
    It says "but also provide useful application functionality across desktop platforms."

  • It's quite useful and a time saver. I don't see the problem. SmartInstaller will install the latest on the users system.

  • It wouldn't update your app if you didn't use SI either. What's the point?

    If you mean your app will be built on an older Qt, that's fine. Qt will be backwards compatible with your app anyway. You can update it in your own time.

  • Well Qt Mobility obviously has a very useful API set and is very quick to code with. Better to use the wheel than reinvent it. And it does link in well with Qt. SmartInstaller means that you don't need to worry about whether the user has it on their system or not. So, it's win/win.
    What would you use instead?

    The only problem (with regards to topic) is that the QtMobility the user wants isn't allowed to be deployed in Ovi, yet.

  • No, we've been over this. Write once, it will always work. You don't need to update your code because new Qt versions come out.

  • Oh I guess Nokia weren't talking about QtMobility. I got it confused when Nokia mentioned that all Qt4.6.3 apps will work in future.

    Well just keep updating your apps if they ever break ;) I'm sure Nokia won't break it intentionally.

  • [quote author="xsacha" date="1291446040"]Oh I guess Nokia weren't talking about QtMobility. I got it confused when Nokia mentioned that all Qt4.6.3 apps will work in future.

    Well just keep updating your apps if they ever break ;) I'm sure Nokia won't break it intentionally.[/quote]

    But these days decisions made by Nokia confuses developers a lot. You cannot say if they will stick to one plan. Especially, the way the roadmap is being changed.

  • I will still use it especially for camera, regardless. I prefer coding a little a lot rather than a lot a little.

  • You don't get Qt apps signed. Nokia signs it for you. It's completely free. (Exception being when it requires too much capability).

    I submit unsigned app on Ovi Publish, mark it as 'unsigned' and Nokia does the rest. Hopefully this is what you meant.

    [quote author="tamhanna" date="1291449010"] This is a question of taste.[/quote]
    Only if they break compatibility. If they didn't, it would be a no-brainer. Code a little, little.

  • Well both of you are right. Just to add the app which nokia signs cannot be distributed via any other channel. It can be distributed only via Ovi. Thats the catch for free ovi signing.

  • I didn't say you can't sign it yourself. I'm saying that's the way you're meant to submit apps on Ovi and that's the way I do it. It fits in with QtCreator, it's the easiest and of course free.
    If your app needs more than basic capabilities, then you'll need to pay to sign of course.

    Nokia gives you free UID3's by the way. In allotments of five unless you require more.

    My route is 0 euros a pop.

  • How about just use that UID3 in the first place?
    I don't understand. You have to stick with an old UID3 so you have to pay to sign it?

  • This is for Qt apps.
    This is the first time Qt apps have been allowed on the Ovi Store.

    So no apps from 2008, no old UIDs.

    I fail to see your point.

  • Not 2008 :P Time between SmartInstaller existance and free signing is a very short time window.
    Unlucky if you missed out, but it's a one-off break from UID. And it affects only a handful of apps.
    It also saves 20 euro (per pop as you say) for each future update.

    Anyway you can create a topic about it if you want. Going off-topic.

  • Well I think you're in the minority, so I stand by my free signing of Qt apps with Nokia UIDs.

    Going back on-topic:
    So, for you, updating your projects for each QtMobility update may prove expensive but it doesn't really affect the rest of us. Especially considering these are new apps we are talking about.
    So I'll happily go with QtMobility to use such APIs as Camera and update when it is required.

  • Please correct me if I'm wrong but all the APIs in QtMobility 1.1 are stated to be final (API Maturity Level -FINAL). So any app using QtMobility 1.1 should run with future mobility packages, as the API is final. "Mobility Doc":

  • Well that is true kkrzewniak.

    But there's a lot of important functionality in QtMobility 1.1 that resides in the 'labs' -- this of course is not final and will change soon.


    • Gestures (pinch-zoom, swipe and so on) Plugin
    • Folder List Plugin
    • Particles Plugin

    Fortunately for the OP, Camera shouldn't change much.
    The APIs defined as 'FINAL' may still be extended (but still backwards compatible).

  • Yes and that is my point exactly! Stop whining that QtMobility so bad, just stick to the parts You know to be final.

  • I don't know why tam hates QtMobility so much. My only guess is he has created his own custom libraries to deal with camera and so on and hates that it has all been replaced by 3 lines of code :P.

  • Moderators

    tamhanna: Have fun limiting your apps to the Symbian ecosystem then.

    Seriously: Qt is meant to make it easy to cover all (Nokia) phones, not just Symbian. You are giving up on Meego before it is even out! And there even are community ports of Qt to android and iphone... who knows, maybe those will become official someday...

  • Moderators

    tamhanna: Most linux distributions are moving away from HAL... I do not know whether it will be in meego or not:-)

  • I don't think his 'hal' header is actually related to HAL, that's just how you handle these libraries right tam? I knew you spent time on custom libraries! :P It's ok to move on to QtMobility you know. Even if it seems you've wasted time making your hal.h.

    I don't think Meego will use HAL though. Will it even use X11? I think Nokia wanted Wayland?

  • OK, I'm not sure why you call it HAL :P I always call that stuff 'defines.h' or 'constants.h' or similar.

    This doesn't show your solution for QtMobility. What do you use?

    Do you have anything that could help the OP, for example, with his Camera API? Or you just write this in Symbian C++?

  • Hi All,
    to be able to use camera in my app i've decided to use CCamera class and MCameraObserver2, below yuo'll find all my class code:

    #ifndef MAINWINDOW_H
    #define MAINWINDOW_H

    #include <QMainWindow>
    #include <ecam.h>

    namespace Ui {
    class MainWindow;

    class MainWindow : public QMainWindow, public MCameraObserver2

    explicit MainWindow(QWidget *parent = 0);

    //Derived from MCameraObserver2

    void HandleEvent(const TECAMEvent &);
    void ImageBufferReady(MCameraBuffer &, TInt);
    void VideoBufferReady(MCameraBuffer &, TInt);
    void ViewFinderReady(MCameraBuffer &, TInt);


    Ui::MainWindow *ui;
    bool iCameraOn;

    private slots:
    void on_pushButton_clicked();

    CCamera *iCamera;
    TCameraInfo iCameraInfo;


    #endif // MAINWINDOW_H


    #include <ecam.h>

    //To remove
    #include <QDebug>

    #include "MainWindow.h"
    #include "ui_MainWindow.h"

    MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow)
    QWidget::setWindowFlags(windowFlags() | Qt::WindowSoftkeysVisibleHint);
    setWindowFlags(Qt::WindowSoftkeysVisibleHint); //To be ablet to see down soft keys

    qDebug()<<"Delete MainWindow";
    if (iCamera!=0)
    delete iCamera;
    delete ui;

    void MainWindow::on_pushButton_clicked()
    //Activate Camera
    // iCamera=CCamera::New2L(*this,CCamera::CamerasAvailable(),(TInt) 50);

    TInt a_TInt_NoOfCameraAvailable=CCamera::CamerasAvailable();
    int a_int_NoOfCameraAvailable=(int) a_TInt_NoOfCameraAvailable;
    qDebug()<<"CamerasAvailable return value: "<<a_int_NoOfCameraAvailable;
    if (a_int_NoOfCameraAvailable>0)
        if (iCamera==NULL)
            qDebug()<<"00 - Building iCamera and reserve it";


    void MainWindow::HandleEvent(const TECAMEvent & aEvent)
    QString aString="I'm in HandleEvent";

    switch (aEvent.iEventType.iUid)
    case 270499131:
            //Reserve Complete
            qDebug()<<"01 - Reserve Complete start power on";
            if (iCameraOn==false)
                qDebug()<<"MainWindow::HandleEvent iCamera->PowerOn();";
    case 270499132:
            //PowerOn Complete
            qDebug()<<"02 - Power On complete";
            qDebug()<<"aEvent= "<<(int)aEvent.iEventType.iUid;


    void MainWindow::ImageBufferReady(MCameraBuffer & aCameraBuffer, TInt)
    QString aString="I'm in ImageBufferReady";

    void MainWindow::VideoBufferReady(MCameraBuffer &aCameraBuffer, TInt)
    QString aString="I'm in VideoBufferReady";

    void MainWindow::ViewFinderReady(MCameraBuffer &aCameraBuffer, TInt)
    QString aString="I'm in ViewFinderReady";


    But when i run program console said: 'CActiveScheduler::RunIfReady() returned error: -5'

    Could you please le tme know where i'm wronging.


Log in to reply