[Laszlo-dev] For Review: Change 20080917-bargull-2fS Summary: round resource sizes

André Bargull andre.bargull at udo.edu
Wed Sep 17 09:43:55 PDT 2008


This is a different topic than "pixellock" and also swf8 specific, so I 
think it's at least at the right place.
However, earlier versions unscaled the movieclip, measured its size and 
reapplied scaling. That way you don't get any wrong fractional results. 
I think it was Tucker who changed that particular piece of code (@rev 
#7933), so maybe he can chime in to explain his changes.

from 
"http://svn.openlaszlo.org/openlaszlo/tags/3.1.1/WEB-INF/lps/lfc/views/LaszloView.as":
> LzView.prototype.updateResourceSize = function ( ){
>     this.__LZmovieClipRef._xscale = 100;
>     this.__LZmovieClipRef._yscale = 100;
>     this.resourcewidth = this.__LZmovieClipRef._width;
>     this.resourceheight = this.__LZmovieClipRef._height;
>     this.__LZmovieClipRef._xscale = this.xscale * 100;
>     this.__LZmovieClipRef._yscale = this.yscale * 100;
>     this.reevaluateSize();
> }



On 9/17/2008 5:11 PM, Max Carlson wrote:
> Approved!  However, I wonder if the rounding should happen at a higher 
> level, perhaps in view.setWidth/Height?  We do some roundingw there if 
> pixellock == true...
> 
> André Bargull wrote:
>> Change 20080917-bargull-2fS by bargull at dell--p4--2-53 on 2008-09-17 
>> 15:58:00
>> in /home/Admin/src/svn/openlaszlo/trunk
>> for http://svn.openlaszlo.org/openlaszlo/trunk
>>
>> Summary: round resource sizes
>>
>> New Features:
>>
>> Bugs Fixed: LPP-6135
>>
>> Technical Reviewer: max
>> QA Reviewer: (pending)
>> Doc Reviewer: (pending)
>>
>> Documentation:
>>
>> Release Notes:
>>
>> Details:
>> Call Math.round() to avoid fractional resource-dimensions.
>>
>>
>> Tests:
>> attached at bugreport
>>
>> Files:
>> M WEB-INF/lps/lfc/kernel/swf/LzSprite.as
>>
>> Changeset: 
>> http://svn.openlaszlo.org/openlaszlo/patches/20080917-bargull-2fS.tar
>>
>>
> 



More information about the Laszlo-dev mailing list