| |
XTRA for work with irregular window shapes in Director
© 1992-2003 Studio dmm, all rights reserved
Licencing information
This software is a commercial product. If you are a registred user,
no royalty-fees are required for distribution
of the software with your applications.
By using the software you're agreeing to the terms and conditions
of the Licence Agreement.
Demoversion download
Fully working testing version of the XTRA library, an example
in Director is enclosed (the demo version is fully working but the
library will show a dialogue window).
Description
The library allows you to adjust shapes of windows and to work with
translucence and transparency of the windows. Most of the functions
can be combined with one another so that interesting effects in
the windows can appear. The library works in Windows. Some functions
only work in Windows 2000 and XP.
Library is compatible with
Director 7, 8, 8.5, MX
History
| 12/03/2003 |
|
Version 1.5 |
|
The function dmm_AlfaBlendWindow was renamed to
dmm_AlphaBlendWindow |
| 14/12/2002 |
|
Version 1.4 |
|
The function dmm_FadeFromToWindow was added
The function dmm_MemberRgn was added |
| 17/11/2002 |
|
Version 1.3 |
|
The function dmm_RectRgn was added
The function dmm_AlfaBlendWindow was added
The function dmm_TransparentColorWindow was added |
| 29/07/2002 |
|
Version 1.2 |
|
The function dmm_RoundRectRgn was added |
| 10/07/2002 |
|
Version 1.1 |
|
The function dmm_SetRgnFile was renamed to dmm_BitmapRgn |
| 07/07/2002 |
|
Version 1.0 |
|
Foundation of the library |
List of functions
| dmm_RegWindow |
|
XTRA dmm window.x32 registration |
| dmm_Border |
|
Adjustment of definition of the application in Director |
| dmm_BitmapRgn |
|
Adjustment of an irregular window of the application in Director.
Shape
of the window is read from an external bmp folder. |
| dmm_MemberRgn |
|
Adjustment of an irregular window of the application in Director.
Shape
of the window is read from an Internal Cast |
| dmm_RoundRectRgn |
|
Adjustment of a window with rounded corners in Director |
| dmm_RectRgn |
|
Adjustment of a rectangle window in Director |
| dmm_AlphaBlendWindow |
|
Adjustment of window transparency in Director, using alfa
channel
(Win NT, 2000, XP) |
| dmm_TransparentColorWindow |
|
Adjustment of window translucence in Director, using colour
(Win NT, 2000, XP) |
| dmm_FadeFromToWindow |
|
Time animation of window transparency in Director, using alfa
channel
(Win NT, 2000, XP) |
All the functions only work in the "Projector" modus.
In the "Author" mode an undesirable reduction of the Director
window could occur.
Description of functions
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_RegWindow(code:string)
We must call this function before we use the dmm_window.x32
library for the first time. If you do not insert the correct registration
number a note saying this is a demo version will appear after you
start the application.
Parametres
The type of code is string (lpcstr), for the demo version code="demo".
For the commercial version the chain is unique.
Example
dmm_RegWindow("demo")
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_Border(line:boolean)
The application in Director is defined by a black one-pixel
line. The dmm_Border function switches on or switches off display
of this line.
Parametres
The type of line is boolean. If line=true the line is visible, if
line=false the line is not dosplayed.
Example
on startMovie
dmm_Border(false)
end
Note
The function only works in the "Projector" modus.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_BitmapRgn(file:string)
This function allows you to create applications in Director,
whose window is not rectangular but rounded or differently irregular.
The function reads the mask from an external bmp folder and reduces
the window depending on it. What is black is reduced so it is not
visible. What is white will stay visible. The window is reduced
including all the driving elements. It is necessary to know it.
Parametres
The type of file is string and we place here the bmp folder, which
the window should be in accordance with (including the path)
Example
dmm_BitmapRgn(the pathName & "okno.bmp")
Note
The function only works in the "Projector" modus. It is
necessary to realise that the reduced window will have the same
shape as the mask. The best way is to prepare the mask, read it
into Director and then into score so that we can see where the applications
will be reduced. After we finish we delete the mask.
If you compile the application as "Full Screen", the reduced
window will appear on the background of the main Director window.
If you choose "In Window", the reduced window will appear
on the Windows background. It is possible to prepare more than one
mask and then to change these masks during the application.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_MemberRgn(name:string)
This function and the dmm_BitmapRgn function work almost identically.The
only difference is that this function reads from Internal Cast.
Parametres
The type of name is string and here you fill the name of member
in which the mask is read. The mask must be situated in Internal
Cast.
Example
dmm_memberRgn("window27")
Note
The function only works in the "Projector" modus.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_RoundRectRgn(widthEllipse:word,
heightEllipse:word)
This function allows you to create applications whose windows
are rounded. The window size will not change only the corners will
become rounded.
Parametres
WidthEllipse is in pixels and it determines a value of camber in
horizontal axis. HeightEllipse is also in pixels but it determines
a value of camber in vertical axis.
Example
dmm_RoundRectRgn(20,25)
Note
The function only works in the "Projector" modus.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_RectRgn(left:word, top:word,
width:word, height:word)
This function allows you to create applications whose windows
are rectangular.Extents of the window are defined by the function
parametres. This function can cancel the adjustment of dmm_BitmapRgn,
dmm_MemberRgn, dmm_RoundRectRgn, if you place the original window
extents.
Parametres
Left is in pixels and it determines the x-coordinate of the upper-left
window corner. Top is in pixels too and it determines the y-coordinate
of the upper-left window corner. Width is size of the window in
pixels and so is Height.
Example
dmm_RectRgn(20,25,200,500)
Note
The function only works in the "Projector" modus.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_AlphaBlendWindow(opacity:word)
This function allows you to constitute transparency for alfa
windows. It only works in Win NT, 2000, XP.
Parametres
The type of opacity is word and the value is from 0 to 100 (it is
the value of opacity).
100-opaque window, 0- transparent window.
Example
dmm_AlphaBlendWindow(25)
Note
The function only works in the "Projector" modus.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_TransparentColorWindow(r:word,
g:word, b:word)
This function allows you to create translucent windows. You
adjust translucence in the colour system RGB. It only works in Win
NT, 2000, XP.
Parametres
The type of R, G, B is word and it is adjustment of colour in the
RGB system. The parametres can be between 0 and 25.
Example
dmm_TransparentColorWindow(255,0,0) causes that translucent colour
will be the red one in the window.
Note
The function only works in the "Projector" modus.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
void=dmm_FadeFromToWindow(opacity_1:word,
opacity_2: word, time:word, period:word)
This function allows you to animate transparency of windows.
The dmm_FadeFromToWindow function animates transparency of windows
in interval opacity_1 and opacity_2. If the opacity_1 is less than
the opacity_2, transparency decreases. In the other case it increases.
It only works in Win NT, 2000, XP.
Parametres
The type of opacity _1 is word and its value ranges from 0 to 100.
It shows level of the original transparency.
The type of opacity _2 is word and its value ranges from 0 to 100.
It shows level of the final transparency.
100-opaque window, 0- transparent window.
The type of time is word and it adjusts time which the whole animation
will take (in milliseconds).
The type of period is word and it is time in which the window will
begin to change (time of one section of the animation). The period
can range from 5ms to 5000ms.
If you choose, for instance, time=5000ms and period=20ms, then the
window will be repainted 50 times during the whole animation. We
must realise that during the animation processor must recount the
whole application window and it means it is extremely busy. That
is why we must choose the period intelligently. With some computers
it is possible that the animation will take longer than we have
adjusted. It is because the processor is busy.
Example
dmm_FadeFromToWindow(100,25,1000,25);
dmm_FadeFromToWindow(25,100,2000,50);
This will make the window disappear fluently and display again.
Note
The function only works in the "Projector" modus.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
Important
Most of the functions can be combined with one another so that
you can reach very interesting shapes and effects of the windows.
|