Hi guys....
I am trying to get the percentage x coordinate of a MC. For example, My MC is 500px wide and 20px height. When I clicked the part of my MC, I want to get the percentage of my MC' x coordinate... (20% will be 100px of my MC...)..Anyone knows how to do it?? Thanks..
my code
progressBa.addEventListener(MouseEvent.CLICK, bar...
Hello, how can I draw strings onto BitmapData, is there something like Java´s Graphics.drawString()?
...
Hi guys..
I am trying to build a youtube player in Actionscript 3 and I got a questions regarding video cue. I have my loaded progress bar and playheard in my player. Everything works fine if user just watch the video from beginning till end.
However, if the user clicks on my progress bar to jump to the specific part of the video, ...
I have a textInput field form that's not displaying the characters it should when typed into. E.g. when the letter "æ" on my keybard is pressed "¾" shows up. This only happens once the flash movie is being displayed in a browser (that is embedded in html), preview through flash does not have this problem. The font is properly embedded as...
Here is a simple example of what I mean:
private var ex:String="day";
......
closeWindows(ex);
trace(ex);//I would like it to trace "night"
......
//this can be in another class, we assume that the "ex" variable can't be accessed directly
private function closeWindows(context:String):void {
context = "night"
}
Somehow I would ne...
Hi guys..
Simple question..I was wondering when you guys extends EventDispatcher in your class. It seems to me that as long as we have import event package, we can dispatchEvent without problems....I saw sometime people extends EventDispatcher in their class...not sure why...anyone care to explain? Thanks a million...
...
Hello, I've encountered curious problem, and I'm wondering what is wrong.
When I define for example Sprite and I draw inside rectangle 20 x 20 px, then when measured on screen it have something like 33 x 33 px, while swf window which was defined as 400 x 300 corresponds to definition well.
Where is the problem?
...
Hello, what would be your recommendation for drawing shapes (rects, circles...) onto BitmapData, and how to effectively switch between colors.
Is there any way to get graphics context from BitmapData so I could easily paint shapes using graphics.draw...()?
...
Hi guys...
I am trying to build a as3 only search api project..
I am checking this guys's code here...
http://blog.martinlegris.com/2010/05/28/sample-code-using-the-youtube-as3-api-with-the-youtube-player-api/
He has following code...
protected function doSearchResults(evt:VideoFeedEvent):void
{
if(_requestId == evt.requestId)
...
Is there any inbuild function to find out the last occurrence of a string pattern in a string in action script .
...
Hi guys..
I am trying to build my youtube video search project in AS3.. and I found the following link...
http://blog.martinlegris.com/2008/02/20/youtube-data-api-as3-youtubeclient-functions-associated-events/
His library has
YouTubeClient.getStandardFeed(…)
Event: StandardVideoFeedEvent.STANDARD_VIDEO_DATA_RECEIVED
.feed: VideoF...
I get a raw data from Microphone's SampleDataEvent, and I want to encode this data before streaming to my server. So I'd like to know if there any standard audio encoder provided in actionscript3? Or do I have to implement it myself?
I know that the Microphone class provide 2 codec (Nellymoser and Speex) that can be used when sending a ...
In actionscript I can use code below to register a callback when there is motion captured:
cam.setMotionLevel (35,3000);
cam.addEventListener (ActivityEvent.ACTIVITY, checkCamAction);
Is that available in FMLE?
UPDATE
Or is it possible to access the same camera from both flash player and FMLE at the same time?
...
i'm trying to embed a swf to my as3 flex project like this:
[Embed(source = "../assets/next_button.swf")]
[Bindable]
protected var nextButtonClass:Class;
protected var next_btn:MovieClip = next_btn = new nextButtonClass() as MovieClip;
// ...
next_btn.addEventListener(MouseEvent.CLICK, onAdChange);
next_button.swf is as2 and created w...
Hi guys..
I am trying to pass custom event data from 1 class to another class...here is my codes..
a.as
private function onClick(event:MouseEvent):void{
dispatchEvent(new YouTubeSearchEvent(YouTubeSearchEvent.CHANGE_VIDEO_READY, videoId));
}
b.as
private var newVideoID:String;
public function get selectedVideoID():String{...
Hi Guys..
I am trying to create a scrollBar for my MC which contains several mc horizontally. I wanted to apply ULscrollBar for my MC container so I can scroll for move small MC but I couldn't get it to work...I would appreciate if someone can help me about it. (there is no scroll head for me to drag...) Thanks...
cont=new videoC...
I have an image of type '.bmp' (NOT jpeg or png). I am trying to embed it using the following code.
[Embed(source="images/door0091.bmp")]
private var door0091_class:Class;
private var door91:Bitmap = new door0091_class();
On compiling, the code throws following error.
'door0091.bmp' does not have a recognized extension, and a mimeT...
Hi there,
I'm writing a flex app, which must record an audio and then playback. It records just fine, I can hear the flv on the server, but when it comes to the playback it cuts the end a little bit, and each time I ask to reproduce again it cuts a little bit more. What can it be? I guess it's something related to buffer management, but...
I want to develop an AIR application that will let users of my website download multiple files in a single process. My database stores details of all the files uploaded by a user so I want them to be able to simply choose a location on local disk then download all files they have uploaded to this location.
Are there any good tutorials ...
What gives the best performance? (edited to include another option)
var myVec:Vector.<Number> = new Vector.<Number>();
for (...)
// Do stuff - example: myVec.push(Math.random());
// Need to empty and repopulate vector
myVec.splice(0, myVec.length);
// OR
myVec = new Vector.<Number>();
// OR
myVec.length = 0;
...