InitialObjectDescriptor { objectDescriptorID 1 audioProfileLevelIndication 255 visualProfileLevelIndication 254 sceneProfileLevelIndication 1 graphicsProfileLevelIndication 1 ODProfileLevelIndication 1 esDescr [ ES_Descriptor { ES_ID 1 decConfigDescr DecoderConfigDescriptor { streamType 3 decSpecificInfo BIFSConfig { isCommandStream true pixelMetric true pixelWidth 300 pixelHeight 400 } } } ] } OrderedGroup { children [ Background2D { backColor 1 1 1 } WorldInfo { info ["This shows a vertical Layout node" "with different scrolling modes, direction and rates" "" "GPAC Regression Tests" "(C) 2002-2004 GPAC Team", "(C) 2006 ENST ATG Conformance Streams"] title "Layout Test" } Transform2D { translation 0 80 children [ DEF BOUNDS Shape { appearance Appearance { material Material2D { emissiveColor 0 0 0 } } geometry Rectangle { size 60 200 } } DEF LAY Layout { wrap TRUE size 60 200 justify ["BEGIN" "BEGIN"] horizontal FALSE smoothScroll TRUE loop TRUE scrollVertical FALSE scrollRate 0.1 scrollMode -1 children [ DEF S1 Shape { appearance Appearance { material Material2D { emissiveColor 1 0 0 filled TRUE } } geometry Rectangle { size 50 50 } } DEF S3 Shape { appearance Appearance { material Material2D { emissiveColor 0 1 0 filled TRUE } } geometry Circle { radius 20 } } ] } Transform2D { translation 0 -120 children [ Shape { appearance DEF APPTEXT Appearance { material Material2D { emissiveColor 0 0 0 filled TRUE } } geometry DEF TXT_MODE Text { string ["mode: scroll-in"] fontStyle DEF FS FontStyle { justify ["MIDDLE" "MIDDLE"] size 16 } } } ] } Transform2D { translation 0 -140 children [ Shape { appearance USE APPTEXT geometry DEF TXT_ALIGN Text { string ["align: begin"] fontStyle USE FS } } ] } Transform2D { translation 0 -160 children [ Shape { appearance USE APPTEXT geometry DEF TXT_DIR Text { string ["scroll dir: horizontal"] fontStyle USE FS } } ] } Transform2D { translation 0 -180 children [ Shape { appearance USE APPTEXT geometry DEF TXT_RATE Text { string ["scroll rate: 0.1"] fontStyle USE FS } } ] } ] } Transform2D { translation -110 180 children [ DEF S Shape { appearance Appearance { material Material2D { emissiveColor 0.7 0.7 0.7 filled TRUE lineProps LineProperties { lineColor 0 0 0 } } } geometry Rectangle {size 80 20} } Shape { appearance USE APPTEXT geometry Text { string ["Begin"] fontStyle USE FS } } DEF TS_BE TouchSensor {} ] } Transform2D { translation -110 160 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Middle"] fontStyle USE FS } } DEF TS_ME TouchSensor {} ] } Transform2D { translation -110 140 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["End"] fontStyle USE FS } } DEF TS_EE TouchSensor {} ] } Transform2D { translation -110 100 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Scroll In"] fontStyle USE FS } } DEF TS_SI TouchSensor {} ] } Transform2D { translation -110 80 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Scroll InOut"] fontStyle USE FS } } DEF TS_SIO TouchSensor {} ] } Transform2D { translation -110 60 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Scroll Out"] fontStyle USE FS } } DEF TS_SO TouchSensor {} ] } Transform2D { translation 110 180 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Rate>0"] fontStyle USE FS } } DEF TS_RP TouchSensor {} ] } Transform2D { translation 110 160 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Rate<0"] fontStyle USE FS } } DEF TS_RN TouchSensor {} ] } Transform2D { translation 110 130 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Horiz"] fontStyle USE FS } } DEF TS_SH TouchSensor {} ] } Transform2D { translation 110 110 children [ USE S Shape { appearance USE APPTEXT geometry Text { string ["Vert"] fontStyle USE FS } } DEF TS_SV TouchSensor {} ] } DEF C_BE Conditional { buffer { REPLACE LAY.justify BY ["BEGIN", "BEGIN"] REPLACE TXT_ALIGN.string BY ["align: begin"] } } DEF C_ME Conditional { buffer { REPLACE LAY.justify BY ["MIDDLE", "BEGIN"] REPLACE TXT_ALIGN.string BY ["align: middle"] } } DEF C_EE Conditional { buffer { REPLACE LAY.justify BY ["END", "BEGIN"] REPLACE TXT_ALIGN.string BY ["align: end"] } } DEF C_SI Conditional { buffer { REPLACE LAY.scrollMode BY -1 REPLACE TXT_MODE.string BY ["mode: scroll-in"] } } DEF C_SIO Conditional { buffer { REPLACE LAY.scrollMode BY 0 REPLACE TXT_MODE.string BY ["mode: scroll-in-out"] } } DEF C_SO Conditional { buffer { REPLACE LAY.scrollMode BY 1 REPLACE TXT_MODE.string BY ["mode: scroll-out"] } } DEF C_RP Conditional { buffer { REPLACE LAY.scrollRate BY 0.1 REPLACE TXT_RATE.string BY ["scroll rate: 0.1"] } } DEF C_RN Conditional { buffer { REPLACE LAY.scrollRate BY -0.1 REPLACE TXT_RATE.string BY ["scroll rate: -0.1"] } } DEF C_SH Conditional { buffer { REPLACE LAY.scrollVertical BY FALSE REPLACE TXT_DIR.string BY ["scroll dir: horizontal"] } } DEF C_SV Conditional { buffer { REPLACE LAY.scrollVertical BY TRUE REPLACE TXT_DIR.string BY ["scroll dir: vertical"] } } ] } ROUTE TS_BE.isActive TO C_BE.activate ROUTE TS_ME.isActive TO C_ME.activate ROUTE TS_EE.isActive TO C_EE.activate ROUTE TS_SI.isActive TO C_SI.activate ROUTE TS_SIO.isActive TO C_SIO.activate ROUTE TS_SO.isActive TO C_SO.activate ROUTE TS_RP.isActive TO C_RP.activate ROUTE TS_RN.isActive TO C_RN.activate ROUTE TS_SH.isActive TO C_SH.activate ROUTE TS_SV.isActive TO C_SV.activate