arobertson
Content Type
Profiles
Forums
Store
Blog
Product
Showcase
FAQ
Downloads
Posts posted by arobertson
-
-
Well since that worked, I have now been spun into another issue that I just can't jump over.
When I attempt to get the scale from the code below, it provides me with the scaleX 1.6 and scaleY 1.6 which is fine and dandy, but once I apply this scale ratio to my drawings they are off.
For example, original file is 486/480 and when it resizes it bumps up to 768/777.6 which, if I use my calculator, provides me with a X scale ratio of 1.580247 and Y scale ratio of 1.62 and not the ratios provided above.
Below is my code:
//Go and fetch the native width/height of the image. var rawContent:DisplayObject = imageGSAP.rawContent; var bounds:Rectangle = rawContent.getBounds(rawContent); trace(event.target + " for image " + imageCount + " is complete!"); trace(event.target + " original width is " + bounds.width + " with a height of " + bounds.height); trace(event.target + " current width is:" + rawContent.width + " with a height of " + rawContent.height); trace(event.target + " current scale is X:" + rawContent.scaleX + " and scale Y:" + rawContent.scaleY);
bounds.width = 486
bounds.height = 480
rawContent.width = 768
rawContent.height = 777.6
rawContent.scaleX = 1.6
rawContent.scaleY = 1.6
-
Carl - superb! You're the man. Thanks for the quick response and reference. Always a pleasure.
- 1
-
Good day to all, I have searched through the documents but am not able to easily find my answer so I am hoping this is a quick response for the professionals. Is there an easy way to find out the scale ratio of the image that is imported at run time?
loader = new ImageLoader(theURL+"SEN"+viewNum+".jpeg", {name:"SuperEnhanced_View3", estimatedBytes:3000, container:xrayLoader, x:408, y:384, width:820, height:768, scaleMode:"proportionalInside", centerRegistration:true, alpha:0, onInit:onImageLoad, onError:errorHandlerMain});
Reason: I am trying to place an overlay over the image in the correct location but when the image is scaled, the object needs to be modified accordingly.
Thanks,
Andrew
-
I switched the settings to NETWORK only and then the following came up...
Attempting to launch and connect to Player using URL E:\Training Development\...............\Evaluation.swf[SWF] E:\Training Development\.................\Evaluation.swf - 144326 bytes after decompressionWarning: Failed to load policy file from http://locallms/crossdomain.xml*** Security Sandbox Violation ***Connection to http://locallms/coursecontent/BW_View2.jpg?cacheBusterID=1470946166727&purpose=audit'>http://locallms/coursecontent/BW_View2.jpg?cacheBusterID=1470946166727&purpose=audit halted - not permitted from file:///E|/Training%20Development/................./Evaluation.swfLoading error on ImageLoader 'BlackWhite_View2' (http://locallms/coursecontent/xraypertstudy/xrayevalimages/1/BW_View2.jpg): Error #2048: Security sandbox violation: file:///E|/Training%20Development/..................../Evaluation.swf cannot load data from http://locallms/coursecontent/BW_View2.jpg?cacheBusterID=1470946166727&purpose=audit'>http://locallms/coursecontent/BW_View2.jpg?cacheBusterID=1470946166727&purpose=audit.Error occured with ImageLoader 'BlackWhite_View2' (http://locallms/coursecontent/BW_View2.jpg): ImageLoader 'BlackWhite_View2' (http://locallms/coursecontent/BW_View2.jpg) > Error #2048: Security sandbox violation: file:///E|/Training%20Development........................../BW_View2.jpg?cacheBusterID=1470946166727&purpose=audit.Error: Request for resource at http://locallms/coursecontent/............./BW_View2.jpg?cacheBusterID=1470946166727&purpose=audit by requestor from file:///E|/Training%20Development/.............../Evaluation.swf is denied due to lack of policy file permissions.
-
That's a shame that the market indicated a new direction because these tools are sharp.
I ran in debug mode and was wondering if you could make sense of the errors?
Cheers.
Andrew
Attempting to launch and connect to Player using URL E:\Training Development\......\Evaluation.swf [SWF] E:\Training Development\......\Evaluation.swf - 144760 bytes after decompression *** Security Sandbox Violation *** Connection to http://locallms/coursecontent/images/1/BW_View2.jpg?purpose=audit&cacheBusterID=1470944960635 halted - not permitted from file:///E|/Training%20Development/....../Evaluation.swf -- Untrusted local SWFs may not contact the Internet. SecurityError: Error #2028: Local-with-filesystem SWF file file:///E|/Training%20Development/....../Evaluation.swf cannot access Internet URL http://locallms/coursecontent/images/1/BW_View2.jpg?purpose=audit&cacheBusterID=1470944960635. at flash.net::URLStream/load() at com.greensock.loading.core::LoaderItem/auditSize()[E:\Training Development\..........\EN\Flash\com\greensock\loading\core\LoaderItem.as:116] at com.greensock.loading::LoaderMax/_auditSize()[E:\Training Development\..........\EN\Flash\com\greensock\loading\LoaderMax.as:731] at com.greensock.loading::LoaderMax/_loadNext()[E:\Training Development\..........\EN\Flash\com\greensock\loading\LoaderMax.as:755] at com.greensock.loading::LoaderMax/_load()[E:\Training Development\..........EN\Flash\com\greensock\loading\LoaderMax.as:293] at com.greensock.loading.core::LoaderCore/load()[E:\Training Development\..........\EN\Flash\com\greensock\loading\core\LoaderCore.as:173] at xrayEvaluation_fla::MainTimeline/loadImg()[Evaluation_fla.MainTimeline::frame1:97] at xrayEvaluation_fla::MainTimeline/xmlLoaded()[Evaluation_fla.MainTimeline::frame1:56] at flash.events::EventDispatcher/dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent() at flash.net::URLLoader/onComplete() Cannot display source code at this location.
-
Hello,
I've just stumbled on this wicked product and I don't know how I've survived without it - but I am having a bit of a problem. I've been able to build a mini-simulation application that functions flawlessly when I test the movie within Flash CS6 but when I export to SWF/HTML the images do not load. Is there anything that I should look at (settings? code?)? Any help would be greatly appreciated.
Cheers,
Andrew
GSAP Scale
in GSAP (Flash)
Posted
Well, I think i answered my on problem. Was it because I had the incorrect scaleMode set (proportionalInside vs proportionalOutside)??