Wowza Community

Custom Closed Caption TTML file location


Is it possible to define a custom location for a TTML file without using the “wowzacaptionfile” URL parameter? I attempted to use the parameter without success.

I am perfectly willing to extend the provided VODCaptionProviderTTML class and override the method that loads the file if you can point me in the correct direction.

So far I have determined that the default path is created using a pair of regular expressions: “captionPathNamingRule” and “captionFileNamingRule”.

However, each of my TTML files lives in a unique location, so it will be difficult if not impossible to condense the paths to a uniform regex.

Can you tell me what method I could override in order to customize the file path creation logic?

Thank you!

Make sure the caption file is in the same location as the video file and has the same name as the video file.

For example sample.mp4 and sample.ttml. Both in the same directory.

Then use the URL like this:


You can add these properties to the TimedText/Properties section in [install-dir]/conf/Application.xml to help troubleshoot.



If this is working correctly you should see something like this is in the logs:

INFO server comment - VODTimedTextProviderBase.indexTimedText using file:/Library/WowzaMediaServer/content/ for captions (VOD:/Library/WowzaMediaServer/content/VideoEdit.mp4)
INFO server comment - VODTimedTextDelegateBase.narrowProviders[vod/_definst_/VideoEdit.mp4]: provider: vodcaptionproviderttml


I will bring this up tomorrow and get back to you.


I did test and asked around about this. I thought there might be an option to get this file from a web server, but I don’t think there is. The .ttml files have to be in the content folder or below. The only thing I can think of is using symlink as subfolders of content location pointing to these directories.

You might also use MediaCache to setup different file locations, but you will still have to have the .ttml alongside the video,which probably doesn’t solve your problem.


I don’t think source code is available, possible but unlikely. I will try to find out if it is extensible, but it will likely be next week before I can update.


Did you set up JWPlayer to use the ttml file?:

CC with JWPlayer 6

Beyond that this is a little more advanced then I am able to help with. I am sure someone from support will pick this thread up very shortly.

If not you can open a support ticket by emailing Please include a link to this thread as reference.


Hi Salvadore,

Thank you for the reply & the explanation of the URL param requirements.

Unfortunately, the current location of my video files & caption files does not allow for this setup. My videos are stored on a separate server from the associated caption XML.

I have access to fully qualified URLs to each, and there is no relative path available between the two. That is why I am asking to know a bit more about the internals of the VODCaptionProviderTTML such that I could point it to the full path of the caption XML instead.

Does that clarify the question?

Thanks again for your help

As an update: I have tested relocating some TTML file to be alongside their source videos, and named properly, but the CC still does not appear to work.

Does the VODCaptionProviderTTML play nicely with the MediaCache plugin? The videos & TTML files are being loaded from a remote server - could this be the reason I am not seeing captions?

Here are some lines from my server log when the files are in the same folder, and named properly. CustomTTMLLoader is the name I’ve given my attempt at a custom Caption Provider, but it does nothing but extend VODCaptionProviderTTML.

Stream.switch[AppName/_definst_/118]: index: 0 name:mp4:http/ start:0 length:-1
VODTimedTextDelegateBase.findAvailableProviders[AppName/_definst_/118]: available providers: [CustomTTMLLoader]
VODTimedTextDelegateBase.findProvidersThatSupportInterface[AppName/_definst_/118]: interface:com.wowza.wms.timedtext.amf.ITimedTextProviderAMF providers: [CustomTTMLLoader]
VODTimedTextProviderBase.indexTimedText[AppName/_definst_/http/] using file:/Library/WowzaMediaServer/content/http/ for captions (VOD:/Library/WowzaMediaServer/content/http/
VODTimedTextDelegateBase.narrowProviders[AppName/_definst_/118]: providers: [CustomTTMLLoader]
VODTimedTextDelegateBase.determineCaptionLanguages[AppName/_definst_/118]: available providers: [CustomTTMLLoader]
VODTimedTextDelegateBase.determineCaptionLanguages[AppName/_definst_/118]: by property:*
VODTimedTextDelegateBase.determineCaptionLanguages[AppName/_definst_/118]: Provider CustomTTMLLoader supported languages:[eng]
VODTimedTextDelegateBase.determineCaptionLanguages[AppName/_definst_/118]: Found lang:eng provider:CustomTTMLLoader
VODTimedTextDelegateBase.determineCaptionLanguages[AppName/_definst_/118]: Reached maximum languages.  Stop looking.

Of course, the folder /Library/WowzaMediaServer/content/http/ does not exist - http/ is the prefix I’m using for the MediaCache plugin.

Does this output mean that the TTML file is loaded or not? I see no additional logs regarding captions, and no captions appear in the JW Player 6 instance I’m testing with.

Thanks again

Hi Richard, were you able to make any traction on this? Should I follow up via email?

Hmmm, ok. I could possibly pre-fetch the TTML files and load them into the content directory before activating the playback. (Again, the TTML files, the videos & Wowza are on 3 different servers)

Is there any possibility of getting access to the VODCaptionProviderTTML source code? I’d be happy to write custom code to handle this situation, but it appears that the file paths are created in a “black box” method that performs a number of tasks beyond simply loading the file. I would have to copy the original method contents and just replace portions of it.