BitmapData.draw tooo slow in AIR


hi,

 

i getting strange behaviour when doing bitmapdata.draw, when publish flash player plugin takes 1ms scale down big image if publish same code air desktop takes 62ms.

 

this code using, nothing special in it....

 

import flash.display.bitmapdata; import flash.geom.matrix; import flash.display.bitmap; import flash.geom.point; import flash.display.stagequality;  var max_bitmap_size:point = new point( 596, 842 );  var bitmapdata:bitmapdata = new mybitmap(); // class image  var sc:number = math.min( max_bitmap_size.x / bitmapdata.width, max_bitmap_size.y / bitmapdata.height );  var outbitmap:bitmapdata = new bitmapdata( bitmapdata.width >> 1, bitmapdata.height >> 1, false, 0x0 );  var scalematrix:matrix = new matrix(); scalematrix.scale(sc,sc);  var time:number = new date().gettime(); outbitmap.drawwithquality( bitmapdata, scalematrix, null,null,null,true,stagequality.low ); trace( new date().gettime()-time  ); 

 

update:

 

figured out why happening... testing inside flash ide , gives me 1ms.... if test in browser gives me 42-47ms.

anyway testing in air gives me 62ms...

i going crazy this, if find out let me know, thanks



More discussions in Archived Spaces


adobe

Comments

Popular posts from this blog

How to change text Component easybook reloaded *newbee* - Joomla! Forum - community, help and support

After Effect warning: A problem occurred when processing OpenGL commands

Preconditions Failed. - Joomla! Forum - community, help and support