Last change
on this file since 110 was 110, checked in by DHERBOMEZ Gérald, 9 years ago |
- minor modifications about dllexport and dllimport macros usages
|
File size:
1.0 KB
|
Rev | Line | |
---|
[16] | 1 | /*********************************************************************
|
---|
| 2 | // created: 2006/06/09 - 7:58
|
---|
| 3 | // filename: ImageViewer.h
|
---|
| 4 | //
|
---|
| 5 | // author: Gerald Dherbomez
|
---|
| 6 | //
|
---|
| 7 | // version: $Id: ImageViewer.h 1239 2012-11-28 16:30:00Z kurdejma $
|
---|
| 8 | //
|
---|
| 9 | // purpose: use this class to display an image
|
---|
| 10 | *********************************************************************/
|
---|
| 11 |
|
---|
| 12 | #ifndef IMAGEVIEWER_H
|
---|
| 13 | #define IMAGEVIEWER_H
|
---|
| 14 |
|
---|
[50] | 15 | #include "Pacpus/kernel/road_time.h"
|
---|
[16] | 16 |
|
---|
| 17 | #include <QFrame>
|
---|
| 18 |
|
---|
| 19 | class QMutex;
|
---|
| 20 |
|
---|
[110] | 21 | namespace pacpus {
|
---|
| 22 |
|
---|
| 23 | class ImageViewer
|
---|
[16] | 24 | : public QFrame
|
---|
| 25 | {
|
---|
| 26 | Q_OBJECT
|
---|
| 27 |
|
---|
| 28 | public:
|
---|
| 29 | ImageViewer();
|
---|
| 30 | ~ImageViewer();
|
---|
| 31 |
|
---|
| 32 | void setMutex(QMutex * imageMutex);
|
---|
| 33 |
|
---|
| 34 | public Q_SLOTS:
|
---|
| 35 | void display(QImage * image);
|
---|
| 36 |
|
---|
| 37 | protected Q_SLOTS:
|
---|
| 38 | void paintEvent(QPaintEvent * e);
|
---|
| 39 |
|
---|
| 40 | private:
|
---|
| 41 | QPixmap * imageBuffer_; // the pixmap that will be displayed
|
---|
| 42 | QMutex * imageMutex_; // the mutex that protects access to the shared image
|
---|
| 43 |
|
---|
| 44 | road_time_t tic_;
|
---|
| 45 | void tic();
|
---|
| 46 | void toc(char * text);
|
---|
| 47 | };
|
---|
| 48 |
|
---|
[110] | 49 | }
|
---|
[16] | 50 | #endif // IMAGEVIEWER_H
|
---|
Note:
See
TracBrowser
for help on using the repository browser.