PanoMax Panorama Component Demo
version 1.0

Copyright (C) 1998 Practical Soft

http://practicalsoft.hypermart.net/shareware/delphi/tpanoramacontrol.html
practicalsoft@usa.net

All Rights Reserved
================================================================


The PanoMax Panorama Component is an interactive renderer of 
panoramic images, featuring the latest technology on 
image based rendering. A physical based camera model is 
implemented with field of view, camera velocity and inertia.
The component features various rendering quality options and 
three different input modes for user interaction.
And easy to use too...
The PanoMax Panorama Control is implemented as a Delphi 3/4 VCL
control, descendant of TWinControl. The Methods and properties 
are described bellow.



TPanoramaControl Reference
==========================


Methods:
========

Constructor Create(AOwner: TComponent);
Destructor Destroy;
  These are called upon creation and destruction of the component.

Function OpenPanorama(Filename: string; 
                      CameraLookAtAngle: Single): Boolean;
  Open the panorama image file. Panorama image files can be of Jpeg 
  or Windows/OS2 Bitmap format with up to 16384 pixels of width.
  The function returns True or False upon success or failure.

Procedure ClosePanorama;
  Closes the actual panorama, releasing all the associated resources.

Procedure SetBounds(aLeft: integer;
                    aTop: integer;
                    aWidth: integer;
                    aHeight: integer);
  Resizes/Moves the Panorama. You can also use the Width and Height,
  but if you resize more than one at the same time use this method, 
  because it's faster.

Function GetAngleFromPoint(X, Y: integer): Single;
  This function receives the x and y of a point on the container and
  returns the corresponding angle of the panorama.


Properties:
===========

property CameraVelocity: Single;
  Sets/returns the camera velocity. A positive value sets the camera
  to the right, a negative value to the left. The camera velocity 
  is subject to the Inertia specified by the CameraInertia property.
  Default is 0.

property CameraInertia: Single;
  Sets/returns the inertia that the camera suffers. Values range from
  0 to 100, 0 means the camera will stop right away, 100 means it will
  keep moving for ever (e.g.. the camera maintains the velocity).
  Default is 92.

property CameraLookAtAngle: Single;
  The angle that the camera is facing, ranging from 0 to 360 degrees.
  Default is 0.

property CameraViewAngle: Integer;
  Sets/returns the field of view of the camera.
  Default is 60.

property HorizonLine: Integer;
  Sets/returns the y line that specifies the horizon line of the 
  panorama. With this setting you can fake looking up or down, the
  default setting is half the height of the panorama - that is the
  horizon line his at half of view.

property Render: Boolean;
  If Render=True the component renders scenes else no rendering is 
  done.

property CameraQuality: Integer;
  This property controls the rendering quality, it can assume the 
  following values:
   cqBlurNone=0  - No antialiasing is performed
   cqBlurOnStop=1  - Antialiasing is performed when the camera stops.
                    This offers increased performance, with good 
                    quality on camera stop (that's when the user
                    notices the image quality).
   cqBlurAlways=2  - Always performs antialiasing. More demanding on 
                    processing power.

property InputMode: Integer;
  The InputMode property sets the how the component reacts to mouse
  input:
   imNone=0  - The component doesn't respond to mouse interaction
   imDrag=1  - The component interprets the mouse movements as if
               dragging the image.
   imGuide=2  - The component reacts as if the user is pointing the
                way to move. This is the usual interaction  for 
                standards like QTVR and others. This is the default.
   imGuideReverse=3  - Same as previous, but with inverted movement.
  
property RenderingPriority: Integer;
  Controls the relative CPU priority of the thread that renders the
  images. The values range from -3 to 3, and can increase the 
  rendering performance:
  rpIdle=-3;  
  rpLow=-2;
  rpBelowNormal=-1;
  rpNormal=0; (Default)
  rpAboveNormal=1;
  rpHigh=2;
  rpCritical=3;

property Filename: String;
  Returns the current open image. If set works as the OpenPanorama
  method.

Next are the default stock properties:
property Left: Integer;
property Top: Integer;
property Width: Integer;
property Height: Integer;
property Enabled;
property Font;
property ShowHint;
property Visible;

BackBMP: TBitmap; 
  This is the back buffer where the rendering is done. By using the
  OnAfterRendering Event you can Draw on this bitmap and flicker-free
  mix your graphics over the rendered image.

LastError: integer;
  LastError keeps the code of the last error that occurred;
  Currently can be one of the following:
   10: Image file not found or file format not supported
       - images files must be BMP or JPEG file formats, 
       with a maximum width of 16384.
   1000: Catastrophic Error/Failure
       - this error should never occur. Please call us stating 
       full configuration if this problem arises.


Events:
=======

These are the default events, and have their usual meaning:
OnClick;
OnMouseDown;
OnMouseMove;
OnMouseUp;

OnAfterRendering;
  This event is called after the rendering is done. 
  If you access the BackBMP Bitmap at this stage the results 
  of the rendering can be manipulated without flicker.
  For example you can draw text over, or draw all kinds of
  graphics. Check the Demo for an interesting example.






