Closed GoogleCodeExporter closed 9 years ago
integrated nvidia 6150SE shows the defect
integrated intel 945G don't shows the defect
The problem is not in the library code, it is in the test code:
The BackgroundLayer defined there don't sets the current gl color, hence it
could pick up the one set for another nodes (here an auxiliar node used in the
transition).
Other related situation with bad behavior happens adding a particle system or a
tinted sprite over the background layer: the layer would be tinted with the
current open gl color (including alpha).
The fix is easy: add a
glColor4ub(255, 255, 255, 255)
as the first line in the 'draw' method of BackgroundLayer.
But, there is another thing to consider:
BackgroundLayer appears aprox 60 times in the test_*
With four implementations
. the simplest one does not call transform in the draw method, hence it would behave like a peculiar CocosNode (not following .rotation, .position, .scale)
. the next applies transform but have this color leak problem
. two special cases
Being that the test_*.py can and should be used to experiment by library users,
it should expose 'good' objects, not quirky ones.
So I think the fix for this issue should be backported to the other appearances.
I will fix in a few commits by
. change the special cases to use another name / become a common case
( test_custom_on_resize.py , test\test_transform.py )
. add a script to bulk upgrade the common cases to good behaved one
( tools\uniform.py )
. bulk upgrade, retesting
Original comment by ccanepacc@gmail.com
on 23 Mar 2012 at 2:17
This issue was closed by revision r1208.
Original comment by ccanepacc@gmail.com
on 2 Jul 2012 at 7:09
Fixed for all scripts with the defect at r1208
snapcompare tell rendered images don't changed when running in a good behaved
tesbed.
We should have care to not introduce same weakness in new tests
Original comment by ccanepacc@gmail.com
on 2 Jul 2012 at 7:13
fixed in cocos 0.5.5, closing
Original comment by ccanepacc@gmail.com
on 14 Aug 2012 at 12:53
Original issue reported on code.google.com by
ccanepacc@gmail.com
on 26 Nov 2010 at 2:47