| Home | Examples | Software | Publications |
Software
What you will find here is some of the software that I have developed through the years. Unfortunately I was unable to update and maintain them all, so downloading is in fact not always useful anymore. Maybe, someday, I will have time to continue some of the projects...The Mesopotamian Cylinder Seal - iOS App
|
This is an iOS App for iPod, iPad and iPhone whicht lets you interactively rotate a seal on your mobile touch device. |
Web based sequence viewer
|
Download the code version 0.4 [~1Mb zip file], |
Using the Javascript code for your own sequences
You can see how it works by reading the example code, which is also included in the download.For an existing html page to include the sequence, the following steps are needed.
- Add the style and script elements to the top of the head section
<!-- use Google Code to load jQuery --> <script src="http://www.google.com/jsapi"></script> <script type="text/javascript"> google.load("jquery", "1.2.6"); // jQuery basis google.load("jqueryui", "1.5.2"); // jQuery UI - for the slider </script> <!-- style sheets and js-code for the plugins, you need to have these files --> <link rel="stylesheet" href="js/css/jquery-objectsequencecontrol.css" type="text/css" media="screen"/> <script type="text/javascript" src="js/jquery.objectsequencecontrol.js"> </script> <link rel="stylesheet" href="js/css/jquery-objectsequenceviewer.css" type="text/css" media="screen"/> <script type="text/javascript" src="js/jquery.objectsequenceviewer.js"> </script>
- Add the jQuery code (inside script tags) which sets up the plugins.
Note that "#id_control1" and "#id_view1" correspond to the id's of the div elements described by the next step.jQuery.noConflict(); // Alows you to work with other libraries without naming conflicts // jQuery main entrance jQuery(document).ready(function(){ var control1 = jQuery("#id_control1").objectsequencecontrol({ maxcounter: 59, delay: 30, animationtype: "swing"}); var view1 = jQuery('#id_view1').objectsequenceviewer({ folder: "small/", basename: "scan_", maxcounter: 60, initialposition: 30, rotationaxis: "horizontal", pixelsperimage: 2, animationtype: "swing"}). bind("initialized", function(event){ control1.setindex(view1.getindex()); control1.width(view1.width()); }); control1.setindex(view1.getindex()); control1.width(view1.width()); control1.bind("changed", function(event,i){ view1.setindex(i); }); view1.bind("changed", function(event,i){ control1.setindex(i); }); });
- Add the div elements inside your html body
<!-- the div's used by the plugins--> <div id="id_control1"></div> <div id="id_view1"></div>
- Change the options inside the script code of step 2.
Objectsequencecontrol optionsname type description maxcounter integer The maximum counter number.
It is a zero based index , for 60 images it must be 59.delay integer The number of millisecond to pause between two succesive images while animating.
Larger slows animation dow, lower speeds it up.animationtype String Specifies how to traverse the images when animating.(with the play button)
With "swing" the animation direction reverses when the end or beginning of the sequence is reached..
With "loop" the animation continues at the start when the end is reached, usefull for full 360 degrees rotating objects.
Objectsequenceviewer optionsname type description folder String The path to the folder containing the image files.
It must end with a slash like in the example: "small/"basename String Specifies the base or first part of the image filenames.
The file name is assumed to be composed of a base followed by a zero padded counter, a dot and then the extension which must be jpg.
For example in "scan_0002.jpg", the basename is "scan_".
Note that the numbering must also start at 1 and the counter must be padded up to 4 digits.maxcounter integer The maximum counter number used for the image filename.
It is a one based index , for 60 images it must be 60.initialposition integer The counter of the initial image to show while loading all other images.
For instance, to start with an image in the middle, the example uses 30rotationaxis String Specify dragging behaviour by indicating the objects rotational axis.
With "horizontal", dragging up and down results in change of image sugesting rotation. With a "vertical" rotation axis you need to drag sideways.pixelsperimage integer The number of pixels to drag for the viewer to show the next image.
If this is small the view is more sensitive to dragging and if larger it is less sensitieve. It depends on the image size and the original rotation angle between two succesive imagesanimationtype String Specifies how to traverse the images when dragging.
Similar to Objectsequencecontrol option above.
Syracuse
|
|
- After Syracuse has been installed, start it by double clicking the desktop icon or by selecting the Syracuse start menu item.
- When Syracuse starts, a dialog is shown which lets you select a camera and a table. Select the <fake camera> and the <fake table>
- Wait fot the fake table to initialize and then you can change the camera settings, grab an image rotate the table and even acquire a fake sequence.
Web based size measuring on an image
|
Download the NetBeans6.5 Java project [~16kb zip file] |
There are only to parameters you need to provide:
- The Image URL. The image will be resized (preserving aspect ratio) to fit the applet dimensions.
- The pixel size in meters, assuming a square pixel.
<applet code="nwocatch.rich.MeasurementApplet" archive="MeasurementApplet.jar" width=400 height=400> <param name="pixelsize" value="0.000257"/> <param name="image-url" value="http://www.xs4all.nl/~pnm/paul/software/measurementapplet/glas.png"/> </applet>
Web based image annotation
|
Download the NetBeans6.5 Java project [~26kb zip file] |
Using the annotation applet
Parameters| Name | Description | Possible values | Default |
|---|---|---|---|
| image-url | Specifies the url to the image data; the file | Any valid url string referring to an image (jpg, png, gif). | Must be specified! |
| controlpannel | Indicates if the applet displays the control panel. This panel; has an Add and Remove button and is used for testing. | ‘off’ or ‘on’ | ‘off’ |
The applet is made scriptable. The following member function can be called.
Member functions
| Name | Description |
|---|---|
| addAnnotation(id, label, text, type, region) | All parameters are described by the 'getters' below. If an annotation exists with the given id, it is replaced. When all parameters are ommitted the values will be generated and a new annotation will be placed at the center of the canvas. This is useful when the user needs to start a new annotation. |
| getAnnotationLabel(id) | Returns the label (short title) string. |
| getAnnotationText(id) | Returns the text (complete description) string. |
| getAnnotationType(id) | Returns the type string. For this demo only "rectregion" is supported. |
| getAnnotationRegion(id) | Comma separated list of numbers, indicating coordinates or dimensions.
For a rectregion type the meaning is: x-coordinate of topleft corner, y-coordinate of topleft corner, width, height. All specified in image pixels. |
| setAnnotationLabel(id, label) | Set the label of the annotation with the given id. |
| setAnnotationText(id, text) | Set the text of the annotation with the given id. |
| setAnnotationRegion(id, region) | Set the region of the annotation with the given id. See: getAnnotationRegion for a description of the region string |
| selectAnnotation(id) | Select the annotation with the given id. Only one annotation can be selected at the same tine, so no multiple-selection supported. |
| getAnnotationId() | Returns the id string of the selected annotation, empty string if no annotation was selected. |
| removeAnnotation(id) | Remove annotation with given id from the applet. If no id is given it removes selected annotation. |
The applet also calls the following Javascript functions.
Events
| Name | Description |
|---|---|
| <applet id>_onSelectionChanged() Where <applet id> should be replaced by the actual applet element id. |
Called when a selected annotation changes. Either by select/deselect or move/resize. |
top