?? manual.htm
字號:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>Datastead Software - TActiveMovie user guide</title>
<link rel="stylesheet" type="text/css" href="../../common/style.css">
<style>
<!--
.body { color: #000000; font-family: Arial; font-size: 9 pt; font-weight: normal background-color: #000000 }
.bd { color: #000000; font-family: Arial; font-size: 9 pt; font-weight: normal background-color: #000000 }
.def { color: #000000; font-family: Arial; font-size: 9 pt; font-weight: normal }
.topt { font-family: Arial; font-size: 9 pt; font-weight: bold }
.topv { font-family: Arial; font-size: 9 pt; font-weight: bold }
.topl { font-family: Arial; font-size: 9 pt; font-weight: normal}
.t1 { font-family: Arial; color: #000080; font-size: 9 pt; font-weight: bold; background-color: #E8ECFF }
.t2 { color: #000080; font-family: Arial; font-size: 9 pt; font-weight: bold }
.t2u { color: #000080; font-family: Arial; font-size: 9 pt; font-weight: bold; text-decoration: underline }
.t3 { color: #000080; font-family: Arial; font-size: 9 pt; font-weight: normal; text-decoration: underline }
.t3nu { color: #000080; font-family: Arial; font-size: 9 pt; font-weight: normal}
.highl { color: #000080; font-family: Arial; font-size: 9 pt; font-weight: normal}
.proc { color: #000000; font-family: Arial; font-size: 9 pt; font-weight: bold }
.procwd { color: #000080; font-family: Arial; font-size: 9 pt; font-weight: bold }
.code { color: #008000; font-family: Courier New; font-size: 9 pt; font-weight: normal }
.faqQ { color: #000080; font-family: Arial; font-size: 9 pt; font-weight: bold }
.toptile { color: #FFFFFF; font-family: Arial, 'MS Sans Serif', 'MS Serif'; font-size: 9 pt; font-weight: bold; text-decoration: none }
.topsubtile { color: #000080; font-family: Arial, 'MS Sans Serif', 'MS Serif'; font-size: 9 pt; font-weight: normal; text-decoration: none }
-->
</style>
<meta name="Microsoft Border" content="none">
</head>
<body><font class="body">
<p><i><b><font face="Verdana" size="5" color="#000080">Datastead Software</font></b></i></p>
<font face="Verdana, Arial, Helvetica">
<!--webbot bot="Include"
u-include="version.htm" tag="BODY" startspan -->
<font class=topt>
<p align="left">TActiveMovie<br>
</font><font class="topv">v<font class=topt>ersion </font></font><font class="topt">5.14</font><font class="topv">
- April 21, 2008</font></p>
<!--webbot bot="Include" endspan i-checksum="32805" -->
</font>
</font>
<p><font face="Verdana" size="2">Home page: <a href="http://www.datastead.com">http://www.datastead.com<br>
</a> Mirror:
<a href="http://www.datastead.info">http://www.delphicity.com</a></font></p>
<p><font face="Verdana" size="2"> Contact: <a href="mailto:contact@datastead.com">contact@datastead.com</a></font><br>
<font face="Verdana" size="2"> Support: <a href="mailto:support@datastead.com">support@datastead.com</a></font></p>
<p> </p>
<ul>
<li>
<h3><a href="#Description - Features - Registration"><font face="Verdana" size="2">Description -
Features - Registration</font></a></h3>
</li>
<li>
<h3><font face="Verdana" size="2"><a href="#License Agreement">License agreement</a></font></h3>
</li>
<li>
<h3><a href="#FAQ - HowTo"><font face="Verdana" size="2">FAQ - How To</font></a></h3>
</li>
</ul>
<!--webbot bot="Include" u-include="man_comm.htm" tag="BODY" startspan --><font class="body">
<ul>
<li>
<p><a href="#package install">Package Install</a></p>
</li>
<li><a href="#quick start guide">Quick start guide</a></li>
</ul>
<ul>
<li><a href="#Initialization">Initialization</a></li>
</ul>
<ul>
<li><a href="#Zooming">Zooming</a></li>
</ul>
<ul>
<li>
<p><a href="#Single">Single frame capture</a></p>
</li>
<li>
<p><a href="#Grabber">Multiple frame capture with the Frame Grabber</a></p>
</li>
</ul>
<ul>
<li>
<p><a href="#Commonly used methods, properties and events">Common
methods, properties and events</a></p>
<ul>
<li><a href="#Open_">Open</a></li>
<li><a href="#Playback">Playback</a></li>
<li><a href="#Appearance">Appearance</a></li>
<li><a href="#Zoom">Zoom</a></li>
<li><a href="#Single2">Single frame capture</a></li>
<li><a href="#Multiple2">Multiple frame capture with the Frame Grabber</a></li>
<li><a href="#Position">Position</a></li>
<br><br>
</ul>
</li>
<li>
<p><a href="#methods">Methods</a></p>
</li>
<li>
<p><a href="#Public properties">Public
Properties</a></p>
</li>
<li>
<p><a href="#Published properties">Published
Properties</a></p>
</li>
<li>
<p><a href="#Events">Events</a></p>
</li>
<li>
<p><a href="#Enumerated">Enumerated
types</a></p>
</li>
<li>
<p><a href="#Global Variables">Global functions and variables</a></p>
</li>
</ul>
<br>
<br>
<p class=t1><a name="package install">Package install</a></p>
<p class="t2"><i> <br>
Update packs</i>
</p>
<p>The TActiveMovie component binaries have been built with the latest version
of the Borland's update packs applied to the respective versions of Delphi and
C++Builder. <br>
Be sure to apply all the Borland's update packs corresponding to your compiler,
to prevent problems caused by mismatches between versions of the librairies.
</p>
<p class="t2">1. If a previous
TActiveMovie package is already installed, remove it first:</p>
<p>- Components | Install Packages<br>
- Click on "datastead TActiveMovie"<br>
- Click "Remove"<br>
- Click "Yes"<br>
- Click "Ok".<br>
- search for "TAMovie.*" and "AMov*.*" files in your Borland directories and delete them, to be certain that old units will not remain in the search paths (causing later raw errors). </p>
<p class="t2">2. Install the
current package:</p>
<p>- Unzip the archive in a folder of your choice
(e.g. c:\amovie)</p>
<p>- According to your Delphi or C++Builder
version,<br>
copy all the Delphi?\*.* or CBuilder?\*.* archive files to the
Borland\Delphi?\Imports or \Borland\CBuilder?\Imports directory,<br>
<br>
- Run Delphi or C++Builder,</p>
<p>- Select Component | Install packages,</p>
<p>- Press the "Add" button,</p>
<p>- Locate the TAMovie.bpl file in the Imports
directory and select it,</p>
<p>- Select Open</p>
<p>- Select Ok</p>
<p>- Check the ActiveX tab in the right of the
component palette. The TActiveMovie object should have been added.</p>
<P CLASS="t2"><I> Note:</I></P>
<P>If you get a "TAMovie.??? file not found" error when compiling or
linking your project:</P>
- go to Tools | Environment Options | Library, and check that you have
;$(DELPHI)\Imports (Delphi) or ;$(BCB)\Imports
(C++Builder) in the Library path, otherwise add it at the end of the edit field.
<P>- go to Project | Options | Packages, check "Build with runtime
package", go to the end of the packages edit field, remove ";TAMovie",
and then uncheck "Build with runtime package".
<P> </P>
<p class="t1"><a name="quick start guide">
Quick start guide</a></p>
<p>- place a TActiveMovie component from the
ActiveX palette on your Project,</p>
<p>- place a button on your Project. In the ButtonClick event, add the following code:<br>
ActiveMovie1.FileName := 'your media file
path or URL';<br>
ActiveMovie1.OpenSync;</p>
<p>- run your project.<br>
</p>
<p class="t1"><a name="Zooming">
Zooming</a></p>
<p>- place a TActiveMovie component from the
ActiveX palette on your Project,</p>
<p>- disable the ShowControls property,</p>
<p>- set the DisplaySize property to mpCustomSize,</p>
<p>- at runtime, change the ActiveMovie1.ZoomSize
value from 100 (original size) to the desired percentage.</p>
<p>
</p>
<p class="t1"><a name="Single">Single</a> frame capture</p>
<p class="t2">Overview</p>
<p>The single frame capture is invoked by calling one of the following
functions, according to the destination of the frame:</p>
<blockquote>
<p > function <a href="#CaptureFrameToBmpFile"> CaptureFrameToBmpFile</a> (var FileName: String): WordBool;<br>
function <a href="#CaptureFrameToJPEGFile"> CaptureFrameToJPEGFile</a> (var FileName: String): WordBool;<br>
function <a href="#CaptureFrameToImage"> CaptureFrameToImage</a> (Image: TImage): WordBool;<br>
function <a href="#CaptureFrameToBitmap"> CaptureFrameToBitmap</a> (Bitmap: TBitmap): WordBool;</p>
</blockquote>
</font>
<p ><font class="body">For <a href="#CaptureFrameToBmpFile"> CaptureFrameToBmpFile</a>
and <a href="#CaptureFrameToJPEGFile"> CaptureFrameToJPEGFile</a>, the FileName property
is passed as var, allowing TActiveMovie to automatically generate a file name
and return it by the FileName parameter if FileName was assigned an an empty
string (otherwise the FileName value passed to the function is used to save the
file). E.g.:</font></p>
<blockquote>
<p class="code" ><font class="body">1. you give a file name to save the BMP or
JPEG file:<br>
</font>procedure TForm1.Button1Click(Sender: TObject);<br>
var<br>
FileName: String;<br>
begin<br>
<b> FileName:= 'c:\myfolder\myfile.jpg';<br>
</b> if ActiveMovie1.CaptureFrameToJPEGFile (FileName) then begin<br>
ShowMessage ('created');<br>
end;<br>
end;</p>
<p class="code" >
<font class="body">2. you let TActiveMovie automatically assign a filename and create a file in
the <a href="#StoragePath">StoragePath</a> directory according to the
<a href="#AutoFileName">AutoFileName</a> property on a sequential increment (AutoFileName
= fnSequential) or time basis (AutoFileName
= fnDateTime). In this case simply assign an empty string to the FileName
variable passed to the function:<br>
</font>procedure TForm1.Button1Click(Sender: TObject);<br>
var<br>
FileName: String;<br>
begin<br>
<font color="#000080"> // an empty string = "please generate
automatically a file name"<br>
</font>
<b> FileName:= '';<br>
</b> if ActiveMovie1.CaptureFrameToJPEGFile (FileName) then begin<br>
<font color="#000080"> // FileName contains now
the file name generated by TActiveMovie<br>
</font> ShowMessage (FileName + 'created');<br>
end;<br>
end;</p>
</blockquote>
<p class="t2" >Fast frame capture</p>
<p ><font class="body">If <a href="#FGrabber_Enabled">FGrabber_Enabled</a> is
enabled, the frame capture is processed by the frame grabber: the frame capture
is faster, but this feature requires DirectX8.
</font></p>
<p ><font class="body"><br>
<br>
</p>
<p class="t1">Multiple frame capture with the Frame <a name="Grabber">Grabber</a>
(DirectX8 required)</p>
<p >
The frame grabber allows to capture quickly several frames (or all the frames)
from only 1 statement call. </p>
<p ><i>This feature is based on DirectX8, so it won't be available if a previous
version of DirectX is installed on the platform where the application runs.</i></p>
<p >
The frame grabber works asynchronously. That means that you set the
grabber parameters, you call <a href="#FGrabber_CaptureFrameTo">FGrabber_CaptureFrameTo</a>
one time, and then the captured frames are returned by
the <a href="#OnFGrabberCaptureCompleted">OnFGrabberCaptureCompleted</a> event.</p>
<p class="t2">
Using the frame grabber to capture 1 frame</p>
<p >
- set <a href="#FGrabber_BurstMode"> FGrabber_Enabled</a> = true to enable the frame grabber (this must be done
before opening the clip),<br>
- open the clip,<br>
- set <a href="#FGrabber_BurstMode">FGrabber_BurstMode</a> = False do get only 1
frame<br>
- call <a href="#FGrabber_CaptureFrameTo">FGrabber_CaptureFrameTo</a><br>
- the captured frame is returned by
the <a href="#OnFGrabberCaptureCompleted">OnFGrabberCaptureCompleted</a> event.</p>
<p class="t2">Using the frame
grabber to capture more than 1 frame</p>
<p >
- set <a href="#FGrabber_Enabled"> FGrabber_Enabled</a> = true to enable the frame grabber (this must be done
before opening the clip),<br>
- open the clip,<br>
- set <a href="#FGrabber_BurstMode">FGrabber_BurstMode</a> = true to allow more
than 1 frame,<br>
- set <a href="#FGrabber_BurstCount">FGrabber_BurstCount</a> = the number of frames to capture, or 0 to capture all the
frames,<br>
- set <a href="#FGrabber_BurstInterval">FGrabber_BurstInterval</a> = 0 to capture
successive frames, or a value n to capture 1 frame each n frames, until
BurstCount has been reached.<br>
- call <a href="#FGrabber_CaptureFrameTo">FGrabber_CaptureFrameTo</a> <a href="#FGrabber_CaptureFrameTo"><br>
</a> - the captured frames are returned by
the <a href="#OnFGrabberCaptureCompleted">OnFGrabberCaptureCompleted</a> event until
BurstCount is reached (if BurstCount = 0, until BurstMode is disabled or the end
of the clip has been reached).</p>
<p class="t2"><a href="#FGrabber_CaptureFrameTo">FGrabber_CaptureFrameTo</a> parameters</p>
<p>Frames are returned by
the <a href="#OnFGrabberCaptureCompleted">OnFGrabberCaptureCompleted</a> event as a
TBitmap, a BMP file or a JPEG file according to the Dest parameter
passed to the <a href="#FGrabber_CaptureFrameTo">FGrabber_CaptureFrameTo</a>
procedure.
Dest can take one of the following values:<br>
fcTBitmap: captures the current frame to a memory bitmap,<br>
fcBmpFile: captures the current frame to a BMP file,<br>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -