--------------------------------------------------------------------------------------------------------------- INITIALIZING VIDBOT, v1.7.1... --------------------------------------------------------------------------------------------------------------- [11:08:23.519] Vidbot :: start() [11:08:23.519] Vidbot :: _next(), _stepIndex:0 of 4 [11:08:23.520] index :: _onStepStarted_vidbot(), step: 1 [11:08:23.521] Vidbot :: step[0], label:Initializing Core [11:08:23.540] index :: _onStepProgress_vidbot(), percent: 20 [11:08:23.540] Vidbot :: _parse() [11:08:23.542] index :: _onStepProgress_vidbot(), percent: 40 [11:08:23.542] Vidbot :: _validate() [11:08:23.543] index :: _onStepProgress_vidbot(), percent: 60 [11:08:23.543] Vidbot :: _fonts() [11:08:23.543] FabricFontManager :: add(), id: SourceSansPro-Bold [11:08:23.543] src: /var/app/Vidbot-V2/assets/fonts/SourceSansPro/SourceSansPro-Bold.ttf [11:08:23.551] FabricFontManager :: add(), id: SourceSansPro-Light [11:08:23.551] src: /var/app/Vidbot-V2/assets/fonts/SourceSansPro/SourceSansPro-Light.ttf [11:08:23.552] FabricFontManager :: add(), id: DINOT-Bold [11:08:23.552] src: /var/app/Vidbot-V2/assets/fonts/DINOT/DINOT-Bold.otf [11:08:23.553] FabricFontManager :: add(), id: DINOT-Light [11:08:23.553] src: /var/app/Vidbot-V2/assets/fonts/DINOT/DINOT-Light.otf [11:08:23.554] FabricFontManager :: add(), id: TradeGothicLTStd-Regular [11:08:23.554] src: /var/app/Vidbot-V2/assets/fonts/TradeGothicCond/TradeGothicLTStd-Regular.otf [11:08:23.555] FabricFontManager :: add(), id: TradeGothicLTStd-Bold [11:08:23.555] src: /var/app/Vidbot-V2/assets/fonts/TradeGothicCond/TradeGothicLTStd-Bold.otf [11:08:23.556] index :: _onStepProgress_vidbot(), percent: 80 [11:08:23.556] Vidbot :: _clips() [11:08:23.556] StreamManager :: add(), id:audio_vo, type:audio [11:08:23.557] AudioClip[audio_vo] :: constructor() [11:08:23.557] InputStream[audio_vo] :: constructor() [11:08:23.557] Vidbot :: StreamMgr.on( 'ADDED' ), data: { streamID: 'audio_vo', clipId: null } [11:08:23.560] StreamManager :: add(), id:bg_music, type:audio [11:08:23.560] AudioClip[bg_music] :: constructor() [11:08:23.560] InputStream[bg_music] :: constructor() [11:08:23.560] Vidbot :: StreamMgr.on( 'ADDED' ), data: { streamID: 'bg_music', clipId: null } [11:08:23.560] StreamManager :: add(), id:simplefadedisplay, type:canvas [11:08:23.561] CanvasStream[canvas_1738828124317] :: constructor() [11:08:23.561] InputStream[canvas_1738828124317] :: constructor() [11:08:23.637] KenBurnsSlideshow[simplefadedisplay] :: constructor() [11:08:23.637] Overlay[simplefadedisplay] :: constructor() [11:08:23.637] CanvasClip[simplefadedisplay] :: constructor() [11:08:23.637] Clip[simplefadedisplay] :: constructor() [11:08:23.637] clip:"simplefadedisplay" added to stream:"canvas_1738828124317" [11:08:23.637] Vidbot :: StreamMgr.on( 'ADDED' ), data: { streamID: 'canvas_1738828124317', clipId: 'simplefadedisplay' } [11:08:23.638] StreamManager :: add(), id:caption, type:canvas [11:08:23.638] RenCaption[caption] :: constructor() [11:08:23.638] Ren[caption] :: constructor() [11:08:23.638] Overlay[caption] :: constructor() [11:08:23.638] CanvasClip[caption] :: constructor() [11:08:23.638] Clip[caption] :: constructor() [11:08:23.638] clip:"caption" added to stream:"canvas_1738828124317" [11:08:23.638] Vidbot :: StreamMgr.on( 'ADDED' ), data: { streamID: 'canvas_1738828124317', clipId: 'caption' } [11:08:23.638] all added... [11:08:23.638] Vidbot :: _next(), _stepIndex:1 of 4 [11:08:23.639] index :: _onStepCompleted_vidbot(), step: 1 [11:08:23.639] index :: _onStepStarted_vidbot(), step: 2 [11:08:23.639] Vidbot :: step[1], label:Initializing Input Streams [11:08:23.639] StreamManager :: init() [11:08:23.640] Vidbot :: StreamMgr.on( 'STREAM_INITED' ), data: { streamID: 'audio_vo', progress: 0.3333333333333333 } [11:08:23.640] index :: _onStepProgress_vidbot(), percent: 33 [11:08:23.640] Vidbot :: StreamMgr.on( 'STREAM_INITED' ), data: { streamID: 'bg_music', progress: 0.6666666666666666 } [11:08:23.640] index :: _onStepProgress_vidbot(), percent: 67 [11:08:23.641] CanvasStream[canvas_1738828124317] :: _init(), BEGIN [11:08:23.641] i:0, c.id:simplefadedisplay [11:08:23.641] KenBurnsSlideshow[simplefadedisplay] :: _init(), BEGIN [11:08:23.641] KenBurnsSlideshow[simplefadedisplay] :: _validate() [11:08:23.642] KenBurnsSlideshow[undefined] :: _validateAnim() [11:08:23.642] KenBurnsSlideshow[undefined] :: _validateTheme() [11:08:23.643] i:1, c.id:caption [11:08:23.644] RenCaption[caption] :: _init() [11:08:23.644] RenCaption[caption] :: _validate() [11:08:23.645] KenBurnsSlideshow[simplefadedisplay] :: _build() [11:08:23.651] AnimatedImageFrame[aif] :: constructor() [11:08:23.652] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.652] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_1.jpg [11:08:23.664] RenCaption[caption] :: _build() [11:08:23.681] Overlay[caption] :: _animate() [11:08:23.684] CanvasStream[caption] :: _init(), p.then() [11:08:23.698] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.703] AnimatedImageFrame[aif] :: _init(), END [11:08:23.704] AnimatedImageFrame[aif] :: constructor() [11:08:23.705] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.705] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_2.jpg [11:08:23.717] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.719] AnimatedImageFrame[aif] :: _init(), END [11:08:23.719] AnimatedImageFrame[aif] :: constructor() [11:08:23.720] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.720] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_3.jpg [11:08:23.731] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.733] AnimatedImageFrame[aif] :: _init(), END [11:08:23.733] AnimatedImageFrame[aif] :: constructor() [11:08:23.734] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.734] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_4.jpg [11:08:23.750] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.751] AnimatedImageFrame[aif] :: _init(), END [11:08:23.751] AnimatedImageFrame[aif] :: constructor() [11:08:23.752] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.752] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_1.jpg [11:08:23.767] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.768] AnimatedImageFrame[aif] :: _init(), END [11:08:23.769] AnimatedImageFrame[aif] :: constructor() [11:08:23.769] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.769] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_2.jpg [11:08:23.787] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.788] AnimatedImageFrame[aif] :: _init(), END [11:08:23.789] AnimatedImageFrame[aif] :: constructor() [11:08:23.789] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.789] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_3.jpg [11:08:23.799] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.800] AnimatedImageFrame[aif] :: _init(), END [11:08:23.801] AnimatedImageFrame[aif] :: constructor() [11:08:23.801] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.801] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_4.jpg [11:08:23.811] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.812] AnimatedImageFrame[aif] :: _init(), END [11:08:23.813] AnimatedImageFrame[aif] :: constructor() [11:08:23.813] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.813] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_1.jpg [11:08:23.824] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.825] AnimatedImageFrame[aif] :: _init(), END [11:08:23.825] AnimatedImageFrame[aif] :: constructor() [11:08:23.826] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.826] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_2.jpg [11:08:23.837] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.838] AnimatedImageFrame[aif] :: _init(), END [11:08:23.838] AnimatedImageFrame[aif] :: constructor() [11:08:23.839] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.839] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_3.jpg [11:08:23.850] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.851] AnimatedImageFrame[aif] :: _init(), END [11:08:23.852] AnimatedImageFrame[aif] :: constructor() [11:08:23.852] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.852] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_4.jpg [11:08:23.862] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.863] AnimatedImageFrame[aif] :: _init(), END [11:08:23.864] AnimatedImageFrame[aif] :: constructor() [11:08:23.864] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.864] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_1.jpg [11:08:23.875] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.876] AnimatedImageFrame[aif] :: _init(), END [11:08:23.877] AnimatedImageFrame[aif] :: constructor() [11:08:23.877] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.877] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_2.jpg [11:08:23.887] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.888] AnimatedImageFrame[aif] :: _init(), END [11:08:23.889] AnimatedImageFrame[aif] :: constructor() [11:08:23.889] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.889] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_3.jpg [11:08:23.900] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.901] AnimatedImageFrame[aif] :: _init(), END [11:08:23.902] AnimatedImageFrame[aif] :: constructor() [11:08:23.902] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.902] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_4.jpg [11:08:23.913] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.914] AnimatedImageFrame[aif] :: _init(), END [11:08:23.915] AnimatedImageFrame[aif] :: constructor() [11:08:23.915] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.915] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_1.jpg [11:08:23.925] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.926] AnimatedImageFrame[aif] :: _init(), END [11:08:23.926] AnimatedImageFrame[aif] :: constructor() [11:08:23.926] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.927] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_2.jpg [11:08:23.936] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.937] AnimatedImageFrame[aif] :: _init(), END [11:08:23.937] AnimatedImageFrame[aif] :: constructor() [11:08:23.938] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.938] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_3.jpg [11:08:23.951] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.952] AnimatedImageFrame[aif] :: _init(), END [11:08:23.952] AnimatedImageFrame[aif] :: constructor() [11:08:23.952] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.952] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_4.jpg [11:08:23.962] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.963] AnimatedImageFrame[aif] :: _init(), END [11:08:23.963] AnimatedImageFrame[aif] :: constructor() [11:08:23.963] AnimatedImageFrame[aif] :: _init(), BEGIN [11:08:23.963] CanvasClip :: LoadImageWithPromise(), src: C5E36224-89F9-2867-23EB-AF79DCDB4DCF_1.jpg [11:08:23.974] CanvasClip :: LoadImageWithPromise(), loaded, isError: false [11:08:23.975] AnimatedImageFrame[aif] :: _init(), END [11:08:23.975] Overlay[simplefadedisplay] :: _animate() [11:08:23.976] KenBurnsSlideshow[simplefadedisplay] :: _init(), END [11:08:23.976] CanvasStream[simplefadedisplay] :: _init(), p.then() [11:08:23.976] CanvasStream[canvas_1738828124317] :: _init(), promise.all.then() [11:08:23.978] CanvasStream[canvas_1738828124317] :: _init(), END [11:08:23.978] StreamMangaer :: init(), stream[canvas_1738828124317].then() [11:08:23.978] Vidbot :: StreamMgr.on( 'STREAM_INITED' ), data: { streamID: 'canvas_1738828124317', progress: 1 } [11:08:23.979] index :: _onStepProgress_vidbot(), percent: 100 [11:08:23.979] StreamManager :: init(), promise.all.then... [11:08:23.979] Vidbot :: StreamMgr.on( 'INITED' ) [11:08:23.979] Vidbot :: _next(), _stepIndex:2 of 4 [11:08:23.979] index :: _onStepCompleted_vidbot(), step: 2 [11:08:23.979] index :: _onStepStarted_vidbot(), step: 3 [11:08:23.979] Vidbot :: step[2], label:Rendering Canvas Streams [11:08:23.980] Vidbot :: StreamMgr.on( 'RENDER_STARTED' ), data: undefined [11:08:23.980] StreamManager :: render() [11:08:23.980] CanvasStream[canvas_1738828124317] :: render() [11:08:24.012] index :: _onStepProgress_vidbot(), percent: 0 [11:08:31.999] index :: _onStepProgress_vidbot(), percent: 5 [11:08:41.143] index :: _onStepProgress_vidbot(), percent: 10 [11:08:51.682] index :: _onStepProgress_vidbot(), percent: 15 [11:09:02.410] index :: _onStepProgress_vidbot(), percent: 20 [11:09:13.245] index :: _onStepProgress_vidbot(), percent: 25 [11:09:24.130] index :: _onStepProgress_vidbot(), percent: 30 [11:09:34.495] index :: _onStepProgress_vidbot(), percent: 35 [11:09:45.452] index :: _onStepProgress_vidbot(), percent: 40 [11:09:56.094] index :: _onStepProgress_vidbot(), percent: 45 [11:10:06.894] index :: _onStepProgress_vidbot(), percent: 50 [11:10:17.638] index :: _onStepProgress_vidbot(), percent: 55 [11:10:28.032] index :: _onStepProgress_vidbot(), percent: 60 [11:10:38.766] index :: _onStepProgress_vidbot(), percent: 65 [11:10:49.482] index :: _onStepProgress_vidbot(), percent: 70 [11:11:00.270] index :: _onStepProgress_vidbot(), percent: 75 [11:11:10.936] index :: _onStepProgress_vidbot(), percent: 80 [11:11:21.227] index :: _onStepProgress_vidbot(), percent: 85 [11:11:32.059] index :: _onStepProgress_vidbot(), percent: 90 [11:11:42.778] index :: _onStepProgress_vidbot(), percent: 95 [11:11:53.741] index :: _onStepProgress_vidbot(), percent: 100 [11:11:55.033] StreamManager :: render(), Promise.all.then... [11:11:55.033] Vidbot :: StreamMgr.on( 'RENDER_COMPLETED' ), data: undefined [11:11:55.033] Vidbot :: _next(), _stepIndex:3 of 4 [11:11:55.034] index :: _onStepCompleted_vidbot(), step: 3 [11:11:55.035] index :: _onStepStarted_vidbot(), step: 4 [11:11:55.036] Vidbot :: step[3], label:Encoding Media [11:11:55.039] CanvasFilters :: Overlay() [11:11:55.039] AudioStream[audio_vo] :: inputOptions() [11:11:55.039] AudioFilters :: Volume() [11:11:55.039] filter: [2:a]volume=1[2_vol] [11:11:55.040] AudioFilters :: Delay() [11:11:55.040] filter: [2_vol]adelay=0|0[2_del] [11:11:55.040] AudioStream[bg_music] :: inputOptions() [11:11:55.040] AudioFilters :: Volume() [11:11:55.040] filter: [3:a]volume=0.25[3_vol] [11:11:55.040] AudioFilters :: FadeOut() [11:11:55.040] filter: [3_vol]afade=t=out:st=60.51:d=1[3_fadeout] [11:11:55.040] AudioFilters :: Delay() [11:11:55.040] filter: [3_fadeout]adelay=0|0[3_del] [11:11:55.041] AudioFilters :: Mix() [11:11:55.041] filter: [2_del][3_del]amix=inputs=2:duration=longest[a_out] [11:11:55.041] mixed filter: [2_del][3_del]amix=inputs=2:duration=longest[a_out] [11:11:55.043] hang.time: 60 [11:11:55.164] Vidbot :: ffmpeg.on( 'start' ) [11:11:55.165] ffmpeg -f lavfi -i color=c=000000:s=640x360:r=30:duration=60.51 -r 30 -i ./tmp/canvas_1738828124317_%05d.png -to 00:01:00.509 -i file:///var/www/html/ [11:11:55.165] clients/3493/audio/C5E36224-89F9-2867-23EB-AF79DCDB4DCF.mp3 -to 00:01:00.509 -i file:///var/app/video_pre_processor/assets/vidbot/_files/audio/Concept [11:11:55.165] 8.mp3 -y -filter_complex [0:v][1:v]overlay=x=0:y=0[1_out];[2:a]volume=1[2_vol];[2_vol]adelay=0|0[2_del];[3:a]volume=0.25[3_vol];[3_vol]afade=t=out:st= [11:11:55.165] 60.51:d=1[3_fadeout];[3_fadeout]adelay=0|0[3_del];[2_del][3_del]amix=inputs=2:duration=longest[a_out] -acodec aac -vcodec libx264 -r 30 -f mp4 -map [a [11:11:55.165] _out] -map [1_out] -preset veryfast -crf 18 -movflags frag_keyframe+empty_moov -pix_fmt yuv420p /var/www/html/clients/3493/video/C5E36224-89F9-2867-23 [11:11:55.165] EB-AF79DCDB4DCF.mp4 [11:11:55.467] index :: _onStepProgress_vidbot(), percent: -3432901103 [11:11:55.814] index :: _onStepProgress_vidbot(), percent: 1 [11:11:56.828] index :: _onStepProgress_vidbot(), percent: 8 [11:11:57.343] index :: _onStepProgress_vidbot(), percent: 13 [11:11:57.849] index :: _onStepProgress_vidbot(), percent: 16 [11:11:58.356] index :: _onStepProgress_vidbot(), percent: 20 [11:11:59.377] index :: _onStepProgress_vidbot(), percent: 27 [11:11:59.884] index :: _onStepProgress_vidbot(), percent: 31 [11:12:00.388] index :: _onStepProgress_vidbot(), percent: 35 [11:12:00.889] index :: _onStepProgress_vidbot(), percent: 40 [11:12:01.891] index :: _onStepProgress_vidbot(), percent: 45 [11:12:02.893] index :: _onStepProgress_vidbot(), percent: 50 [11:12:03.896] index :: _onStepProgress_vidbot(), percent: 58 [11:12:04.424] index :: _onStepProgress_vidbot(), percent: 61 [11:12:04.924] index :: _onStepProgress_vidbot(), percent: 66 [11:12:05.433] index :: _onStepProgress_vidbot(), percent: 71 [11:12:05.935] index :: _onStepProgress_vidbot(), percent: 75 [11:12:06.435] index :: _onStepProgress_vidbot(), percent: 80 [11:12:07.436] index :: _onStepProgress_vidbot(), percent: 87 [11:12:07.936] index :: _onStepProgress_vidbot(), percent: 92 [11:12:08.939] index :: _onStepProgress_vidbot(), percent: 99 [11:12:09.080] index :: _onStepProgress_vidbot(), percent: 100 [11:12:09.255] Vidbot :: ffmpeg.on( 'end' ), Done! [11:12:09.255] StreamManager :: dispose() [11:12:09.256] CanvasStream[canvas_1738828124317] :: dispose() [11:12:09.262] Vidbot :: fflog.on( 'finish' ) [11:12:09.262] fflog.path: /var/www/html/clients/3493/video/C5E36224-89F9-2867-23EB-AF79DCDB4DCF.mp4.fflog [11:12:09.263] Vidbot :: _next(), _stepIndex:4 of 4 [11:12:09.263] index :: _onStepCompleted_vidbot(), step: 4 [11:12:09.263] index :: _onComplete_vidbot(), data: { stepTime: 0, appTime: 225.764, output: '/var/www/html/clients/3493/video/C5E36224-89F9-2867-23EB-AF79DCDB4DCF.mp4', duration: 60.51 } --------------------------------------------------------------------------------------------------------------- Output File : /var/app/video_pre_processor/jobs/postp//var/www/html/clients/3493/video/C5E36224-89F9-2867-23EB-AF79DCDB4DCF.mp4 Media Duration : 00:01:00.509 Generation Time : 00:03:45.764 ---------------------------------------------------------------------------------------------------------------