---------------------------------------------------------------------------------------
local PREFIX_PATH = "Data/Textures/Scenes/03_Panorama/Animations/z_time_spiral/"
---------------------------------------------------------------------------------------
createCompositionTimeSpiral = nil
createCompositionFinal = nil
---------------------------------------------------------------------------------------
createCompositionTimeSpiral = function()
	local compositionbg = CreateCompositionSequence()
	local compositionDuration = 3
	compositionbg:setDuration(compositionDuration)
	compositionbg:setName("compositionTimeSpiral" )
	compositionbg:setBoundingBox( Rectanglef(0, 0, 640,480) )
 
	local element
	local effector
 
	-- Layer Final/1
	element = createCompositionFinal()
	element:setName("Final/1")
	compositionbg:addElement(element)
	element:setHotSpot(320, 240)
	element:setParentElement(compositionbg)
	element:setXY(320, 240)
 
 
	effector = element:getEffector()
	effector:setLifeTime(1.04166666666667, 2.54166666666667)
	effector:play()
 
 
	-- Layer Glow_000031 ([1-23]).png/2
	element = CreateCompositionElement(PREFIX_PATH.."Glow_000031__[]_.png")
	element:setName("Glow_000031 ([1-23]).png/2")
	compositionbg:addElement(element)
	element:setHotSpot(80, 60)
	element:setParentElement(compositionbg)
	element:setXY(320, 240)
 
	element:setScale(4,4)
					local anim = element
					anim:setAnimationSize(160,120)
					anim:setFramesCount(23)
					anim:setFPS(24)
					anim:setMode(_ANIM_FWD)
					anim:setBlend(_EBlendModeColorAdd)
					anim:play()
 
	effector = element:getEffector()
	effector:setLifeTime(0, 0.95833333333333)
	effector:play()
 
	compositionbg:play()
 
	return compositionbg
end
 
createCompositionFinal = function()
	local compositionFinal = CreateCompositionSequence()
	local compositionDuration = 1.5
	compositionFinal:setDuration(compositionDuration)
	compositionFinal:setName("compositionFinal" )
	compositionFinal:setBoundingBox( Rectanglef(0, 0, 640,480) )
 
	local element
	local effector
 
	-- Layer kvadrat00021 1 ([1-24]).png/1
	element = CreateCompositionElement(PREFIX_PATH.."kvadrat00021_1__[]_.png")
	element:setName("kvadrat00021 1 ([1-24]).png/1")
	compositionFinal:addElement(element)
	element:setHotSpot(65, 58.5)
	element:setParentElement(compositionFinal)
	element:setXY(312, 272)
 
	element:setScale(9.52307692307693,10.3333333333333)
					local anim = element
					anim:setAnimationSize(130,117)
					anim:setFramesCount(24)
					anim:setFPS(16)
					anim:setMode(_ANIM_FWD)
					anim:play()
 
	effector = element:getEffector()
	effector:setLifeTime(0, 1.5)
	effector:play()
 
 
	-- Layer _Shine11_([1-20]).png/2
	element = CreateCompositionElement(PREFIX_PATH.."_Shine11__[]_.png")
	element:setName("_Shine11_([1-20]).png/2")
	compositionFinal:addElement(element)
	element:setHotSpot(72.0817120622568, 60.5538461538461)
	element:setParentElement(compositionFinal)
	element:setXY(326, 249.999999999999)
 
	element:setScale(10.5,10.5)
	element:setRotationRad(3.7524578875)
					local anim = element
					anim:setAnimationSize(150,123)
					anim:setFramesCount(20)
					anim:setFPS(16)
					anim:setMode(_ANIM_FWD)
					anim:play()
 
	effector = element:getEffector()
	effector:setLifeTime(0, 1.25)
	effector:setKey(_TRACK_O, 0.66666666666667, 0.5)
	effector:setKey(_TRACK_O, 1.20833333333333, 0)
	effector:play()
 
	compositionFinal:play()
 
	return compositionFinal
end
 
