MACROMEDIA FLASH COMMUNICATION SERVER MX-SERVER-SIDE COMMUNICATION ACTIONSCRIPT DICTIONARY Spezifikationen Seite 210

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken
  • Seite
    / 369
  • Inhaltsverzeichnis
  • LESEZEICHEN
  • Bewertet. / 5. Basierend auf Kundenbewertungen
Seitenansicht 209
Client-Side Communication ActionScript 19
Example
The following example displays the name of the default camera in the Output window. In
Windows, this name is the same as the device name listed in the Scanners and Cameras
properties sheet.
myCam = Camera.get();
trace("The camera name is: " + myCam.name);
See also
Camera.get, Camera.names
Camera.names
Availability
Flash Player 6.
Flash Communication Server MX (not required).
Usage
Camera.names
Note: The correct syntax is Camera.names. To assign the return value to a variable, use syntax like
camArray = Camera.names. To determine the name of the current camera, use activeCamera.name.
Description
Read-only class property; retrieves an array of strings reflecting the names of all available cameras
without displaying the Flash Player Privacy Settings panel. This array behaves the same as any
other ActionScript array, implicitly providing the zero-based index of each camera and the
number of cameras on the system (by means of
Camera.names.length). For more information,
see the “Array (object)” entry in the online Flash ActionScript Dictionary in the Flash MX
Help menu.
Calling
Camera.names requires an extensive examination of the hardware, and it may take several
seconds to build the array. In most cases, you can just use the default camera.
Example
The following example uses the default camera unless more than one camera is available, in which
case the user can choose which camera to set as the default camera.
camArray = Camera.names;
if (camArray.length == 1){
Camera.get();
}
else
System.showSettings(3);
Camera.get();
See also
Camera.get, Camera.index, Camera.names
Seitenansicht 209
1 2 ... 205 206 207 208 209 210 211 212 213 214 215 ... 368 369

Kommentare zu diesen Handbüchern

Keine Kommentare