forked from hyperandroid/CAAT
-
Notifications
You must be signed in to change notification settings - Fork 0
/
changelog
505 lines (356 loc) · 19.2 KB
/
changelog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
02/23/2012 *0.3 Build 212*
--------------------------
* Added to CAAT.Scene the following methods:
+ findActorAtPosition(CAAT.Point) : custom actor find procedure. This is overriden to attend at the priority input lists.
+ enableInputList(number) : number of priority lists to set for this scene. A priority list is a list of actors to
which are suitable to receive input first. If no actor on the priority lists are under
the cursor, the whole scene graph is traversed instead.
+ addActorToInputList( actor, index, position ) : add an actor to a given priority list at certain position.
+ emptyInputList( index ) : remove all elements from a list.
+ removeActorFromInputList( actor, index ) : remove an actor from a list, or if no index list is supplied remove
the actor from every list in which appears.
* Fixed Actor.setImageTransformation( CAAT.SpriteImage.prototype.TR_TILE ) which didn't honor actor position and offset
to appropriately place the tiling image. Also the performance sink when using this flag with huge actors's been fixed.
* Fixed an issue when entering scene gets mouse input.
02/21/2012 *0.3 Build 180*
--------------------------
* Fixed (at last) Catmull Rom splines as CAAT.Path objects.
* Added CAAT.Path.flatten method to turn a compound path of patches into a polyline.
* Added CAAT.PathActor.setOnUpdateCallback
02/10/2012 *0.3 Build 138*
--------------------------
* Deprecated CAAT.PathBehavior.setTranslation function in favor of CAAT.Actor.setPositionAnchor function.
* Deprecated method setLocation in favor of setPosition.
* Added translation anchor. setpositionAnchor, setPosition.
* Added methods setRotationAnchor, setScaleAnchor, setGlobalAnchor to CAAT.Actor.
* Fixed bug with dirty rects and scaled canvas. It wasn't repainting the correct screen areas.
* Added CAAT.SpatialHash object.
* Added Behavior.setDelayTime( delay, duration ). This method applies the behavior after delay ms from current scene time
so there's no need to know currentScene time to set a behavior anymore.
* Added CAAT.SpriteImage.stringHeight method which gives the highest char height on the sprite image atlas map.
* Fixed CAAT.ContainerBehavior that on expiration notified twice behavior expiration event (one from base class, and another
one from the container itself).
* Fixed CAAT.TextActor issue when drawing text with CAAT.SpriteImage
* Clip Paths also honors the new method setPositionAnchor in CAAT.Actor. Added methods setRotationAnchor, setRotation,
setScaleAnchor, setScale, setPosition, setPositionAnchor to CAAT.Path.
* Added global flag CAAT.GLRENDER.
02/09/2012 *0.3 Build 64*
--------------------------
* Fixed setScreenBounds method which was calculating the bounding box erroneously when in negative coordinates.
Note to self: Number.MIN_VALUE != -Number.MAX_VALUE !!!!.
* Fixed the case where a path composed by one single segment with overlapping starting and ending point was returning
(0,0) as path traversal. Now returns one of the two overlapping points.
* Added invalidation for actors which change their background's image sprite index (Canvas only)
* Improved scene graph traversal to fast discard elements out of screen (AABB testing)
* Improved matrix calculations for AABB Actors.
* Changed CSS renderer setLocation semantics from style.left|top to [-vendorPrefix]-transform.
* Added getMapInfo method on CAAT.SpriteImage. Thus I can access glypth/sub-image data by index.
* Fixed a bug with dirtyRects which made the system draw the whole canvas when no area is affected (agh!!)
* Modified CAAT.QuadTree object to allow for default parameters setup.
02/03/2012 *0.3 Build 6*
--------------------------
* Added math/Quadtree object.
* Added Demo19 showcasing some collision detection mechanism.
* Modified debug panel to show affected cleared dirty rectangles.
* Modified math/Rectangle object and added intersect method which extract intersection from any two given rectangles.
* Fixed an issue which prevented cachedAsBitmap TextActor not show properly.
02/01/2012 *0.2 Build 90*
--------------------------
* Refactored CAAT.TextActor object so that it can have background style or image.
* Added method setTextFillStyle to determine text fill style. The old setFillStyle method does not affect text anymore
but actor's background.
* Removed some non ansi characters from sourcecode comments.
* Added setGestureEnabled and isGestureEnabled methods to CAAT.Actor on CSS renderer.
* TextActor recalculates its size when font or text is changed.
* Added DirtyRects info to Debug panel. Number of rectangles, and on-screen representation.
01/26/2012 *0.2 Build 52*
--------------------------
* Added volume to audio elements in audio manager. Call method director.setVolume or audioManager.setVolume
01/24/2012 *0.2 Build 48*
--------------------------
* Fixed Path.applyAsPath which failed to execute.
* Fixed Path.applyAsPath which wasn't applying the mask properly.
01/23/2012 *0.2 Build 40*
--------------------------
* Improved Dirty rects performance.
01/22/2012 *0.2 Build 20*
--------------------------
* Removed some debug code.
* Added dirty rectangles clear support.
To be enabled a call director.setClear( CAAT.Director.CLEAR_DIRTY_RECTS ); must be performed.
Every actor which changes affine transformation, either position, rotation or scale, will automatically
be invalidated. In you want any other actor to be explicitly invalidated, just call actor.invalidate();
* Cleaned some ctx.save/restore code.
* Modified license file to reflect copyright 2012.
01/20/2012 *0.1 Build 631*
--------------------------
* Added methods initializeAsFontMap, drawString, stringWidth to CAAT.SpriteImage. Those methods allow to
draw strings via textured fonts. Every character will be defined besides x,y,width,height in texture,
by xoffset, yoffset, xadvance.
* Removed unneeded actor initialization inverse matrices.
01/19/2012 *0.1 Build 627*
--------------------------
* Added clip paths capability to be scaled accordingly to director's affine transform.
* Modified CAAT.Path bounding box to keep track of path's position. So if a clip path is defined as:
new CAAT.Path().beginPath(200,200).addRectangleTo(300,300).endPath() there's no need to still apply the workaround
of setting a behavior to show it properly.
01/19/2012 *0.1 Build 610*
--------------------------
* Fixed a bug which prevented scaled directors to properly show bounding boxes.
* Merged fix for template with splash screen.
01/18/2012 *0.1 Build 607*
--------------------------
* Enabled iOS rotate/scale gestures.
* Corrected a bug which prevented drag-enabled actors to be dragged with gestures.
* Added setGestureEnabled and isGestureEnabled methods to allow iOS gestures zoom/rotate.
* Added bounding box and differentiated it from AA bounding box.
01/16/2012 *0.1 Build 555*
--------------------------
* Improved debug panel.
01/13/2012 *0.1 Build 523*
--------------------------
* Added method CAAT.setCoordinateClamping( bool ) which controls the to-integer coordinate clamping procedure. This
speeds things up on mobile. A call to this method must be performed previously to creating any CAAT.Matrix object,
begin the beginning of your application the suitable place.
* Added current scene time to mouseEvent.
* Removed some unneeded consuming code.
* Modified CAAT.Debug object to show more info. Added file documentation/debug/debug_template.html with the needed
html code for Debug info to be shown. By default, the performance canvas will take window.innerWidth width and it
won't resize its size.
12/29/2011 *0.1 Build 429*
--------------------------
* fixed the case in which a clipPath was not transformed properly unless it had a behavior applied. Thanks Rob Boerman
for spotting.
12/28/2011 *0.1 Build 422*
--------------------------
* deferred integer coordinate clamping to matrix's transformRenderingContextSet and transformRenderingContext methods.
* disabled preventDefault on key events. Must be explicitly called by the developer otherwise, page reload, etc. could
be prevented.
* added CAAT.Keys object with common key keyCodes.
* added demo18 Keyboard management.
12/26/2011 *0.1 Build 415*
--------------------------
* Fixed PathActor to be able to draw background image or color.
* Fixed key event system. Now, the original key event is 'preventDefault'ed, and the notification callback receives an
object of the form:
new CAAT.KeyEvent(
key,
'up' | 'down',
{
alt: CAAT.KEY_MODIFIERS.alt,
control: CAAT.KEY_MODIFIERS.control,
shift: CAAT.KEY_MODIFIERS.shift
},
source_event );
12/17/2011 *0.1 Build:407*
--------------------------
* CAAT.modules.ImageUtil is no more an object but a namespace with (static) functions.
* function CAAT.modules.ImageUtil.optimize now accepts a parameter to scan on specifig regions.
* Added CAAT.Font which encapsulates a sprite font. Contains methods: to define font, paint, stringWidth, save, etc.
* Method initialize and initializeGL give the opportunity to define a proxy input event. It is usefull in case some
layering has to be done on top of the canvas element.
12/16/2011 *0.1 Build:374*
--------------------------
* A bug prevented to construct an appropriate css sprite image representation.
12/15/2011 *0.1 Build:371*
--------------------------
* Added TR_TILE to SpriteActor. This allows to tile an actor bg image. This method should be combined with a call to
actor.setClip(true) otherwise, the tiling op won't work properly. Bakground offseting won't work on CSS.
* Added ActorContainer constructor modifier which will make the container conform to its childres bounds.
Constraint: actors located at negative coordinates won't modify containers top-left position.
12/09/2011
--------------------------
* Added Scale1Behavior to apply scale behavior either on X or Y axis.
12/08/2011 *0.1 Build:355*
--------------------------
* Added bounding box drawing if CAAT.DEBUGBB is set.
12/05/2011 *0.1 Build:347*
--------------------------
* Fixed bug in CAAT-CSS Actor.addChildAt.
* Added no-repeat modifier to Actor background image to CSS conversion.
* Optimized CSS Actor scene traversal procedure.
* Added mouseOut and mouseOver handlers for events regarding mouse abandons CAAT's screen area or mouse gets in CAAT's
screen area respectively.
* Fixed bug when dragging and getting out of CAAT's on-screen area. Now events resume properly.
12/04/2011 *0.1 Build:327*
--------------------------
* Added maps for SpriteImage. Now the output from the tool http://labs.hyperandroid.com/static/texture/spriter.html
can be directly used in SpriteImage by initializing it with the method initializeFromMap( image, map ).
* Added SpriteImage setChangeFPS for CSS renderer.
* Removed references to deprecated CAAT.ImageActor objects.
11/28/2011 *0.1 Build:287*
--------------------------
* One single director file (no more messing with director and directorCSS).
* Unified touch code for canvas and CSS renderers.
11/24/2011 *0.1 261*
--------------------
* Deprecated and removed: CAAT.ImageActor, CAAT.SpriteActor, CAAT.Button, CAAT.CompoundImage
* Removed csskeyframehelper.js and keyframe.js files
11/24/2011 *0.1 257*
--------------------
* Keyframes's been removed. They were not such a big idea after all.
11/24/2011 *0.1 252*
--------------------
* Added Keyframes. Keyframes set Behaviors deprecated.
11/24/2011
----------
* fixed CAAT.Actor.setAsButton to honor disabled status.
11/22/2011
----------
* Added proper touch events support.
* Added behaviorStarted method to behavior lifecycle listener.
* Added calculateKeyframesData method to get a CSS3 keyframes representation of any given behavior.
* Added CSSKeyframeHelper methods to manage CSS3 @-[webkit|moz]-keyframes elements.
* Fixed bug on setZOrder method which created a nested actor array.
* Added setTimeOffset method on behaviors which allows to start a behavior at any given position instead of zero time.
11/08/2011
----------
* Added statistics to CSS director.
* Fixed a bug that prevented a button-as-actor to set its first state image.
11/07/2011
----------
* Enabled multi-page packed textures on GL renderer.
* Fixed GL lines color with the new UNPACK_PREMULTIPLY_ALPHA_WEBGL flag to be compatible with FF.
11/02/2011
----------
* Fixed FF Webgl textures problem. Unpacking pre multiplied alpha on channels has done it.
Changing from blending function SRC_ALPHA to ONE.
* Added Box2D debug renderer.
* Fixed Demo3, sprite fish didn't animated properly.
10/27/2011
----------
* Added minified and non-minified CAAT library files versions.
10/26/2011
----------
* Changed Input subsystem (again). Now every event has the right information.
* Changed Transformation matrix hierarchy. Now Director's transformation is considered to be Projection Matrix.
* Changed Actor's setScaleAnchored and setRotationAnchored methods so that anchor values are no more
coordinates in space but proportional values (0..1) representing a percentage (like in behaviors).
This is a major issue and should be taken into account for previous developments.
* Fixed tutorials and demos to reflect setScaleAnchored and setRotateAnchored changes.
10/24/2011
----------
* Fixed CSS dragging bug.
* Added get/set id methods to CSS Actor.
10/19/2011
----------
* Code optimizations.
* Fixed bug with onMouseMove local coordinates.
10/18/2011
----------
* Added a callback function to be triggered on Director resize events. The method enableResizeEvents signature
has been changed to be enableResizeEvents : function(mode, onResizeCallback) {}. The parameter
onResizeCallback is function with the signature function( director, width, height ).
* If director has enableResizeEvents enabled, now is resized on first instance. Previously, a window resize
had to be triggered manually.
* Fixed mousemove coordinates on scaled director that weren't proper ones.
10/17/2011
----------
Fixed input subsystem. Now Actor instances won't receive mouseUp if dragged was performed on them.
BUG. Fixed a bug with container behaviors that prevented a contained behavior to be expired again.
10/15/2011
----------
Fixed a bug with bezier bounding box that wasn't including the curve's first control point. (thanks yodesoft.com)
10/14/2011
----------
Added modelToModel coordinate system conversion method which transforms a local coordinate into another
actor's coordinate system.
10/13/2011
----------
Refurbished input subsystem. Now handles drag on buttons.
Added scene pause methods.
Added line definition values on Shape and Star actors.
Added visual debugging info, regarding FPS and total/active actors on screen. (CAAT.DEBUG=1 before
director creation).
09/26/2011
----------
Added ShapePath to allow for rectangle shaped path segments.
Added methods on Path* and bezier curves to manage individual control points.
Added bounding box support for Path* objects.
Changed Path.closePath function semantics.
Fixed some code on rectangle, point, bezier, path.
09/14/2011
---------
Added shift/control/alt modifiers to key events.
added missing getAnchorPercent method to actorCSS.js file. [important bug]
Fixed CSS renderer zOrder error.
09/11/2011
----------
Added function setInteractive method to PathActor.
Added function showBoundingBox : function(show, color) to PathActor.
09/04/2011
----------
Removed bug on ActorCSS.setFillStyle().
Deprecated methods setFilled and setOutlined form CAAT.StarActor.
09/01/2011
----------
Added new layout module. Now simply lays out a collection of actors in a row into a given container.
Will upgrade accordingly as needed.
31/08/2011
----------
deprecated method centerOn and renamed it to centerAt.
16/08/2011
----------
Added x and y attributes to mouseEvent object instances.
15/08/2011
----------
Added a exception to be thrown whenever an Actor is to be added to any given parent and already has
a registered parent.
Added on actor destroy event, a call to be removed from its parent (in case there's one). Now, discardable
and out-of-frame-time elements can be succesfully reused with the previous condition. To remove an
actor means a linear search to identify in which position is stored.
13/08/2011
----------
Fixed director canvas resize on RESIZE_PROPORTIONAL. WebGL renderer did not show properly after resizing.
Changed directorGL perspective from frustum to orthogonal.
11/08/2011
----------
Updated tutorials to fit new CAAT needs.
Updated demo/examples to fit new CAAT needs. Suggested place to look for examples is CAAT-Samples repo.
Fixed some scene transition bugs (when scaling).
10/08/2011
----------
Added on ActorCSS needed control to set a canvas as background image. It is not recommended
since the performance drops very significantly.
Fixed director's RESIZE_PROPORTIONAL option. There was a bug that prevented scenes from
affine transforming properly with respect to the director instance.
Separated CAAT compilation results into two separate versions one for Canvas/GL and the
other for CSS. This is needed since the Actor,ActorContainer,Scene and Director classes
have been rewritten to support a CSS renderer. Since there's a extend function invoked
inside closures to extend prototypes I'm unable to decide on the fly whether to extends
an object (Actor) or another version with the same interface (ActorCSS).
09/08/2011
----------
Actor.cacheAsBitmap method change: now returns this instead of an HTMLCanvasElement.
Set ScaleBehavior and RotateBehavior setAnchor method to define an exact pixel distance
anchor. Use this method when setting percentages via setValues method call is hard to do,
for example, when anchoring around a parent.
08/06/2011
----------
Added getRenderType method to Director. It will return WEBGL|CANVAS|CSS depending
on the rendering techniques it uses.
Added DirectorCSS, SceneCSS and ActorCSS to the system. Now, CSS is a suitable option
to render.
Added CSS renderer.
DOM is unable to identify wihch of any overlapping divs the user is interacting with.
Added a over div which tracks mouse info. ( And works properly \o/ )
CSS Renderer drawbacks:
* the scale anchor's been deprecated since transform style only supports one
* always use accessor/mutator method to interact with actor's properties
* unable to use dynamic images (ie Canvas generated images).
Changed Scale Anchor semantics. Now it is equal to Rotation, so the method
setScaleAnchored now accept two more parameters which define the position in pixels
where the anchor is located.
Changed ScaleBehavior and RotateBehavior to fit the new setScale semantics. Now the method
setValues of these Behavior accept two more parameters to define the transformation anchor.
In general, there should not be mixed different types of director renderers per page.
07/30/2011
----------
CAAT.Actor: added the capability to draw images on its background. This feature
will substitute the need of using CAAT.ImageActor, CAAT.Image and CAAT.Button.
CAAT.CompoundImage: added method to automatically change sprite index on time
basis. Basically logic from SpriteActor's been moved to this class.
Created CAAT.SpriteImage to substitute CAAT.CompoundImage and serve as images
info backend for CAAT.Actor. CAAT.CompoundImage is kept for backwards compatibility
with CAAT.ImageActor, CAAT.SpriteActor and CAAT.Button.
Modified GL methods to kept compatibility with new CAAT.Actor image capabilities.