GNU Radio's HOWTO Package
show_image.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright 2013 Volker Schroer, DL1KSV.
4  *
5  * This is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 3, or (at your option)
8  * any later version.
9  *
10  * This software is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this software; see the file COPYING. If not, write to
17  * the Free Software Foundation, Inc., 51 Franklin Street,
18  * Boston, MA 02110-1301, USA.
19  */
20 
21 
22 #ifndef INCLUDED_DISPLAY_SHOW_IMAGE_H
23 #define INCLUDED_DISPLAY_SHOW_IMAGE_H
24 
25 #include <Python.h>
26 #include <display/api.h>
27 #include <gnuradio/sync_block.h>
28 #include <QWidget>
29 
30 
31 class QApplication;
32 class ShowPngPicture;
33 
34 namespace gr {
35  namespace display {
36 
37  /*!
38  * \brief display a grayscaled ( png ) image
39  * \ingroup display
40  *
41  */
42  class DISPLAY_API show_image : virtual public sync_block
43  {
44  public:
45  typedef boost::shared_ptr<show_image> sptr;
46 
47  /*!
48  * \brief Return a shared_ptr to a new instance of display::show_image.
49  *
50  * To avoid accidental use of raw pointers, display::show_image's
51  * constructor is in a private implementation
52  * class. display::show_image::make is the public interface for
53  * creating new instances.
54  */
55  static sptr make(int imagewidth,int imageheight,QWidget *parent=NULL);
56  virtual PyObject* pyqwidget()=0;
57  virtual void displayBottomUp(bool direction) = 0;
58  };
59 
60  } // namespace display
61 } // namespace gr
62 
63 #endif /* INCLUDED_DISPLAY_SHOW_IMAGE_H */
boost::shared_ptr< show_image > sptr
Definition: show_image.h:45
Definition: showpngpicture.h:13
#define DISPLAY_API
Definition: api.h:30
Definition: show_image.h:34
display a grayscaled ( png ) image
Definition: show_image.h:42