Alpha_shapes_2

How to use Alpha shape Demo

Main Functionality

- Reset application
- Creating a new window
- Print
- Close the current window
- Quit the application

Editing

- Generate Delaunay triangulation
- Insert a new vertex
- Delete existing vertex
- Move existing vertex
- Change the alpha value of Alpha shape
  - Using slider
  - Using menu

Persistance

- Load an existing image
- Save the current triangulation
- Load an existing triangulation

Reset application

Press Ctrl+N combination keys or go to File menu and choose "New". The triangulation and the alpha shape will be erased, the window's viewport will be set to default. (-1, 1, -1, 1)

Create a new window

Press Ctrl+W combination keys or go to File menu and choose "New Window". A new window will appear, modifying the viewport to make the triangulation fit in the new window.

Print

Press Ctrl+P combination keys or go to File menu and choose "Print". The visible area on the screen will be outputed to the print device of your choice.

Close the current window

Press Ctrl+X combination keys or go to File menu and choose "Close". You may do it for any window other than the initial one, this operation will close only the one you have choosen. If you do this for the initial parent window, it will close the others too.

Quit the application

Press Ctrl+Q combination keys or go to File menu and choose "Quit". When you quit the application, all the windows you have created will be destroyed.

Generate Delaunay triangulation

To generate a Delaunay triangulation, go to Edit menu and choose "Generate Triangulation" button, or press Ctrl+G combination keys. All the vertices from the triangulation will be inserted in the alpha shape too. Each time you generate the triangulation, the old one will be erased.

Insert a new vertex

Left click on the "Input point" layer. Left Click anywere on the application's drawing area (the black rectangle) to insert the vertex. The vertex is inserted in the triangulation and the alpha shape. To insert more than one vertex, keep clicking on the rectangle without deactivating the "Input point" layer. To deactivate this layer, just press the arrow button situated on the same toolbar.

Delete an existing vertex

(1)Left click on the "Move/Delete point" layer. If the "Input point" layer was active, it will deactivate itself. (2)Right click on the drawing area (the black rectangle) near an existing vertex. A popup menu will apear and the selected vertex will be highlighted. (3)Choose "Delete". The vertex will be removed from the triangulation and from the alpha shape. To delete more than one vertex, repeat the process from (2) to (3). To deactivate this layer, just press the arrow button situated on the same toolbar.

Move existing vertex

(1)Left click on the "Move/Delete point" layer. If the "Input point" layer was active, it will deactivate itself. (2)Right click on the drawing area (the black rectangle) near an existing vertex. A popup menu will apear and the selected vertex will be highlighted. (3)Choose "Move". From this moment, the vertex will move as you move the mouse. The triangulation and the alpha shape will reflect changes. (4)Left click on the drawing area will position the vertex at the mouse coordinates. You may repeat the process from the step (2). To deactivate this layer, just press the arrow button situated on the same toolbar.

Change the alpha value of Alpha shape using the slider

Use the slider from the right of the drawing area (the black rectangle) to increase or decrease the value of alpha. You can see changes on the label situated on the bottom of the application. The minimum value of alpha is 0 and is reflected by the upper slider's cursor position. The maximum value is initially 1 and could be manually changed using the menu (see next section).

Change the alpha value of Alpha shape using the menu

Press Ctrl+C combination keys, or go to Edit menu, then choose "Change alpha". A new modal window will apear with an edit field containing the current alpha value. Enter the new alpha value that you want, then hit enter or press the "OK" button. The slider from the right will change the current value. If the alpha value you have entered is bigger than the maximum slider value, initially 1, the slider will take your alpha as the new maximum value for it. You can see the new alpha value you have entered on the label from the bottom of the window.

Load an existing image

Press Ctrl+I combination keys or go to File menu, then choose "Load Image". A load file dialog will appear, having as the filter the bitmap and jpeg files. Enter "data" directory then choose the m30f.jpg. The image will appear on the drawing area positioned with the upper-left corner in the upper-left corner of the drawing area.

Save the current triangulation

Press Ctrl+S combination keys or go to File menu, then choose "Save Triangulation". A save file dialog will appear, the default name given is "triangulation.cgal". You may change the name then press "Save" or hit "Enter" key. To cancel the save process just press Esc key.
The triangulation saved does not contain the viewport, that means you may not see it when you load it if you have different viewport than the viewport at the save time.

Load an existing triangulation

Press Ctrl+L combination keys or go to File menu and choose "Save Triangulation". A load file dialog will appear, having a filter that displays only the files with "cgal" extension. Choose a file then press "Open" button or hit "Enter" key.
The triangulation saved does not contain the viewport, that means you may not see it when you load it if you have different viewport than the viewport at the save time.

Last modified: Fri May 16 12:14:50 MEST 2003