#include <PreviewIdentifyTool.h>
Inheritance diagram for PreviewIdentifyTool:

Public Member Functions | |
| PreviewIdentifyTool (ToolHelper *helper, GLPreviewFrame *owner) | |
| ~PreviewIdentifyTool () | |
| void | Activate () |
| Switch on a tool. | |
| void | ImagesUnderMouseChangedEvent () |
| Notify when the images directly underneath the mouse pointer have changed. | |
| void | AfterDrawImagesEvent () |
| Draw (using OpenGL) images above the others. | |
| bool | BeforeDrawImageEvent (unsigned int image) |
| Draw what the tool requires just before a given image is drawn. | |
| void | ShowImageNumber (unsigned int image) |
| Notification for when moving the mouse on an image button. | |
| void | StopShowingImages () |
| Notification for when moving the mouse off an image button. | |
| void | MouseButtonEvent (wxMouseEvent &e) |
| Show control point editor if mouse is over two images. | |
| void | MouseMoveEvent (double x, double y, wxMouseEvent &e) |
| Notify when the mouse pointer has moved over the panorama preview. | |
| void | KeypressEvent (int keycode, int modifiers, int pressed) |
| void | setConstantOn (bool constant_on_in) |
| void | UpdateWithNewImageSet (std::set< unsigned int > new_image_set) |
| void | ForceRedraw () |
Private Member Functions | |
| void | HighlightColour (unsigned int index, unsigned int count, unsigned char &red, unsigned char &green, unsigned char &blue) |
| Generate a colour given how many colours we need and an index. | |
| void | StopUpdating () |
| void | ContinueUpdating () |
Private Attributes | |
| std::set< unsigned int > | image_set |
| Set of image numbers of the images we are displaying highlighted. | |
| GLPreviewFrame * | preview_frame |
| unsigned int | mouse_over_image |
| The image the user last placed their mouse over the button for. | |
| bool | mouse_is_over_button |
| bool | stopUpdating |
| bool | holdLeft |
| bool | holdControl |
| bool | constantOn |
Static Private Attributes | |
| bool | texture_created = false |
| unsigned int | circle_border_tex |
| OpenGL texture name for the circular border texture. | |
| unsigned int | rectangle_border_tex |
| OpenGL texture name for the rectangular border texture. | |
There are two ways it does this:
The highlighted images are drawn on top of the other images, with a coloured border. If the mouse is over exactly two images, a click opens the control point editor with those two images shown.
Definition at line 42 of file PreviewIdentifyTool.h.
|
||||||||||||
|
Definition at line 66 of file PreviewIdentifyTool.cpp. References circle_border_tex, circle_ts, circle_ts_multiple, constantOn, holdControl, holdLeft, preview_frame, rect_ts, rectangle_border_tex, stopUpdating, and texture_created. |
|
|
Definition at line 176 of file PreviewIdentifyTool.cpp. References circle_border_tex, and rectangle_border_tex. |
|
|
Switch on a tool. Inherited classes also register events they want to respond to with the PreviewToolHelper. As events are lost when the tool is deactivated without notification to the PreviewTool, things from the last activation can be cleaned up here too. Implements Tool. Definition at line 183 of file PreviewIdentifyTool.cpp. References image_set, ImagesUnderMouseChangedEvent(), mouse_is_over_button, ToolHelper::NotifyMe(), and ToolHelper::SetStatusMessage(). |
|
|
Draw (using OpenGL) images above the others.
Reimplemented from Tool. Definition at line 322 of file PreviewIdentifyTool.cpp. References TextureManager::BindTexture(), circle_border_tex, DEBUG_ASSERT, VisualizationState::GetMeshDisplayList(), ViewState::GetSupportMultiTexture(), ViewState::GetTextureManager(), ToolHelper::GetViewStatePtr(), ToolHelper::GetVisualizationStatePtr(), HighlightColour(), image_set, preview_frame, rectangle_border_tex, and GLPreviewFrame::SetImageButtonColour(). |
|
|
Draw what the tool requires just before a given image is drawn. This can be used to modify how the images are drawn, prevent drawing of the image, or change the order of the image drawing (with another event to draw the image when it is needed).
Reimplemented from Tool. Definition at line 424 of file PreviewIdentifyTool.cpp. References DEBUG_ASSERT, and image_set. |
|
|
Definition at line 223 of file PreviewIdentifyTool.cpp. References ImagesUnderMouseChangedEvent(), and stopUpdating. Referenced by KeypressEvent(), MouseMoveEvent(), and setConstantOn(). |
|
|
Definition at line 595 of file PreviewIdentifyTool.cpp. References VisualizationState::ForceRequireRedraw(), ToolHelper::GetVisualizationStatePtr(), and VisualizationState::Redraw(). Referenced by ShowImageNumber(), StopShowingImages(), StopUpdating(), and UpdateWithNewImageSet(). |
|
||||||||||||||||||||||||
|
Generate a colour given how many colours we need and an index.
Definition at line 464 of file PreviewIdentifyTool.cpp. References DEBUG_ASSERT. Referenced by AfterDrawImagesEvent(). |
|
|
Notify when the images directly underneath the mouse pointer have changed. It is monitored by the PreviewToolHelper. Reimplemented from Tool. Definition at line 297 of file PreviewIdentifyTool.cpp. References ToolHelper::GetImageNumbersUnderMouse(), image_set, preview_frame, ToolHelper::SetStatusMessage(), and GLPreviewFrame::UpdateIdentifyTools(). Referenced by Activate(), ContinueUpdating(), and MouseButtonEvent(). |
|
||||||||||||||||
|
Definition at line 269 of file PreviewIdentifyTool.cpp. References ContinueUpdating(), holdControl, and StopUpdating(). |
|
|
Show control point editor if mouse is over two images.
Reimplemented from Tool. Definition at line 507 of file PreviewIdentifyTool.cpp. References constantOn, MainFrame::Get(), holdLeft, image_set, ImagesUnderMouseChangedEvent(), ToolHelper::IsMouseOverPano(), MainFrame::ShowCtrlPointEditor(), MainFrame::ShowMaskEditor(), and stopUpdating. |
|
||||||||||||||||
|
Notify when the mouse pointer has moved over the panorama preview. The coordinates are in the space of the panorama output at full size, with no output cropping.
Reimplemented from Tool. Definition at line 228 of file PreviewIdentifyTool.cpp. References ContinueUpdating(), holdControl, StopUpdating(), and stopUpdating. |
|
|
Definition at line 284 of file PreviewIdentifyTool.cpp. References constantOn, ContinueUpdating(), StopUpdating(), and stopUpdating. Referenced by GLPreviewFrame::OnIdentify(), GLPreviewFrame::SetMode(), and GLPreviewFrame::updateBlendMode(). |
|
|
Notification for when moving the mouse on an image button.
Definition at line 432 of file PreviewIdentifyTool.cpp. References DEBUG_ASSERT, ForceRedraw(), image_set, mouse_is_over_button, mouse_over_image, and ToolHelper::NotifyMeBeforeDrawing(). |
|
|
Notification for when moving the mouse off an image button.
Definition at line 449 of file PreviewIdentifyTool.cpp. References ToolHelper::DoNotNotifyMeBeforeDrawing(), ForceRedraw(), image_set, mouse_is_over_button, mouse_over_image, preview_frame, and GLPreviewFrame::SetImageButtonColour(). |
|
|
Definition at line 205 of file PreviewIdentifyTool.cpp. References DEBUG_ASSERT, ToolHelper::DoNotNotifyMeBeforeDrawing(), ForceRedraw(), image_set, preview_frame, GLPreviewFrame::SetImageButtonColour(), stopUpdating, and GLPreviewFrame::UpdateIdentifyTools(). Referenced by KeypressEvent(), MouseMoveEvent(), and setConstantOn(). |
|
|
Definition at line 549 of file PreviewIdentifyTool.cpp. References DEBUG_ASSERT, ToolHelper::DoNotNotifyMeBeforeDrawing(), ForceRedraw(), image_set, ToolHelper::NotifyMeBeforeDrawing(), preview_frame, and GLPreviewFrame::SetImageButtonColour(). Referenced by GLPreviewFrame::UpdateIdentifyTools(). |
|
|
OpenGL texture name for the circular border texture.
Definition at line 63 of file PreviewIdentifyTool.cpp. Referenced by AfterDrawImagesEvent(), PreviewIdentifyTool(), and ~PreviewIdentifyTool(). |
|
|
Definition at line 94 of file PreviewIdentifyTool.h. Referenced by MouseButtonEvent(), PreviewIdentifyTool(), and setConstantOn(). |
|
|
Definition at line 92 of file PreviewIdentifyTool.h. Referenced by KeypressEvent(), MouseMoveEvent(), and PreviewIdentifyTool(). |
|
|
Definition at line 90 of file PreviewIdentifyTool.h. Referenced by MouseButtonEvent(), and PreviewIdentifyTool(). |
|
|
Set of image numbers of the images we are displaying highlighted.
Definition at line 79 of file PreviewIdentifyTool.h. Referenced by Activate(), AfterDrawImagesEvent(), BeforeDrawImageEvent(), ImagesUnderMouseChangedEvent(), MouseButtonEvent(), ShowImageNumber(), StopShowingImages(), StopUpdating(), and UpdateWithNewImageSet(). |
|
|
Definition at line 83 of file PreviewIdentifyTool.h. Referenced by Activate(), ShowImageNumber(), and StopShowingImages(). |
|
|
The image the user last placed their mouse over the button for.
Definition at line 82 of file PreviewIdentifyTool.h. Referenced by ShowImageNumber(), and StopShowingImages(). |
|
|
Definition at line 80 of file PreviewIdentifyTool.h. Referenced by AfterDrawImagesEvent(), ImagesUnderMouseChangedEvent(), PreviewIdentifyTool(), StopShowingImages(), StopUpdating(), and UpdateWithNewImageSet(). |
|
|
OpenGL texture name for the rectangular border texture.
Definition at line 64 of file PreviewIdentifyTool.cpp. Referenced by AfterDrawImagesEvent(), PreviewIdentifyTool(), and ~PreviewIdentifyTool(). |
|
|
Definition at line 88 of file PreviewIdentifyTool.h. Referenced by ContinueUpdating(), MouseButtonEvent(), MouseMoveEvent(), PreviewIdentifyTool(), setConstantOn(), and StopUpdating(). |
|
|
Definition at line 62 of file PreviewIdentifyTool.cpp. Referenced by PreviewIdentifyTool(). |
1.3.9.1