#include <vuLightDial.h>
Inheritance diagram for vuLightDial:
Public Types | |
enum | { idLIGHTINT, idHIDE, idLAST } |
Public Member Functions | |
vuLightDial (wxWindow *parent, vuTFDesignSpec &tf) | |
Constructor for the dialog window. | |
bool | isUpdated () |
lights have been updated? | |
void | updateSliders () |
Set the slider according to the weights. | |
float | getLj (int j, const wxPoint &x) |
returns value of lagrange interpolation polynomial L(j) | |
Protected Member Functions | |
void | OnSlideIntensity () |
change in intensity slider | |
void | OnHide () |
hide button clicked | |
void | reweightLights () |
reweights the lights according to slider position | |
void | OnMouseEvent (wxMouseEvent &event) |
mouse handler | |
void | OnPaint () |
customized handle for paint events | |
void | DrawShape () |
void | repaintParent () |
repaint parent (should be a (vuUtilityWindow*)) | |
Protected Attributes | |
vuTFDesignSpec & | m_TFunc |
handle to the tfunc holding the light sources | |
wxSlider * | m_LightIntensity |
Slider for the overall intensity. | |
wxRect | m_DialArea |
area of the dial | |
int | m_WeightX |
position of the light weight | |
int | m_WeightY |
position of the light weight | |
wxSizer * | m_DialSpacer |
spacer for the dial | |
bool | m_IsUpdated |
is updated? | |
wxPoint | m_LPos [LDIAL_MAXLIGHTS] |
bool | m_LActive [LDIAL_MAXLIGHTS] |
wxPoint | m_HullPos [LDIAL_MAXLIGHTS] |
int | m_LIndices [LDIAL_MAXLIGHTS] |
int | m_NLights |
int | m_NCHull |
vuConvexHull | m_CHull |
wxBitmap * | m_BulbImg |
the weights result from reciprocal distances to the nodes being normalized to sum==1
Definition at line 28 of file vuLightDial.h.
|
Definition at line 31 of file vuLightDial.h. |
|
Constructor for the dialog window. This creates the dialog window and it's controls, but doesn't show it. Call the standard ShowModal() method to display it.
Definition at line 40 of file vuLightDial.cpp. References bulbimg, HEADERIMG, LDIAL_INTENSITY, and LDIAL_SLDRES. |
|
Definition at line 159 of file vuLightDial.cpp. References vuConvexHull::addPoint(), vuConvexHull::clearPoints(), dc, vuConvexHull::getCHull(), vuTFDesignSpec::getNumLights(), m_BulbImg, m_CHull, m_DialArea, m_HullPos, m_LActive, m_LIndices, m_LPos, m_NCHull, m_NLights, M_PI, m_TFunc, m_WeightX, m_WeightY, and MIN. Referenced by updateSliders(). |
Here is the call graph for this function:
|
returns value of lagrange interpolation polynomial L(j)
Definition at line 278 of file vuLightDial.cpp. References DNORM, m_LActive, and m_LPos. Referenced by reweightLights(). |
|
lights have been updated?
Definition at line 48 of file vuLightDial.h. References m_IsUpdated. Referenced by vuSpectral::glRender(), and vuSpecFVR::glRender(). |
|
hide button clicked
Definition at line 136 of file vuLightDial.cpp. |
|
mouse handler
Definition at line 290 of file vuLightDial.cpp. References linalg::abs(), vuConvexHull::addPoint(), LR, m_CHull, m_DialArea, m_IsUpdated, m_LActive, m_LPos, m_WeightX, m_WeightY, repaintParent(), reweightLights(), and RR. |
Here is the call graph for this function:
|
customized handle for paint events
Definition at line 146 of file vuLightDial.cpp. |
|
change in intensity slider
Definition at line 262 of file vuLightDial.cpp. References LDIAL_SLDRES. |
|
repaint parent (should be a (vuUtilityWindow*))
Definition at line 402 of file vuLightDial.cpp. Referenced by OnMouseEvent(). |
|
reweights the lights according to slider position
Definition at line 362 of file vuLightDial.cpp. References getLj(), vuTFDesignSpec::getNumLights(), LDIAL_SLDRES, m_DialArea, m_LightIntensity, M_PI, m_TFunc, m_WeightX, m_WeightY, MIN, vuTFDesignSpec::setLightIntensity(), and vuTFDesignSpec::weightLights(). Referenced by OnMouseEvent(). |
Here is the call graph for this function:
|
Set the slider according to the weights. A correct implementation of this function is quite tricky if even impossible because of the limitation of the 2D slidespace and the nD weight space. So far we just use an approximation. Actually, we are doing nothing so far ;-) Definition at line 128 of file vuLightDial.cpp. References DrawShape(), vuTFDesignSpec::getLightIntensity(), LDIAL_SLDRES, m_LightIntensity, and m_TFunc. Referenced by vuSpectral::glRender(). |
Here is the call graph for this function:
|
Definition at line 121 of file vuLightDial.h. Referenced by DrawShape(). |
|
Definition at line 119 of file vuLightDial.h. Referenced by DrawShape(), and OnMouseEvent(). |
|
area of the dial
Definition at line 102 of file vuLightDial.h. Referenced by DrawShape(), OnMouseEvent(), and reweightLights(). |
|
spacer for the dial
Definition at line 108 of file vuLightDial.h. |
|
Definition at line 115 of file vuLightDial.h. Referenced by DrawShape(). |
|
is updated?
Definition at line 111 of file vuLightDial.h. Referenced by isUpdated(), and OnMouseEvent(). |
|
Definition at line 114 of file vuLightDial.h. Referenced by DrawShape(), getLj(), and OnMouseEvent(). |
|
Slider for the overall intensity.
Definition at line 99 of file vuLightDial.h. Referenced by reweightLights(), and updateSliders(). |
|
Definition at line 116 of file vuLightDial.h. Referenced by DrawShape(). |
|
Definition at line 113 of file vuLightDial.h. Referenced by DrawShape(), getLj(), and OnMouseEvent(). |
|
Definition at line 117 of file vuLightDial.h. Referenced by DrawShape(). |
|
Definition at line 117 of file vuLightDial.h. Referenced by DrawShape(). |
|
handle to the tfunc holding the light sources
Definition at line 96 of file vuLightDial.h. Referenced by DrawShape(), reweightLights(), and updateSliders(). |
|
position of the light weight
Definition at line 105 of file vuLightDial.h. Referenced by DrawShape(), OnMouseEvent(), and reweightLights(). |
|
position of the light weight
Definition at line 105 of file vuLightDial.h. Referenced by DrawShape(), OnMouseEvent(), and reweightLights(). |