ewon15,
[quoted text, click to view] > well i'm using actionscript 2.0 ... i have not had a chance
> to dive into AS3.
No worries. :) It just makes a difference in regard to whatever
snippets or samples would be helpful to you.
[quoted text, click to view] > i'm not sure what you mean when you ask me if there is
> metadata in my FLV...
When the FLV file is encoded, it may or may not have additional
information -- the metadata -- embedded into it. MP3 files, for example,
mainly contain audio recordings, but they have the capability of also
containing metadata a such as copyright date, the recording artist's name,
etc. If your FLV has no metadata, then the NetStream.onMetaData event won't
be prompted to do anything.
[quoted text, click to view] > but the way i know the onMetaData method of the NetStream
> class was not being dispatched was by the timer and scrubber
> i set up...plus i put a trace in the method and it was not outputting
> anything...
Sometimes it helps to trace more than just the value of a given object.
It's possible, for example, that the trace() is indeed putting content to
the Output panel, but maybe that content is an empty string.
[quoted text, click to view] > here's the gist of my code:
> [lots of code ...]
Aha. So your trace is "hello," which should certainly be visible in the
Output panel -- provided the FLV file has metadata. That's good. And
you're saying that everything works with absolute paths, but not relative
paths? That makes me wonder if the relative path is hitting the video file
at all. (Of course, it would presumably be obvious if not, because you
wouldn't see the video at all.)
A quick glance at your code doesn't reveal to me anything outright
wrong. Some of that code looks like it was suggested by one of my blog
articles, but I can't be sure of that. (I was going to refer you to my
blog, but I didn't want to send you on a wild goose chase, if you'd already
come from there.)
My general approach, when I run into something baffling like this, is to
isolate the problem area in a separate FLA, so I can study it without the
distraction of the rest of the code. Here's a quick snippet from the Help
docs, for example ...
var nc:NetConnection = new NetConnection();
nc.connect(null);
var ns:NetStream = new NetStream(nc);
ns.onMetaData = function(infoObject:Object) {
for (var propName:String in infoObject) {
trace(propName + " = " + infoObject[propName]);
}
};
ns.play("
http://www.helpexamples.com/flash/video/water.flv");
Paste that into a new FLV, test the SWF, and see if you get output in
your Output panel. You should. Then save that new FLA into the same folder
as your existing work and change the absolute path of that Adobe file to the
absolute path of one of your own. See if the same sort of output appears in
your Output panel. It should. If it doesn't, that means your FLV doesn't
have metadata. If it does, remove the URL portion and see if it still works
locally for the same FLV (your FLV), but with a relative path.
David Stiller
Adobe Community Expert
Dev blog,
http://www.quip.net/blog/ "Luck is the residue of good design."