Is there something like an onSeek event? Seeking in remote flv via http parameter.
#16
hmm ok, well i think you are right about if possible avoiding a callback.
afaik i don't think that an onSeek would be that hard to implement, but yes it is best to avoid it.

i was also thinking (a little selfishly, because i want Megavideo seeking to work), that there should be a way to get non-query strings into the url. ie. some way to specify something like this:

original url
megavideo.com/asfah4893gefj/stream.flv
url with seek
megavideo.com/asfah4893gefj/23528009/stream.flv

where 23528009 is the skip. i think this would have to be defined through a regex.

so to sum up, in python you would then do something like this:
Code:
xbmc.player(URL, seekType, SeekKeywordOrRegex)
where seekType would be 'querystring' or 'regex'. if it is querystring then SeekKeywordOrRegex would just be the keyword (ie. 'fs' or 'start'), which is then auto inserted as a query string using the C++ equivalent of urllib.

if it is 'regex' then you would pass a regular expression string that when passed the url and seek value, inserted the seek into the url....

what do you think?
Reply
#17
We definitely need the flexibility to manipulate the URL in any way we want, especially that there is no format standard, so adding the seek keyword regex makes perfect sense.

Who can we ping to help us implementing this?
I guess we also need to update the bug.
Reply
#18
ps. for the seek keyword regex, i thought it can be configured as a splitter regex,
ie. so it splits the url into the two parts that go either side of the seek value. if it is also necessary to insert a few characters, then afaik the same regex can also be used to do this.
the C++ code can then join the two split parts of the url around the seek value.

PS. i would PM my friend on the XBMC team, but he's already working on another internet video streaming patch (cache to file and stream+download).

I want to draft up a complete and accurate code request, that sums up the conclusions we have come to. To this end, i've opened a piratepad document. I'd love it if you make some additions if you get a moment.

once it is done, i'll update the trac ticket with it's contents
Reply
#19
anarchintosh

As requested, I updated
http://piratenpad.de/ep/pad/view/0W7sDxMMfU/latest
let me know if this is enough.

I also played more with the metadata parsing and I found code already implemented in python, c, ruby and Java that parses the filepositions for us. So the hardest part is over, we just need someone familiar with xbmc code to get this implemented for us or if they can point me to right file/s and I will try to figure it out
Reply
#20
Closer to a solution.
developers @ ffmpeg apparently noticed this issue and they recently checked in a solution.
http://patches.libav.org/patch/171/
http://ffmpeg.org/doxygen/trunk/libavfor...ource.html

Now it's just a matter of integrating the changes and testing.
Reply
#21
nice finds danilll, piratenpad.de is not working atm (not sure why), so i can't properly check your changes. i guess we'll have to redraft the document now you've found that ffmpeg patch thing.

only thing is, does this now mean our seek patch will have to go as deep as ffmpeg? (ie. do we have to pass the query string to ffmpeg?)
i must admit, this is all a bit beyond me
Reply
#22
@anarchintosh

I tried to update the FFMPEG libraries in XBMC, but this was too much work and then I built the latest FFMPEG libraries separately and configured xbmc to use it, but this also gave me trouble as many existing classes in xbmc need to be updated.
http://forum.xbmc.org/showthread.php?tid=100601&page=2

At this point, I didn't have any proof if the solution in ffmpeg even works and I had the same question, what about the "seek keyword"....

So I took a different route, compiled MMPlayer with latest FFMPEG, and boommmmmm... It worked.... no buffering on FLV!!! I sniffed the wire to see how it works around the seek keyword and it does not use one, it uses the same way as mp4, for example "Range: bytes=3655680"

Please give mplayer a shot to make sure I am not missing anything here and let's bug get someone to help us getting ffmpeg updated.

Next step,
Reply
#23
One more update:

I tried many online flv streaming links and also went through videodevil links and they all have no issue, the only one that didn't work was megavideo, still old behavior, it waits to buffer.
I download one of the megavido clips and I was not able to extract metadata out of it using flvtool2, so it's possible that the code is failing the same way, but anyhow we have a 80% solution
Reply
#24
@anarchintosh

I was able to compile xbmc with the latest ffmpeg (external librariries) and I verified the seek WORKS!!! Awesome, I will keep doing more testing

Let me know if you need steps on how to get this done,
Reply
#25
hi danill, i haven't got time to do any experimenting over the next few weeks as i'm taking exams, but i'll be able to keep up with this thread.

thats cool about the seek keyword!
1 thing though, could you give the fantasti.cc addon a test? There were plenty of videohosts in that which were not seeking. You might need to check the log though, as some vids are megavideo.

Thats a shame about megavideo. I wonder how it could be fixed, or if it is worth fixing? (it would be a shame to muddy that clever patch with website-specific text...)
Reply
#26
@anarchintosh

No problem, focus on your exams... I will add steps on how to compile and use the latest ffmpeg.

So I Installed fantasti plugin, all clips seek correctly, however, I couldn't find any megavido clip in the list, can you point me to one?
Reply
#27
yeah there is this
http://fantasti.cc/videos/permalink/mega...Fun/83404/
but it doesn't seem to be in the listings anymore. If you've already tested a megavideo link then theres no need to test this.

PS.
Quote:I was able to compile xbmc with the latest ffmpeg (external librariries) and I verified the seek WORKS!!!
Does this mean that flv patch is already in ffmpeg trunk?

As for this,
Quote:I download one of the megavido clips and I was not able to extract metadata out of it using flvtool2
Might flvtool++ do the job?
Reply
#28
@anarchintosh

Previously I compiled xbmc using external ffmpeg libraries, doing that I couldn't figure out how to run the debuger on FFMPEG external code.

So for the last 3 days, I was trying to update the XBMC FFMPEG code and I finally got it to work and last night I was able to set breakpoints on the ffmpeg/flv parsing calls.

A quick test, I can see clearly that megavideo stream is not going through the flv keyframes parsing call, I need to spend time next week to see why and if we can get it to parse.

We need a new bug/RFE to update FFMPEG libraries.
Reply
#29
cool, i'll close the old trac ticket and open a new one

update:
can't close the old one, but i left a comment with a link to the new one, which is at http://trac.xbmc.org/ticket/11586
Reply
#30
@anarchintosh

I don't see updates against the ffmpeg upgrade bug you opened, so I'm not sure if it will even make it into Eden, so I though maybe back-porting the fix might be a more acceptable solution.

If you want to give it a shot, http://trac.xbmc.org/attachment/ticket/1...-patch.log I am running it against dahrma so I can have a stable version on my HTPC.
Reply

Logout Mark Read Team Forum Stats Members Help
Is there something like an onSeek event? Seeking in remote flv via http parameter.1