File: Sound.hx

package info (click to toggle)
haxe 1%3A4.2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 42,984 kB
  • sloc: ml: 132,401; ansic: 2,403; makefile: 436; java: 365; cs: 336; cpp: 318; python: 315; sh: 75; objc: 64; php: 45; xml: 30; javascript: 11
file content (25 lines) | stat: -rw-r--r-- 1,474 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package flash.media;

extern class Sound extends flash.events.EventDispatcher {
	@:flash.property var bytesLoaded(get,never) : UInt;
	@:flash.property var bytesTotal(get,never) : Int;
	@:flash.property var id3(get,never) : ID3Info;
	@:flash.property var isBuffering(get,never) : Bool;
	@:flash.property @:require(flash10_1) var isURLInaccessible(get,never) : Bool;
	@:flash.property var length(get,never) : Float;
	@:flash.property var url(get,never) : String;
	function new(?stream : flash.net.URLRequest, ?context : SoundLoaderContext) : Void;
	function close() : Void;
	@:require(flash10) function extract(target : flash.utils.ByteArray, length : Float, startPosition : Float = -1) : Float;
	private function get_bytesLoaded() : UInt;
	private function get_bytesTotal() : Int;
	private function get_id3() : ID3Info;
	private function get_isBuffering() : Bool;
	private function get_isURLInaccessible() : Bool;
	private function get_length() : Float;
	private function get_url() : String;
	function load(stream : flash.net.URLRequest, ?context : SoundLoaderContext) : Void;
	@:require(flash11) function loadCompressedDataFromByteArray(bytes : flash.utils.ByteArray, bytesLength : UInt) : Void;
	@:require(flash11) function loadPCMFromByteArray(bytes : flash.utils.ByteArray, samples : UInt, ?format : String, stereo : Bool = true, sampleRate : Float = 44100) : Void;
	function play(startTime : Float = 0, loops : Int = 0, ?sndTransform : SoundTransform) : SoundChannel;
}