#include <vuMarchingCubes.h>
Inheritance diagram for _HistoCanvas:


Public Member Functions | |
| _HistoCanvas () | |
| Default constructor. | |
| _HistoCanvas (vuMCHistogram *parent, wxWindowID id=-1, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize) | |
| virtual | ~_HistoCanvas () |
| void | Reset () |
| Resets the histogram to it's start value. | |
| void | Inc (int n, int val) |
Increments the value at position n. | |
| void | SetSelColor (wxColour &c) |
| void | Select (int idx) |
| void | DelayedUpdate (bool m) |
| bool | DelayedUpdate () |
| void | OnPaint (wxPaintEvent &event) |
| void | OnMotion (wxMouseEvent &event) |
| void | OnMouse (wxMouseEvent &event) |
| DECLARE_DYNAMIC_CLASS (_HistoCanvas) | |
| DECLARE_EVENT_TABLE () | |
Private Attributes | |
| int | _min |
| This variable will be set to the lowest index in the map _histo. | |
| int | _max |
| This variable will be set to the highest index in the map _histo. | |
| int | _vmax |
| This value holds the biggest value in the map _histo. | |
| float | _vpp |
| Holds the density in y-direction (values per pixel). | |
| float | _ppe |
| Holds the density in x-direction (pixel per element). | |
| map< int, int > | _histo |
| The map holds the histogram values that will be painted. | |
| vuMCHistogram * | _callback |
| We want to inform the parent if, the mouse is over a element in the histogram. | |
| int | _updateCounter |
| This variable counts GUI updates. | |
| bool | _delayedUpdate |
| If this value is true, GUI updates take place only when _updateCounter reaches HC_UPDATE_WATERMARK. | |
| int | _idx |
| The actual index, where the mouse is on. This is updated when the mouse moves. | |
| int | _selected |
| The selected index. | |
| wxColour | _selColor |
| The color used to paint the selected index. | |
As a consequence of a bug in wxGTK-2.4 we had to move this class out from vuMCHistogram. This class provides the DC where the histogram is actually drawn. The class also provides functionallity to controll the GUI-update behaviour.
Definition at line 774 of file vuMarchingCubes.h.
|
|
Default constructor.
Definition at line 743 of file vuMarchingCubes.cpp. References DEBUGC. |
|
||||||||||||||||||||
|
Definition at line 749 of file vuMarchingCubes.cpp. |
|
|
Definition at line 759 of file vuMarchingCubes.cpp. References DEBUGD. |
|
|
|
|
|
|
|
|
Definition at line 829 of file vuMarchingCubes.cpp. References DEBUG0. |
|
|
Definition at line 821 of file vuMarchingCubes.cpp. References _delayedUpdate, _updateCounter, DEBUG0, and DEBUG3. Referenced by vuMCHistogram::OnDelayedUpdateChecked(). |
|
||||||||||||
|
Increments the value at position Incrementing is a little bit of a problem because we do not know how the map intitializes the elements. So we implement the following algorithm:
Definition at line 775 of file vuMarchingCubes.cpp. References _histo, _max, _min, _updateCounter, _vmax, DEBUG0, and DEBUG2. Referenced by vuMCHistogram::Inc(). |
|
|
Definition at line 911 of file vuMarchingCubes.cpp. References _callback, _histo, _idx, _max, _min, _ppe, DEBUG0, DEBUG2, and vuMCHistogram::OnTextChange(). |
Here is the call graph for this function:

|
|
Definition at line 935 of file vuMarchingCubes.cpp. References _callback, _idx, _selected, DEBUG0, and vuMCHistogram::OnClicked(). |
Here is the call graph for this function:

|
|
This is how we work:
Definition at line 835 of file vuMarchingCubes.cpp. References _callback, _histo, _max, _min, _ppe, _selColor, _vpp, dc, DEBUG0, DEBUG2, DEBUG3, and vuMCHistogram::OnTextChange(). Referenced by vuMCHistogram::Flush(). |
Here is the call graph for this function:

|
|
Resets the histogram to it's start value.
Definition at line 764 of file vuMarchingCubes.cpp. References _histo, _max, _min, _updateCounter, _vmax, and DEBUG0. Referenced by vuMCHistogram::Clear(). |
|
|
Definition at line 815 of file vuMarchingCubes.cpp. References _selected, and DEBUG0. Referenced by vuMCHistogram::OnClicked(), and vuMCHistogram::Select(). |
|
|
Definition at line 805 of file vuMarchingCubes.cpp. References _selColor, DEBUG0, and max. Referenced by vuMCHistogram::SetSelColor(). |
|
|
We want to inform the parent if, the mouse is over a element in the histogram.
Definition at line 801 of file vuMarchingCubes.h. Referenced by OnMotion(), OnMouse(), and OnPaint(). |
|
|
If this value is true, GUI updates take place only when _updateCounter reaches HC_UPDATE_WATERMARK.
Definition at line 806 of file vuMarchingCubes.h. Referenced by DelayedUpdate(). |
|
|
The map holds the histogram values that will be painted.
Definition at line 799 of file vuMarchingCubes.h. Referenced by Inc(), OnMotion(), OnPaint(), and Reset(). |
|
|
The actual index, where the mouse is on. This is updated when the mouse moves.
Definition at line 808 of file vuMarchingCubes.h. Referenced by OnMotion(), and OnMouse(). |
|
|
This variable will be set to the highest index in the map _histo. See description of Inc for more information. Definition at line 788 of file vuMarchingCubes.h. Referenced by Inc(), OnMotion(), OnPaint(), and Reset(). |
|
|
This variable will be set to the lowest index in the map _histo. See description of Inc for more information. Definition at line 783 of file vuMarchingCubes.h. Referenced by Inc(), OnMotion(), OnPaint(), and Reset(). |
|
|
Holds the density in x-direction (pixel per element).
Definition at line 797 of file vuMarchingCubes.h. Referenced by OnMotion(), and OnPaint(). |
|
|
The color used to paint the selected index.
Definition at line 812 of file vuMarchingCubes.h. Referenced by OnPaint(), and SetSelColor(). |
|
|
The selected index.
Definition at line 810 of file vuMarchingCubes.h. |
|
|
This variable counts GUI updates.
Definition at line 803 of file vuMarchingCubes.h. Referenced by DelayedUpdate(), Inc(), and Reset(). |
|
|
This value holds the biggest value in the map _histo. It is needed to speed up the histogram drawing. Definition at line 793 of file vuMarchingCubes.h. |
|
|
Holds the density in y-direction (values per pixel).
Definition at line 795 of file vuMarchingCubes.h. Referenced by OnPaint(). |
1.3.9.1