Open GoogleCodeExporter opened 9 years ago
I think I'm experiencing the same error with this code:
var image:ImageSnapshot = ImageSnapshot.captureImage(parentApplication.mChart,
300,
new PNGEncoder());
myPDF.addImageStream(image.data, 0, 0, image.width, image.height);
Error: Alpha channel not supported
at org.alivepdf.images::PNGImage/parsePNG()[/Users/timbert/Documents/Flex Builder
3/AlivePDF/src/main/flex/org/alivepdf/images/PNGImage.as:46]
at org.alivepdf.images::PNGImage()[/Users/timbert/Documents/Flex Builder
3/AlivePDF/src/main/flex/org/alivepdf/images/PNGImage.as:19]
at org.alivepdf.pdf::PDF/addImageStream()[/Users/timbert/Documents/Flex Builder
3/AlivePDF/src/main/flex/org/alivepdf/pdf/PDF.as:3304]
at VaxSafetyReport_view/createPDF()[C:\Documents and
Settings\cdowney\workspace-flex3\TLC\src\VaxSafetyReport_view.mxml:150]
at VaxSafetyReport_view/___VaxSafetyReport_view_Button1_click()[C:\Documents and
Settings\cdowney\workspace-flex3\TLC\src\VaxSafetyReport_view.mxml:159]
VERSION: 0.1.4.9 / OS: Windows XP
Additional Info:
This code (using the same DisplayObject) works just fine:
myPDF.addImage(parentApplication.mChart,X,myPDF.getY()+20,0,0,ImageFormat.PNG,10
0,1);
I'm hoping that this bug gets fixed soon so I can use higher quality snapshots.
Thank you!
Original comment by cdow...@gmail.com
on 4 Nov 2009 at 1:21
Could you provide the code that defines the parentApplication?
I have a similar issue and will see what I come up with.
Original comment by mortens...@gmail.com
on 17 Nov 2009 at 4:39
Inside the parentApplication, mChart is the name of a form within an Accordion
container. The form contains MercuryBarChart2, which is a Canvas container that
hosts a ColumnChart and TextArea.
<mx:Accordion creationPolicy="all">
<mx:Form label="Vaccine Selection" backgroundColor="#E0E0F2" id="mCalcForm">
<local:MercuryCalc id="mCalc"/>
</mx:Form>
<mx:Form label="Mecury Calculation Chart" backgroundColor="#E0E0F2">
<local:MercuryBarChart2 id="mChart"/>
</mx:Form>
<mx:Form label="Your Custom Vaccination Record" backgroundColor="#E0E0F2">
<local:VaxSafetyReport_view/>
</mx:Form>
<mx:Form label="About" backgroundColor="#E0E0F2">
<local:About/>
</mx:Form>
</mx:Accordion>
Please let me know if there is anything else that would be helpful.
Original comment by cdow...@gmail.com
on 17 Nov 2009 at 4:49
I think I am having a similar issue, but only when loading an external PNG.
Embedded
PNG's and DisplayObject snapshots are fine.
Error: Alpha channel not supported
version 0.1.4.8
Windows 7
Original comment by chris.fa...@gmail.com
on 7 Apr 2010 at 3:55
Original issue reported on code.google.com by
patrick....@gmail.com
on 21 Oct 2009 at 9:39