[Red5] Metadata file generators
Dan Rossi
spam at electroteque.org
Tue Feb 5 00:11:13 PST 2008
apologies its been mentioned before I found the code, just starting on
a recursive / single file generator class
public class MetaDataGenerator {
private String path;
private File flvFile;
public static void main(String[] args) {
if (!args[0].equals(""))
{
MetaDataGenerator meta = new MetaDataGenerator(args[0]);
meta.generate();
}
}
public MetaDataGenerator(String flvPath)
{
path = flvPath;
}
public void generate()
{
try {
flvFile = new File(path);
if (flvFile.isDirectory())
{
} else {
saveMetaData(flvFile);
}
} catch (Exception e) {
}
}
private void saveMetaData(File flvFile) throws Exception
{
FLVReader reader = new FLVReader(flvFile, true);
FileKeyFrameMetaCache cache = new FileKeyFrameMetaCache();
cache.saveKeyFrameMeta(flvFile, reader.analyzeKeyFrames());
}
On 05/02/2008, at 6:07 PM, Dan Rossi wrote:
> Hi there i am soon to be revisiting this, I was wondering if somebody
> had a quick code example of how to load a file and generate the
> metadata file from it ? I was looking at building a tool to iterate
> through directories and generate non existant files.
>
> The other question i should ask is, is this file based system going to
> be superceded with the cache implementation again sometime soon ? This
> would mean its a waste of time to build such an app.
>
> Let me know thanks !
>
> _______________________________________________
> Red5 mailing list
> Red5 at osflash.org
> http://osflash.org/mailman/listinfo/red5_osflash.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://osflash.org/pipermail/red5_osflash.org/attachments/20080205/d4040d9e/attachment.html
More information about the Red5
mailing list