Search Results

Search found 36 results on 2 pages for 'mxmlc'.

Page 1/2 | 1 2  | Next Page >

  • MXMLC Ant task results in java.lang.OutOFMemoryError

    - by Mims H. Wright
    I'm making a change to a set of code for a Flex project that I didn't write and was set up to compile using ant tasks. I assume that the codebase was stable at the last checkin but I'm running into memory issues when trying to build a project using MXMLC and ant (see stack trace below). Before, I was just getting an out of memory error. I tried using a different machine and got this more verbose exception (including problems with the image fetcher). I've tried using various versions of the SDK, I've tried replacing the <mxmlc> tag with <exec executable="mxmlc"> with no luck. Here is my java version in case that has anything to do with it: » java -version java version "1.6.0_20" Java(TM) SE Runtime Environment (build 1.6.0_20-b02-279-10M3065) Java HotSpot(TM) 64-Bit Server VM (build 16.3-b01-279, mixed mode) Any help would be appreciated. Thanks! Buildfile: build.xml compileSWF: [echo] Compiling main.swf... [mxmlc] Loading configuration file /Applications/Adobe Flash Builder 4 Plug-in/sdks/4.0.0beta2/frameworks/flex-config.xml [mxmlc] Exception in thread "Image Fetcher 0" java.lang.OutOfMemoryError: Java heap space [mxmlc] at java.awt.image.PixelGrabber.setDimensions(PixelGrabber.java:360) [mxmlc] at sun.awt.image.ImageDecoder.setDimensions(ImageDecoder.java:62) [mxmlc] at sun.awt.image.JPEGImageDecoder.sendHeaderInfo(JPEGImageDecoder.java:71) [mxmlc] at sun.awt.image.JPEGImageDecoder.readImage(Native Method) [mxmlc] at sun.awt.image.JPEGImageDecoder.produceImage(JPEGImageDecoder.java:119) [mxmlc] at sun.awt.image.InputStreamImageSource.doFetch(InputStreamImageSource.java:246) [mxmlc] at sun.awt.image.ImageFetcher.fetchloop(ImageFetcher.java:172) [mxmlc] at sun.awt.image.ImageFetcher.run(ImageFetcher.java:136) [mxmlc] /src/com/amtrak/components/map/MapAsset.mxml: Error: exception during transcoding: Failed to grab pixels for image /src/assets/embed_assets/images/zoomed_map_wide.jpg [mxmlc] [mxmlc] /src/com/amtrak/components/map/MapAsset.mxml: Error: Unable to transcode /assets/embed_assets/images/zoomed_map_wide.jpg. [mxmlc] [mxmlc] Error: Java heap space [mxmlc] [mxmlc] java.lang.OutOfMemoryError: Java heap space [mxmlc] at java.util.ArrayList.<init>(ArrayList.java:112) [mxmlc] at macromedia.asc.util.ObjectList.<init>(ObjectList.java:30) [mxmlc] at macromedia.asc.parser.ArgumentListNode.<init>(ArgumentListNode.java:30) [mxmlc] at macromedia.asc.parser.NodeFactory.argumentList(NodeFactory.java:116) [mxmlc] at macromedia.asc.parser.NodeFactory.argumentList(NodeFactory.java:97) [mxmlc] at flex2.compiler.mxml.ImplementationGenerator.generateBinding(ImplementationGenerator.java:563) [mxmlc] at flex2.compiler.mxml.ImplementationGenerator.generateBindingsSetupFunction(ImplementationGenerator.java:864) [mxmlc] at flex2.compiler.mxml.ImplementationGenerator.generateBindingsSetup(ImplementationGenerator.java:813) [mxmlc] at flex2.compiler.mxml.ImplementationGenerator.generateInitializerSupportDefs(ImplementationGenerator.java:1813) [mxmlc] at flex2.compiler.mxml.ImplementationGenerator.generateClassDefinition(ImplementationGenerator.java:1005) [mxmlc] at flex2.compiler.mxml.ImplementationGenerator.<init>(ImplementationGenerator.java:201) [mxmlc] at flex2.compiler.mxml.ImplementationCompiler.generateImplementationAST(ImplementationCompiler.java:498) [mxmlc] at flex2.compiler.mxml.ImplementationCompiler.parse1(ImplementationCompiler.java:196) [mxmlc] at flex2.compiler.mxml.MxmlCompiler.parse1(MxmlCompiler.java:168) [mxmlc] at flex2.compiler.CompilerAPI.parse1(CompilerAPI.java:2851) [mxmlc] at flex2.compiler.CompilerAPI.parse1(CompilerAPI.java:2804) [mxmlc] at flex2.compiler.CompilerAPI.batch2(CompilerAPI.java:446) [mxmlc] at flex2.compiler.CompilerAPI.batch(CompilerAPI.java:1274) [mxmlc] at flex2.compiler.CompilerAPI.compile(CompilerAPI.java:1488) [mxmlc] at flex2.compiler.CompilerAPI.compile(CompilerAPI.java:1375) [mxmlc] at flex2.tools.Mxmlc.mxmlc(Mxmlc.java:282) [mxmlc] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [mxmlc] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [mxmlc] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [mxmlc] at java.lang.reflect.Method.invoke(Method.java:597) [mxmlc] at flex.ant.FlexTask.executeInProcess(FlexTask.java:280) [mxmlc] at flex.ant.FlexTask.execute(FlexTask.java:225) [mxmlc] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288) [mxmlc] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [mxmlc] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [mxmlc] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [mxmlc] at java.lang.reflect.Method.invoke(Method.java:597) BUILD FAILED /src/build.xml:49: mxmlc task failed

    Read the article

  • Including configuration files while compiling a Flex application with MXMLC

    - by Daniel
    Hello there, I'm using: - Flex SDK 3.5.0 - Parsley 2.2.2. - Flash Builder 4 Down in my src folder (which is configured as part of the source path in the Flash Builder), I have a logging.xml which I configure via Parsley: FlexLoggingXmlSupport.initialize(); XmlContextBuilder.build("com/company/product/util/log/logging.xml"); When I run my application through Flash Builder, the XmlContentBuilder seems to locate the logging.xml (the implementation is a regular URLLoader one). When I compile my application using MXMLC (whether in Ant or command-line), and then run the swf, I get the following error: Cause(0): Error loading com/company/product/util/log/logging.xml: Error in URLLoader - cause: Error #2032: Stream Error. URL: file:///C|/workspace/folder01/product/target/com/company/product/util/log/logging.xml - cause: Error #2032: Stream Error. URL: file:///C|/workspace/folder01/product/target/com/company/product/util/log/logging.xml Here is the MXMLC tag in Ant: <mxmlc file="${product.src.dir}/com/company/product/view/Main.mxml" output="${product.target.dir}/${product.release.filename}" keep-generated-actionscript="false"> <load-config filename="${FLEX_HOME}/frameworks/flex-config.xml" /> <!-- source paths --> <source-path path-element="${FLEX_HOME}/frameworks" /> <compiler.source-path path-element="${product.src.dir}" /> <compiler.source-path path-element="${product.locale.dir}/{locale}" /> <compiler.library-path dir="${product.basedir}" append="true"> <include name="libs" /> </compiler.library-path> <warnings>false</warnings> <debug>false</debug> </mxmlc> And here is the command line: \mxmlc.exe -output "C:\temp\Rap.swf" -load-config "C:\Program Files\Adobe\Adobe Flash Builder 4 Plug-in\sdks\3.5.0\frameworks\flex-config.xml" -source-path "C:\Program Files\Adobe\Adobe Flash Builder 4 Plug-in\sdks\3.5.0\frameworks" C:\workspace\folder01\product\src C:\workspace\folder01\product\locale\en_US -library-path+=C:\workspace\folder01\product\libs -file-specs C:\workspace\folder01\product\src\com\company\product\view\main.mxml Now perhaps I don't get this correctly, but as far as I understand the SWF should be compiled with all of the resources in the paths I give MXMLC as source-paths. For some reason it seems that the XML file is not compiled into the SWF, hence the relative path of the XmlContentBuilder isn't located successfully. I could not find any argument to provide the MXMLC with that might solve this. I tried using the -dump-config option with the Flash Builder's compiler, then giving that configuration to MXMLC, but it didn't work either. I tried providing the XmlContentBuilder with an absolute path. That worked fine when I compiled with MXMLC via Ant, but still didn't work when I used MXMLC in the command-line... I'd be happy to be enlightened here, regarding all subjects - using MXMLC, accessing resources with relative paths, configuring logging in Parsley, etc. Many thanks in advance, Daniel

    Read the article

  • Flex, Ant, mxmlc and conditional compilation

    - by Rezmason
    My ActionScript project builds with several compile-time specified constants. They are all Booleans, and only one of them is true at any given time. The rest must be false. When I represented my build process in a bash script, I could loop through the names of all these constants, set one of them to be true and the rest to be false, then concatenate them onto a string to be inserted as a set of arguments passed to mxmlc. In Ant, looping is more complicated. I've tried the ant-contrib for tag: <mxmlc file='blah' output='blah'> <!- ... -> <for list='${commaSeparatedListOfConstNames}' param='constName'> <sequential> <define> <name>${constName}</name> <value>${constName} == ${theTrueConst}</value> <!-- (mxmlc's define arguments can be strings that are evaluated at compile time) --> </define> </sequential> </for> </mxmlc> Long story short, ant-contrib tags like the for tag can't go in the mxmlc task. So now I'm using Ant's propertyregex to take my list of arguments and format them into a set of define args, like my old bash script: <propertyregex property='defLine.first' override='false' input='${commaSeparatedListOfConstNames}' regexp='([^\|]+)\,' replace='\1,false ' /> <propertyregex property='defLine.final' input='${defLine.first}' regexp='(@{theTrueConst}\,)false' replace='\1true' /> <!-- result: -define+=CONST_ONE,false -define+=CONST_TWO,false -define+=TRUE_CONST,true --> Now my problem is, what can I do with this mxmlc argument and the mxmlc task? Apparently arg tags can go inside the mxmlc task without it throwing an error, but they don't seem to have any effect. What am I supposed to do? How do I make this work with the mxmlc task?

    Read the article

  • MXMLC and 64bit JRE

    - by sascha
    Are there any workarounds to get the Flex compiler to work with a 64bit JRE? If I use an MXMLC task in an Ant buildfile in Eclipse it works fine but if I try to use MXMLC from the command line (or try the Run... command from FDT in Eclipse) it fails, telling me ... "Error loading: C:\Program Files\Java\jrrt-1.6.0\jre\bin\jrockit\jvm.dll" (this is with a 64bit JRockit runtime but that shouldn't matter).

    Read the article

  • compiling actionscript from command line using MXMLC

    - by I. J. Kennedy
    I have a tiny actionscript "project" consisting of two files, call them foo.as and bar.as. For reasons I won't go into, I really really want to build the .SWF from the command line, without setting up a formal project of any kind. Every compiler I've ever used lets you do this, but for the life of me I can't figure out how to coerce MXMLC into compiling these two files and linking them into a SWF. Naively, I try MXMLC foo.as bar.as but I'm informed that only one source file is allowed. Ok, supposing I compiled these two files separately, how would I link them together to get the final SWF? NOTE: The only reason I have two files instead of one is the requirement of only one class per file. I tried putting both classes in one file and making one of the classes "private" or "internal" but neither of these ideas worked. I would be ecstatic to find out I can put more than one class in a file (with only one being public).

    Read the article

  • using property file along with config file to be used with mxmlc

    - by whoopy_whale
    Hi, I'm trying to run mxmlc in the following manner. mxmlc -load-config+=mycfg.xml C:\\projects\\src\\main.mxml -output myswf.swf In the config file, I want to keep some values configurable, for example the paths of the external libraries. Is it possible to include a property file into the config file and use it as {property_name} in the config file? Or is it possible to pass certain arguments from the command line itself that will override/replace the corresponding values in the config file, like the -D option in the ant command? Please provide your suggestions.

    Read the article

  • Ant MXMLC task with arbitrary list of source/lib paths?

    - by sascha
    Does anyone know of a way to use the mxmlc task of the Flex Ant tasks with a user-definable list of source path or library paths? The idea is that the user can define an arbitrary list of source paths and/or library (swc) paths into an Ant properties file and the build file takes these values and evaluates them for use in the mxmlc task. Just wondering if there are any tricks (maybe utilizing filtering/string replacing) to get this working?

    Read the article

  • Ant and Flex-4 problem, MXMLC.jar not found !

    - by Ali
    Hi all, I updated a flex application from flex 3.5 to flex 4.0. We are using ant for compiling our project and we have a mxmlc task to handle the flex part. After the upgrade, our mxmlc task broke. Here is the task definition: <taskdef resource="flexTasks.tasks"> <classpath> <pathelement path="${FLEX_HOME}/ant/lib/flexTasks.jar"/> <pathelement path="${FLEX_HOME}/lib/flexTasks.jar"/> <fileset dir="${FLEX_HOME}/lib"> <include name="**/*.jar"/> </fileset> </classpath> </taskdef> And here is mxmlc task <mxmlc file="${src}/Main.mxml" output="${build}/main.swf" debug="true" target-player="10" services="../src/main/webapp/WEB-INF/flex/services-config.xml" context-root="/" > <compiler.library-path dir="${lib}"> <include name="*.swc"/> </compiler.library-path> <compiler.library-path dir="${FLEX_HOME}/frameworks/libs"> <include name="*.swc"/> </compiler.library-path> <compiler.library-path dir="${FLEX_HOME}/frameworks/libs/player/10.0"> <include name="*.swc"/> </compiler.library-path> <compiler.library-path dir="${FLEX_HOME}/frameworks/locale"> <include name="**/*"/> </compiler.library-path> </mxmlc> And we are getting: The class not found in jar file: mxmlc.jar I checked the ${FLEX_HOME}/lib folder and I can see the mxmlc.jar file there. I appreciate your comments for resolving this matter, Thanks, -A

    Read the article

  • Compiling CSS to SWF server side Java, What is the best practice?

    - by DataSurfer
    My project allows users to create custom css for our flex app. In regards to compiling the CSS into SWFs on the server side: Should I use the flex2.compiler.css.Compiler class in mxmlc-3.5.0.12683.jar? Or Should I invoke mxmlc from Runtime.getRuntime().exec()? The css.Compiler class is not very well documented. Does anyone have any examples that use this? For the Runtime exec method, what is the best way to package mxmlc into the maven build so its available to the server at runtime?

    Read the article

  • How to suppress Flash migration warnings (1090)

    - by aaaidan
    I get "migration issue" warnings when I use mouse/keyboard input handler names such as onMouseDown, onKeyUp, etc. These names are perfectly legal, but sensibly, we are now warned that their use is no longer automatic in ActionScript 3. I want to suppress these warnings, but without suppressing all other warnings, which I find useful. E.g., when I use code like this: protected override function onMouseDown(e:MouseEvent):void { I get an annoying warning like this: Warning: 1090: Migration issue: The onMouseDown event handler is not triggered automatically by Flash Player at run time in ActionScript 3.0. You must first register this handler for the event using addEventListener ( 'mouseDown', callback_handler). There are flex compiler (mxmlc) flags which can suppress actionscript warnings, or all warnings, but I don't want that. That's to general. Ideally I could suppress a specific error/warning number (Warning #1090). Halp?

    Read the article

  • Error in playing a swf file on internet explorer

    - by Rajeev
    In the below code i get an error saying Error #2007: Parameter url must be non-null on Ineternet explorer only.What am i doing wrong here html <OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" WIDTH="50" HEIGHT="50" id="myMovieName"> <PARAM NAME="movie" VALUE="/media/players/testsound.swf" /> <PARAM NAME="quality" VALUE="high" /> <PARAM NAME="bgcolor" VALUE="#FFFFFF" /> <EMBED href="/media/players/testsound.swf" src="/media/players/testsound.swf" flashvars="soundUrl=sound.mp3" quality=high bgcolor=#FFFFFF NAME="myMovieName" ALIGN="" TYPE="application/x-shockwave-flash"> </EMBED> </OBJECT> mxml ; import flash.net.; import mx.controls.Alert; import mx.controls.Button; import flash.events.Event; import flash.media.Sound; import flash.net.URLRequest; private function clickhandler(event:Event):void { var musicfile:String; var s:Sound = new Sound(); s.addEventListener(Event.COMPLETE, onSoundLoaded); var req:URLRequest = new URLRequest("/opt/cloodon/site/media/players/sound.mp3"); //musicfile = stage.loaderInfo.parameters["soundUrl"]; //var req:URLRequest = new URLRequest(musicfile); s.load(req); } private function onSoundLoaded(event:Event):void { //Alert.show("1"); //var localSound:Sound = event.currentTarget as Sound; var localSound:Sound = event.target as Sound; localSound.play(); } ]]> </fx:Script> <fx:Declarations> <!-- Place non-visual elements (e.g., services, value objects) here --> </fx:Declarations> <!--<mx:Button id="play" label="PLAY" click="clickhandler(event)" />--> <mx:Image id="loader1" source="@Embed(source='/opt/cloodon/site/media/img/speaker.gif')" click="clickhandler(event)" /> </s:Application>

    Read the article

  • save button error in AS project

    - by Rajeev
    Whats wrong with the following code,There is an error at saveButton.visible = false; discardButton.visible = false; package { import flash.display.Sprite; import flash.media.Camera; import flash.media.Video; import flash.display.BitmapData; import flash.display.Bitmap; import flash.events.MouseEvent; import flash.net.FileReference; import flash.utils.ByteArray; import com.adobe.images.JPGEncoder; public class caml extends Sprite { private var camera:Camera = Camera.getCamera(); private var video:Video = new Video(); private var bmd:BitmapData = new BitmapData(320,240); private var bmp:Bitmap; private var fileReference:FileReference = new FileReference(); private var byteArray:ByteArray; private var jpg:JPGEncoder = new JPGEncoder(); public function caml() { saveButton.visible = false; discardButton.visible = false; saveButton.addEventListener(MouseEvent.MOUSE_UP, saveImage); discardButton.addEventListener(MouseEvent.MOUSE_UP, discard); capture.addEventListener(MouseEvent.MOUSE_UP, captureImage); if (camera != null) { video.smoothing = true; video.attachCamera(camera); video.x = 140; video.y = 40; addChild(video); } else { trace("No Camera Detected"); } } private function captureImage(e:MouseEvent):void { bmd.draw(video); bmp = new Bitmap(bmd); bmp.x = 140; bmp.y = 40; addChild(bmp); capture.visible = false; saveButton.visible = true; discardButton.visible = true; } private function saveImage(e:MouseEvent):void { byteArray = jpg.encode(bmd); fileReference.save(byteArray, "Image.jpg"); removeChild(bmp); saveButton.visible = false; discardButton.visible = false; capture.visible = true; } private function discard(e:MouseEvent):void { removeChild(bmp); saveButton.visible = false; discardButton.visible = false; capture.visible = true; } } }

    Read the article

  • Reduce unwanted noise

    - by Rajeev
    In the below code sometimes when microphone is not connected some noise is generated and the system just keeps on buzzing the same sound.Whats wrong with the code below and how to reduce the unwanted noise. Should i set myMic.setLoopBack(false) in the below code <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" width="300" height="100" creationComplete="init()"> <mx:Script> <![CDATA[ import mx.controls.Alert; import flash.net.NetStream; private var myMic:Microphone; private var recordingState:String = "idle"; private function init():void { myMic = Microphone.getMicrophone(); myMic.setSilenceLevel(0); myMic.rate = 44; myMic.gain = 100; myMic.setUseEchoSuppression(true); micLevel.visible = true; //Security.showSettings(SecurityPanel.MICROPHONE); myMic.setLoopBack(true); if (myMic != null) { myMic.setUseEchoSuppression(true); micLevel.setProgress(myMic.activityLevel, 100); addEventListener(Event.ENTER_FRAME, showMicLevel); //micLevel.setProgress(myMic.activityLevel, 100); } } private function showMicLevel(event:Event):void{ switch (recordingState){ case "idle" : micLevel.setProgress(myMic.activityLevel, 100); break; } } ]]> </mx:Script> <mx:ProgressBar x="0" y="36" mode="manual" id="micLevel" label="" labelPlacement="bottom" width="100" fontSize="10" fontWeight="normal"/> </mx:Application>

    Read the article

  • addchild not displaying content

    - by Rajeev
    In the following code i dont have any error but why is that the addchild(video); i.e, the the video captured by webcam is not displayed <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"> <mx:Script> <![CDATA[ import org.com.figurew; import mx.controls.Button; import mx.controls.Alert; import flash.display.InteractiveObject; import flash.display.Sprite; import flash.media.*; import flash.net.*; public function addBody():void { var ret:Number = figurew.getInstance().getparam(); if( ret == 1) { Alert.show("Camera detected"); } if(ret == 0) { Alert.show("No camera detected"); } var cam:Camera = Camera.getCamera(); if(cam != null) { cam.setMode(640, 480, 30); var video:Video = new Video(30, 40); video.attachCamera(cam); addChild(video); } else { trace("No Camera Detected"); } } ]]> </mx:Script> <mx:Button label="Test camera" click="addBody();" x="99" y="116"/> </mx:Application > figurew.as package org.com { import flash.display.InteractiveObject; import flash.display.Sprite; import flash.media.*; import flash.net.*; public class figurew extends Sprite { public function figurew() { //getparam(); var cam:Camera = Camera.getCamera(); if(cam != null) { cam.setMode(640, 480, 30); var video:Video = new Video(300, 450); video.attachCamera(cam); addChild(video); } else { trace("No Camera Detected"); } } public function getparam():Number { var cam:Camera = Camera.getCamera(); if(cam != null) { cam.setMode(640, 480, 30); var video:Video = new Video(300, 450); video.attachCamera(cam); addChild(video); return 1; } else { return 0; trace("No Camera Detected"); } } private static var _instance:figurew = null; public static function getInstance():cldAS { if(_instance == null) { trace("No instance found"); _instance = new cldAS(); } return _instance; } } }

    Read the article

  • Unsupported smapling rate in flex/actionscript

    - by Rajeev
    In action script i need Loading configuration file /opt/flex/frameworks/flex-config.xml t3.mxml(10): Error: unsupported sampling rate (24000Hz) [Embed(source="music.mp3")] t3.mxml(10): Error: Unable to transcode music.mp3. [Embed(source="music.mp3")] The code is <?xml version="1.0"?> <!-- embed/EmbedSound.mxml --> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"> <mx:Script> <![CDATA[ import flash.media.*; [Embed(source="sample.mp3")] [Bindable] public var sndCls:Class; public var snd:Sound = new sndCls() as Sound; public var sndChannel:SoundChannel; public function playSound():void { sndChannel=snd.play(); } public function stopSound():void { sndChannel.stop(); } ]]> </mx:Script> <mx:HBox> <mx:Button label="play" click="playSound();"/> <mx:Button label="stop" click="stopSound();"/> </mx:HBox> </mx:Application>

    Read the article

  • Avoiding duplication in setting properties on the task in Rake tasks

    - by Stray
    I have a bunch of rake building tasks. They each have unique input / output properties, but the majority of the properties I set on the tasks are the same each time. Currently I'm doing that via simple repetition like this: task :buildThisModule => "bin/modules/thisModule.swf" mxmlc "bin/modules/thisModule.swf" do |t| t.input = "src/project/modules/ThisModule.as" t.prop1 = value1 t.prop2 = value2 ... (And many more property=value sets that are the same in each task) end task :buildThatModule => "bin/modules/thatModule.swf" mxmlc "bin/modules/thatModule.swf" do |t| t.input = "src/project/modules/ThatModule.as" t.prop1 = value1 t.prop2 = value2 ... (And many more property=value sets that are the same in each task) end In my usual programming headspace I'd expect to be able to break out the population of the recurring task properties to a re-usable function. Is there a rake analogy for this? Some way I can have a single function where the shared properties are set on any task? Something equivalent to: task :buildThisModule => "bin/modules/thisModule.swf" mxmlc "bin/modules/thisModule.swf" do |t| addCommonTaskParameters(t) t.input = "src/project/modules/ThisModule.as" end task :buildThatModule => "bin/modules/thatModule.swf" mxmlc "bin/modules/thatModule.swf" do |t| addCommonTaskParameters(t) t.input = "src/project/modules/ThatModule.as" end Thanks.

    Read the article

  • why make said no rule to make target

    - by guilin ??
    Isn't Makefile syntax is target: require_files cmd... Why I got this problem? Makefile MXMLC = /opt/flex/bin/mxmlc MXMLC_RELEASE = $(MXMLC) -debug=false -compiler.optimize=true release: bin-release/Wrapper.swf, bin-release/Application.swf bin-release/Application.swf: src/**/*.as, lib/*.swc $(MXMLC_RELEASE) -output bin-release/Application.swf src/Application.as @@-rm ../server/public/game/Application.swf $(CP) bin-release/Application.swf ../server/public/game/Application.swf bin-release/Wrapper.swf: src/*.as, src/engine/**/*.as, lib/*.swc $(MXMLC_RELEASE) -output bin-release/Wrapper.swf src/Wrapper.as @@-rm ../server/public/game/Wrapper.swf $(CP) bin-release/Wrapper.swf ../server/public/game/Wrapper.swf $: make bin-release/Application.swf ~/workspace/project/src/flash [2]19:20 make: * No rule to make target src/constant/*.as,', needed bybin-release/Application.swf'. Stop.

    Read the article

  • pure as3 benefits to compiling with flex4 instead of flex3?

    - by jedierikb
    If I have a pure as3 project that I have been compiling with flex3 from mxmlc, is there any reason to switch to using the mxmlc with flex4? I can use all of the flash 10 language features like Vector, 3D, etc., so that is not a reason to switch (or is there something I can't do?). But maybe there is a performance boost? Or is the exact same compiling tool and the flex code base is the only difference?

    Read the article

  • "Link" against a SWC in Flex

    - by ggambett
    I'm trying to do a very simple app in Flash/Flex, that loads an image embedded in the swf itself and then shows it. The thing is I'm trying to do it using the command line only (mxmlc and compc) and without using @Embed, and failing miserably. I have a very simple Main.as : package { import flash.display.*; import flash.utils.*; public class Main extends Sprite { public function Main () : void { var pDef:Class = getDefinitionByName("icon_big.png") as Class; var _image:BitmapData = new pDef(0, 0); var pSprite:Sprite = new Sprite(); pSprite.graphics.beginBitmapFill(_image); pSprite.graphics.drawRect(0, 0, _image.width, _image.height); pSprite.graphics.endFill(); addChild(pSprite); } } } This works fine if I add icon_big.png to the Library using the Flash IDE, but I can't figure out how to do it from the command line. I'm using compc to put the png inside a swc : compc --include-file icon_big.png icon_big.png -output assets.swc This generates a 17 kb assets.swf, slightly bigger than icon_big.png. Then I try to compile and link Main.as : mxmlc -include-libraries+=assets.swc Main.as This produces a 944 byte Main.swf, which clearly doesn't include the asset, and fails at runtime. According to the mxmlc docs I found, -include-libraries should link with every class, including the ones not directly referenced by code (as is the case here, since I'm getting the class from code), and it unsurprisingly fails at runtime. Note that this same code (or, more precisely, quite equivalent code) works when used within a Flash project - I'm not looking to fix the code, but how to do in the command line whatever Flash does internally. I feel I'm just "not getting" something... any clues?

    Read the article

  • Flex 4 + Apache Ant, Cannot Load FlashPunk Libraries

    - by SquareCrow
    I have been searching google, Apache Docs*, and FlashPunk forums looking for an answer to this: I cannot get Ant/Flex to find and compile the FlashPunk libraries. Here is my build.xml. [code] <!-- Fetch the JAR full of Flex tasks if it is not already in the source directory --> <copy file="${FLEX_HOME}/ant/lib/flexTasks.jar" todir="${SOURCE_PATH}"/> <!-- Add flextasks to the project --> <taskdef resource="flexTasks.tasks" classpath="${SOURCE_PATH}/flexTasks.jar"></taskdef> <!-- Release build Flash Player 10.1 --> <target name="build"> <!-- Build the FlashPunk library --> <echo message="building swc..." /> <compc output="FlashPunk.swc" keep-generated-actionscript="false" incremental="false" optimize="false" debug="true" use-network="false"> <include-sources dir="${FLASHPUNK_PATH}/net" includes="**/* flashpunk/utils/* flashpunk/masks/*" excludes="**/*.TTF **/*.png"/> <load-config filename="${FLEX_HOME}/frameworks/flex-config.xml"/> </compc> <echo message="building swf..." /> <mxmlc file="${SOURCE_PATH}/epOne.as" output="${OUTPUT_PATH}/epOne.swf" debug="false" incremental="false" strict="true" accessible="false" link-report="link_report.xml" static-link-runtime-shared-libraries="true"> <optimize>true</optimize> </mxmlc> </target> [/code] Results in many errors of the type "Definition net.flashpunk.masks:Grid could not be found" even though when I open the directories I can see the *.AS files right there. Sorry if this is very basic. I am piecing together knowledge of Ant from docs and tutorials. *I decided to use Ant because neither FlashDevelop for Windows nor Eclipse for Linux seemto work for me.

    Read the article

  • How to make a small flash swf with ComboBox in Actionscript 3?

    - by Sint
    I have a pure Actionscript 3 project, using flash.* libraries, compiles down to about 6k (using mxmlc). Program handles about 1k shapes, a few sprites, a sockets connection, works great (tastes less filling). Now, how would I add a ComboBox control without incurring excessive bloat? More specificially, I would like to keep the size under 100k. So far I have tried: Adobe mx.controls ComboBoxexample - simple mxml example compiles to 200+k both on my main Linux Box using mxmlc and in Windows using Flash Builder 4 Yahoo Astra - uses mx libraries underneath(so as bloated as Adobe?), plus does not contain exact ComboBox Keith Peter's MinimalComps - seems small, but far from providing ComboBox functionality SPAS (Swing Package for Actionscript) - compiles to 130k, but alpha version of ComboBox does not let me adjust height... asuilib - compiles to 40k, unfortunately this ComboBox does not provide for scrolling items...if it does not fit on screen no way to scroll to it Now my questions: Is there a way to lower size for projects importing mx.controls ? Maybe there is a way to fix SPAS or asuilib ComboBoxes? Perhaps, there are some other libraries which provide a ComboBox(or DropList)?

    Read the article

  • embedded Italic, bold fonts don't look the same in flex as in Windows...

    - by Mark
    ...unless they're something like "Times New Roman" or some other established font with a fully designed italic and bold, presumably in seperate files. Let me explain what I mean (though why no one has commented on this before I have no idea.) Numerous, numerous fonts do not have a seperate file for italic and bold, and in fact to the best of my knowledge don't even have italic and bold defined as such. But if you install them on windows (for example) and then use them in an app, You can still make use of italic and bold with those fonts. For italic, and oblique angle is just given to it, presumably by Windows, and it looks the same in all Windows apps, and the bold is just given a heavier weight. OK, well here's the problem: if you embed a font like that in a Flex app, as a "SystemFont" the italic and bold will not look the same as they do in Windows. Specifically, the oblique angle is invariably much less than in Windows (i.e the italic slant is much less) and the bold version is not bold enough. I vaguely recall thinking that there was some flex mechanism to assign custom oblique angles for italic (and weight for bold) but now can't recall what it is. Does anyone know the correct established way to do this. The following is actually a seperate (but related) font question (in case anyone is expert in all this.) Its rather a lengthy question and can be skipped, but its something that's plagued me for a long time. I mention above embedding as a "SystemFont", so iow something like this: package fonts { import flash.display.Sprite; public class FLW_Script_I extends Sprite { [Embed(systemFont='FLW Script', fontName='FLW Script', fontStyle='italic', fntWeight='normal', mimeType='application/x-font-truetype')] public var wrFont:Class; } } The other alternative to SystemFont for embedding, is "Source" followed by the name of an actual font file. If you try to embed one of the aformentioned single file fonts as a Source file (as opposed to SystemFont) and specify fontStyle='italic', then the mxmlc compiler will return an error and say there is no italic info in the font file. So up to now I have only been embedding these fonts as "SystemFont". The problem is, flex uses two different font compilers internally for Source embedding and SystemFont embedding. For source font embeds it uses the "Batik" compiler and for SystemFont, the JRE (Java Runtime) font compiler. Well actually the Batik is considered a superior compiler and generally produces better looking fonts. And also if you mix normal fonts compiled with Batik and italic compiled with JRE, sometimes the line spacing is different for the two, and it doesn't look right. So does anyone have an idea how to get mxmlc to do italic and bold for these single file fonts when embedding as "Source". Would there be a way using C++ or whatever to construct an "italic" font file from the SystemFont for such a font in windows.

    Read the article

  • swf doesn't respond when relocating it

    - by ron
    Hi, i have in my program few swf files and using mxmlc i compile the application into one swf file. when i open the swf from the output directory(just dbl click) everything works fine. But, when i copy the directory to another location in the hardisk the application stops responding (i can see my swf main picture and its buttons in it. But, when i click a button which just popup a message, it doesn't work!) any help?

    Read the article

1 2  | Next Page >