41 typedef std::map<Int_t, SurfIter_t> IterMap_t;
42 typedef IterMap_t::iterator IterMapIter_t;
49 class TGL5DDataSetEditor::TGL5DEditorPrivate {
54 return fIterators.find(index) != fIterators.end();
111 fHidden =
new TGL5DEditorPrivate;
128 fShowBoxCut->
Connect(
"Toggled(Bool_t)",
"TGL5DDataSetEditor",
this,
"BoxCutToggled()");
129 fAlpha->
Connect(
"ValueChanged(Long_t)",
"TGL5DDataSetEditor",
this,
"AlphaChanged()");
130 fAlpha->
Connect(
"ValueSet(Long_t)",
"TGL5DDataSetEditor",
this,
"AlphaChanged()");
137 fNCellsXEntry->
Connect(
"ValueSet(Long_t)",
"TGL5DDataSetEditor",
this,
"GridParametersChanged()");
138 fNCellsXEntry->
Connect(
"ValueChanged(Long_t)",
"TGL5DDataSetEditor",
this,
"GridParametersChanged()");
140 fNCellsYEntry->
Connect(
"ValueSet(Long_t)",
"TGL5DDataSetEditor",
this,
"GridParametersChanged()");
141 fNCellsZEntry->
Connect(
"ValueSet(Long_t)",
"TGL5DDataSetEditor",
this,
"GridParametersChanged()");
156 fOkGridBtn->
Connect(
"Pressed()",
"TGL5DDataSetEditor",
this,
"ApplyGridParameters()");
159 fIsoList->
Connect(
"Selected(Int_t)",
"TGL5DDataSetEditor",
this,
"SurfaceSelected(Int_t)");
285 const UInt_t min = 10, max = 300;
295 frame = make_labeled_hframe(gridGroup,
"Cells along Y:");
302 frame = make_labeled_hframe(gridGroup,
"Cells along Z:");
314 make_slider_range_entries(rangeGroup,
fXRangeSliderMin,
"Set the minimum value of the x-axis",
317 make_slider_range_entries(rangeGroup,
fYRangeSliderMin,
"Set the minimum value of the y-axis",
320 make_slider_range_entries(rangeGroup,
fZRangeSliderMin,
"Set the minimum value of the z-axis",
344 make_slider_range_entries(v4Group,
fV4MinEntry,
"Minimum value of V4",
413 if ((
fDataSet = dynamic_cast<TGL5DDataSet *>(obj))) {
427 if (needUpdate &&
gPad)
436 slider->
SetRange(r.first, r.second);
499 curr->fHighlight =
kFALSE;
505 fHidden->fIterators[ind] = curr;
734 Error(
"SurfaceSelected",
"Got wrong index %d",
id);
TGDoubleHSlider * fSlideRange
virtual Float_t GetMinPosition() const
virtual void Resize(UInt_t w=0, UInt_t h=0)
Resize the frame.
const Rgl::Range_t & GetYRange() const
V2 range (Y).
TGNumberEntry * fNCellsXEntry
virtual void Resize(UInt_t w, UInt_t h)
Resize the listbox widget.
TGTextButton * fSurfRemoveBtn
virtual void AddEntry(TGString *s, Int_t id)
Add entry with specified string and id to listbox.
void ZSliderSetMin()
Value in a number entry was modified.
virtual Float_t GetMaxPosition() const
void ShowBoxCut(Bool_t show)
virtual TGFrame * GetContainer() const
TGNumberEntryField * fYRangeSliderMin
void ZSliderSetMax()
Value in a number entry was modified.
virtual void SetRange(Int_t min, Int_t max)
virtual Double_t GetBinLowEdge(Int_t bin) const
Return low edge of bin.
virtual void SetState(Bool_t state)
Set the active state.
TGNumberEntry * fNCellsZEntry
std::pair< Double_t, Double_t > Range_t
GUI editor for OpenGL 5D Painter.
TGCheckButton * fShowCloud
virtual void SetToolTipText(const char *text, Long_t delayms=500)
Set tool tip text associated with this text entry.
Bool_t IsBoxCutShown() const
void SetColor(Pixel_t color, Bool_t emit=kTRUE)
Set color.
virtual void SetNumber(Double_t val)
void RemoveSurface()
Remove selected surface.
TGTextButton * fAddNewIsoBtn
void GridParametersChanged()
Some of controls in a "Grid" tab was modified.
virtual void SetLimits(ELimit limits=TGNumberFormat::kNELNoLimits, Double_t min=0, Double_t max=1)
void CreateGridTab()
Tab, containing controls to set the ranges and number of cells in a grid.
virtual void SetRange(Float_t min, Float_t max)
void XSliderSetMax()
Value in a number entry was modified.
TGNumberEntryField * fXRangeSliderMin
void ApplyAlpha()
Slot connected to the "Apply" button for alpha value.
void SetAlpha(Double_t newAlpha)
Set selection range parameter.
TGHSlider * fSurfAlphaSlider
void YSliderChanged()
Y slider in a "Grid" tab.
void HighlightClicked()
Check, if selected surface must be highlighted.
virtual Double_t GetBinUpEdge(Int_t bin) const
Return up edge of bin.
TGDoubleHSlider * fXRangeSlider
void CreateStyleTab()
Creates "Style" tab.
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString...
virtual Long_t GetIntNumber() const
const Rgl::Range_t & GetZRange() const
V3 range (Z).
void XSliderChanged()
X slider in a "Grid" tab.
void SurfaceSelected(Int_t id)
Surface was selected in a list box.
TGDoubleHSlider * fYRangeSlider
TGNumberEntryField * fZRangeSliderMax
TGCompositeFrame(const TGCompositeFrame &)
void ZSliderChanged()
Z slider in a "Grid" tab.
virtual TGVerticalFrame * CreateEditorTabSubFrame(const char *name)
Create a vertical frame to be used by 'owner' in extra tab 'name'.
virtual Double_t GetNumber() const
Get the numeric value (floating point representation).
TGL5DPainter * GetRealPainter() const
Get access to painter (for GUI-editor).
void BoxCutToggled()
Slot connected to the Show BoxCut check button.
TGCheckButton * fLogScale
void ColorChanged(Pixel_t pixelColor)
Change the color of the selected surface.
virtual void SetLimits(ELimit limits=kNELNoLimits, Double_t min=0, Double_t max=1)
Set the numerical limits.
const Rgl::Range_t & GetXRange() const
V1 range (X).
const Mask_t kKeyPressMask
TAxis * GetYAxis() const
Y axis for plot.
Bool_t Connect(const char *signal, const char *receiver_class, void *receiver, const char *slot)
Non-static method is used to connect from the signal of this object to the receiver slot...
virtual void RemoveAll()
Remove all entries.
void XSliderSetMin()
Value in a number entry was modified.
TGCheckButton * fShowBoxCut
SurfList_t::iterator SurfIter_t
Int_t GetLast() const
Return last bin on the axis i.e.
Class to manage histogram axis.
void DisableSurfaceControls()
Disable surface controls.
void YSliderSetMin()
Value in a number entry was modified.
void RemoveInput(UInt_t emask)
Remove events specified in emask from the events the frame should handle.
TGTextButton * fOkGridBtn
virtual void Error(const char *method, const char *msgfmt,...) const
Issue error message.
virtual void SetPosition(Int_t pos)
SurfIter_t SurfacesEnd()
std::list::end.
void ApplyGridParameters()
"Apply" button was pressed in a "Grid" tab.
static Int_t GetColor(const char *hexcolor)
Static method returning color number for color specified by hex color string of form: "#rrggbb"...
const Rgl::Range_t & GetV4Range() const
V4 range.
void CreateIsoTab()
Tab, containing controls to work with iso-surfaces.
TGNumberEntryField * fV4MaxEntry
void DisableGridTabButtons()
Disable "Cancel" and "Apply" buttons.
void ResetGeometryRanges()
No need to create or delete meshes, number of meshes (iso-levels) are the same, but meshes must be re...
TGNumberEntryField * fYRangeSliderMax
void SetIsoTabWidgets()
Set "Surfaces" tab's controls from model.
virtual void SetIntNumber(Long_t val)
TGCheckButton * fHighlightCheck
virtual void SetModel(TObject *obj)
Set model or disables/hides viewer.
TGL5DDataSetEditor(const TGL5DDataSetEditor &)
TGTextButton * fApplyPlanes
TGColorSelect * fSurfColorSelect
TGNumberEntry * fNCellsYEntry
static ULong_t Number2Pixel(Int_t ci)
Static method that given a color index number, returns the corresponding pixel value.
void VisibleClicked()
Hide/show selected surface.
virtual Double_t GetNumber() const
void EnableGridTabButtons()
Grid parameters were changed, enable "Cancel" and "Apply" buttons.
TGNumberEntryField * fZRangeSliderMin
TGNumberEntry * fNumberOfPlanes
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=0)
Add frame to the composite frame using the specified layout hints.
void ConnectSignals2Slots()
Connect signals to slots.
void AddNewSurface()
Add new iso-surface.
void NContoursChanged()
Slot connected to the Number of Planes value-entry.
Mother of all ROOT objects.
virtual void Layout()
Layout the listbox components.
virtual void SetNumber(Double_t val)
Set the numeric value (floating point representation).
SurfIter_t AddSurface(Double_t v4, Color_t ci, Double_t isoVal=1., Double_t sigma=1., Double_t range=1e-3, Int_t lowNumOfPoints=kNLowPts)
Try to add new iso-surface.
TGNumberEntryField * GetNumberEntry() const
void SetNContours(Int_t num)
Set the number of predefined contours.
TGNumberEntryField * fV4MinEntry
void AlphaChanged()
Slot connected to the Alpha entry.
void RollbackGridParameters()
"Cancel" button was pressed in a "Grid" tab.
Int_t GetNContours() const
virtual void SetPosition(Float_t min, Float_t max)
void YSliderSetMax()
Value in a number entry was modified.
TGNumberEntry * fNewIsoEntry
TGNumberEntryField * fXRangeSliderMax
SurfIter_t SurfacesBegin()
std::list::begin.
Double_t GetAlpha() const
virtual void Set(Int_t nbins, Double_t xmin, Double_t xmax)
Initialize axis with fix bins.
void RemoveSurface(SurfIter_t surf)
Remove iso-surface.
TGDoubleHSlider * fZRangeSlider
virtual void MakeTitle(const char *title)
Create attribute frame title.
TGL5DEditorPrivate * fHidden
void SetGridTabWidgets()
Set "Grid" tab's controls from model.
TGTextButton * fCancelGridBtn
TGCheckButton * fVisibleCheck
void ApplyPlanes()
Slot connected to the Apply Planes button.
virtual void RemoveEntry(Int_t id=-1)
remove entry with id.
TGTextButton * fApplyAlpha
void EnableSurfaceControls()
Surface was selected in a list box, enable some controls.
TAxis * GetXAxis() const
X axis for plot.
void SetStyleTabWidgets()
Set "Style" tab's controls from model.
TAxis * GetZAxis() const
Z axis for plot.
const char * Data() const