Unable to resolve '[file]' for transcoding
So I was happy building my project in Flex Builder, till I committed my code and CruiseControl complained that I cannot build it ! See, CC uses compc (the command line compiler) to compile the module and it was returning:
Here is what the code looked liked.
So I said to my self, "Oh come on! I thought you can handle pngs. Poop !" - Googled the error and found this link. And the solution was to add a "/" in front of "assets":
Now I'm happier :-)
unable to resolve 'assets/cross_cursor.png' for transcoding.
Here is what the code looked liked.
[Embed(source="assets/cross_cursor.png")]
So I said to my self, "Oh come on! I thought you can handle pngs. Poop !" - Googled the error and found this link. And the solution was to add a "/" in front of "assets":
[Embed(source="/assets/cross_cursor.png")]
Now I'm happier :-)
Comments
I am trying to embed a font as such:
fontFamily: "Century Gothic";
fontWeight: lighter;
fontStyle: normal;
src: url("/assets/gothic.ttf");
I have placed the gothic.ttf TrueType font file in assets and I always get the error. Any ideas?
Thank you.
If you haven't found this solution already, you just need to add
-managers flash.fonts.AFEFontManager
To the "Additional Compiler Arguments" in the properties of the project.
Was wondering what caused the error!
Cheers.
[Embed("../assets/soundSample.mp3")]
Note for the search engines, I came across this when trying to generate ASDoc.
[Embed(source="/assets/images/basemap.png")]
[Bindable]
var pngBytes:Class;
myPDF.addImageStream( new pngBytes() as ByteArray, 0, 0, 0, 0, 1, "false");
Thanks,
package
{
import net.flashpunk.Entity;
import net.flashpunk.graphics.Image;
public class MyEntity extends Entity
{
[Embed(source="/assets/fireball.png")]
private var PLAYER:Class;
public function MyEntity()
{
graphic = new Image(PLAYER);
}
override public function update():void
{
trace("MyEntity updates.");
}
}
}
Any ideas?
It could be a JDK problem.
http://mytechieblog.blogspot.com/2011/06/error-unable-to-transcode-assetsxyzpng.html
Cheers
Aneesh