------------------------------------------------------------ Release Notes for Transform SWF for Java, Version 2.0.5. ------------------------------------------------------------ This release contains bug fixes and the deployment of text suites that use TestNG. Special thanks goes to Denis Bohm of Firefly Design for contributing fixes for several bugs. Bug Fixes FSDefineVideo: the smoothing attribute is now encoded correctly. FSPlaceObject2: ratioes of zero are now encoded. FSPlaceObject2: clipping depth now masks shapes correctly. FSPlaceObject2: unity colour transforms are now encoded correctly. Shapes now handle all bitmap fill styles. Bug fixes in 2.0.4 Patch 1 are included. Class Changes FSPlaceObject2 encodes any non-null transform. FSDefineTextField: defaults values for layout changed. Internal Class Changes FSCoordTransform now encoded more efficiently. FSText: number of advance bits defaults to 1. FSFontInfo: character code table is now encoded more efficiently. FSSoundStreamHead2 preserves reserved field. Package Changes Added the Tools package. Added test suites using TestNG. Further simplified package structure. ------------- Bug Fixes ------------- 1. FSDefineVideo: the smoothing attribute is now encoded correctly. Smoothing in FSDefineVideo tells the Flash Player to "smooth" the frames displayed. This improves the visual appearance of the video but at a heavy performance cost. In previous releases the inverse value of boolean flag that controls whether smoothing would be used was being encoded. Now Fixed 2. FSPlaceObject2: ratioes of zero are now encoded. The documentation for the class specified that the default value for the morphing ratio was set to minus one (-1.0) and if the attribute was set to another value between 0.0 and 1.0 then it would be encoded in the movie. This attribute is now set correctly to -1.0 and morphing ratioes are now encoded. In previous releases the default value was actually zero and the text for encoding was if the value was greater than zero. Consequently shapes at the start of the morphing process would not be displayed correctly. Hpowever the practical consequences of this bug were probably small since shapes typically were quickly displayed moving through the different morphing steps. 3. FSPlaceObject2: clipping depth now masks shapes correctly. The clipping depth allows a shape on a given layer to mask shapes displayed in front of it up to a specified layer number. In previous releases the layer number was being decremented by 1 before encoding - for reasons which are lost in the mists of time. As a result the shape did not clip the topmost layer specified. This is now fixed. 4. FSPlaceObject2: unity colour transforms are now encoded correctly. A unity colour transform, which set the colours to the original values defined in the shape has a special encoding in Flash files which is not included in the Flash file format specification from Macromedia. The transform is encoded as an empty transform with no add terms or multiply terms. When this form was seen in files it was assumed it was a bug and that the transform was not doing anything useful. It is now known that this form "resets" the colour changes to the original colours are displayed. The effect was noticed on transparent shapes where the unity transform is used to make the shape opaque. 5. Shapes now handle all bitmap fill styles The Bitmap fill style types, Unsmoothed_Tiled and Unsmoothed_Clipped are now being decoded and encoded correctly in shape definitions: FSDefineShape, FSDefineShape2 and FSDefineShape3. 6. Bug fixes in 2.0.4 Patch 1 are included. The bug fixes for FSDefineJPEGImage2, FSDefineJPEGImage3 and FSPush are included in this release. ----------------- Class Changes ----------------- 1. FSPlaceObject2 encodes any non-null transform. The FSPlaceObject2 class will now encode any non-null FSCoordTransform and FSCOlorTransform object. Previously the class checked to see whether the transforms were unity transforms and only encoded them if they were not. 2. FSDefineTextField: defaults values for layout changed. Default values for alignment, leftMargin, rightMargin, indent and leading were previosly set to zero. Layout information for a text field , which is comprised of these attributes, was not encoded if all of the attributes were zero. The default values are now set to the package constant Transform.VALUE_NOT_SET which allows values of zero to be correctly specified when controlling the layout of the text displayed in the field. -------------------------- Internal Class Changes -------------------------- 1. FSCoordTransform now encoded more efficiently. The same "empty" representation for FSColorTransform when encoding unity transforms applies to FSCordsTransform. The class has been updated to encode and decode correctly using this form. 2. FSText: number of advance bits defaults to 1. FSText: the minimum number of advance bits is set to 1 so that files encoded using Transform are identical to files generated by third-party tools. This update appears to have no functional use but simplifies the progress of regression testing. This change affects only the way text objects are encoded and is completely hidden from the API. 3. FSFontInfo: character code table is now encoded more efficiently. The table containing the character codes is now sized correctly, using only 16-bits when there are codes over 255. Previously wide (16-bit) codes were always used for ShiftJIS or Unicode characters. This change affects only the way text objects are encoded and is completely hidden from the API. 4. FSSoundStreamHead2 now preserves reserved field. FSSoundStreamHead2: added an attributed _reserved, which is used to hold the state of a reserved field when decoding a movie so then the movie is encoded the value is preserved. This field is supposed to always be zero, but this is not the case in practice. This preserves the function in case it implements an undocumented Flash feature. ------------------- Package Changes ------------------- 1. Added the Tools package. A new package com.flagstone.transform.tools has been added for useful programs and utilities. The first tool to be included is TextDump which saves a full text description of a Flash file. This tool implements the Export command in Describe SWF (it uses the same code, with minor modifications) and generates a formatted file showing all the data structures and values decoded from a Flash file. The primary use of this tool is for debugging. Text representations of file that has been decoded then reencoded can be compared against the original file providing a quick way of seeing what the differences are. 2. Added test suites using TestNG. As promised in the roadmap, TestNG is now being used for performing all testing on the classes. Some tests has been added, the most important one is com.flagstone.transform.test.FSMovieTest. This test combined with the TextDump tool is now used to verify that all the classes in the framework are encoding and decoding correctly. More tests will be added in the future to verify correct operation of individual classes. TestNG is not included with the release but see the file, doc/README.txt for more information on how to obtain the library and run the test suites included in the directory, test/suites. 3. Further simplified package structure. Some of files such as README.txt and LICENCE.txt have been moved around to simplify the package structure and generally tidy things up.