equal
deleted
inserted
replaced
21 |
21 |
22 #include <QObject> |
22 #include <QObject> |
23 #include "cxeerror.h" |
23 #include "cxeerror.h" |
24 #include "cxestatemachine.h" |
24 #include "cxestatemachine.h" |
25 |
25 |
26 class QPixmap; |
|
27 class CxeSnapshotControl; |
26 class CxeSnapshotControl; |
28 class CxeCameraDevice; |
27 class CxeCameraDevice; |
29 |
28 |
30 |
29 |
31 /*! |
30 /*! |
41 void handleStateChanged(int newStateId, CxeError::Id error); |
40 void handleStateChanged(int newStateId, CxeError::Id error); |
42 |
41 |
43 private: |
42 private: |
44 CxeSnapshotControl::State state() const; |
43 CxeSnapshotControl::State state() const; |
45 void initializeStates(); |
44 void initializeStates(); |
46 QSize calculateSnapshotSize(const QSize &displaySize, const QSize &outputResolution) const; |
45 QSize calculateSnapshotSize(const QSize &displaySize, Cxe::AspectRatio aspectRatio) const; |
47 void start(const QSize &size); |
46 void start(const QSize &size); |
48 void stop(); |
47 void stop(); |
49 void handleCameraEvent(int id, int error); |
48 void handleCameraEvent(int id, int error); |
50 QPixmap snapshot(); |
49 QImage snapshot(); |
51 |
50 |
52 private: |
51 private: |
53 CxeSnapshotControl *q; |
52 CxeSnapshotControl *q; |
54 CxeCameraDevice &mDevice; |
53 CxeCameraDevice &mDevice; |
55 |
54 |