header
ask question
Click here to ask Question Now Its free No registration required. Flash, Flex, Flash Media Server, ActionScript,Adobe Air. Most questions receive a response in an hour.
Dan008
Points:20
Posts:0

9/20/2010 6:55:51 PM

Title: Full browser AS2 Flash without distorations.


hi i am doing a full flash site as well trying to fit my flash to any browser in 100% fit without distortions. As currently it does fit 100% in any browser but it stretches. Anyone will be able to help?

I am using this script below.






stop();  
this.onResize = function() {  
    //-- Called when browser is resized.  
    this.sample_mc._x = (Stage.width/2)-(this.green_mc._width/2);  
    this.sample_mc._y = (Stage.height/2)-(this.green_mc._height/2);  
    this.sample_mc = Stage.width+"x"+Stage.height;  
};  
Stage.scaleMode = "exactFit";  
Stage.align = "TL";  
Stage.showMenu = false;  
Stage.addListener(this);  
this.onResize();   

Please help. Dan.



1
Rex
Points: 1280
Posts:0
9/20/2010 11:25:15 PM



Dan it quite obvious that if we try to fit something in a resolution it was not created for then it will distort or cropped. Using exactfit will stretch the website to fit the available area without keeping the proportions, so it will distort. showall option can be used to scale it to fit the browser without distortion. but if the browser area is not in proportion with the flash file , borders will appear.


2
Dan008
Points: 20
Posts:0
9/21/2010 1:13:55 AM



Thanks Rex. But are there any other options to this?

Because I have searched over the net, on google for hours and days. Does the stage size have to be in relations to the screen size? For example I did the stage size in flash was 700px X 500px.


Thanks.


Post your Reply
Name  

Email

Type your Reply or Answer

Are you human? What is 4+3 



Members Login

Email  
Password
Forgot Password





This website focus on: Flash | Flex | FMS | RED5 | WOWZA | Flash Media Server | Adobe AIR | ActionScript,Flash Solutions | Flash Question | Flash Answers | Flash Developers | Flash Problem, Flash Help, Flash bugs, Flash workaround | Flash Blog | Flex Question Answers | Flash Forum | Flex Development | Actionscript development | Flash development | Adobe AIR development
Copyright © 2008 AskMeFlash.com. All rights reserved. Privacy Policy | Terms & Conditions