Duration is always 0

Discuss issues related to PS3 Media Server development (only for programmers)

Re: Duration is always 0

Postby SeeSoubleYou » Thu Nov 17, 2011 5:16 pm

I've got it running for some part. I will create a google code repository later on which I will share, but I want to take a look at the next challenge. I'm afraid that I will have to start messing with the main PMS code: when the percentage a file has been viewed is known, then I want this percentage to be shown in the thumbnail and/or before/after the name of the file. For as far as I can see, the plugin system is not prepared for this...
It is actually SeeDoubleYou...
SeeSoubleYou
 
Posts: 21
Joined: Sun Jan 10, 2010 8:57 pm

Re: Duration is always 0

Postby taconaut » Thu Nov 17, 2011 5:24 pm

SeeSoubleYou wrote:Actually, then it can still go wrong. If for example you have watched a file for 80% and later on you start the file again and skip to 80% of the file and watch it to the end, the calculation will say you have watched it for 20%. In essence this is true, but not suitable for what I want.

That's right. My implementation is only meant to work if watching a file in one piece.

SeeSoubleYou wrote:I'm afraid that I will have to start messing with the main PMS code: when the percentage a file has been viewed is known, then I want this percentage to be shown in the thumbnail and/or before/after the name of the file. For as far as I can see, the plugin system is not prepared for this...

You can't modify the name of the files showing up by default (this would have to be changed in DLNAResource.getDisplayName), but you could add a AdditionalResourceFolderListener showing the files the way you want. This would avoid having to change the pms base code.
If you always wanted to have your most recent videos at the top of the folder in the ps3 or wished you could group all videos with the same genre in one folder, have a look at pms-mlx
taconaut
Project Member
 
Posts: 1075
Joined: Sat Apr 11, 2009 12:29 am
Location: Switzerland

Re: Duration is always 0

Postby SeeSoubleYou » Thu Nov 17, 2011 7:01 pm

I have now edited DLNAMediaInfo.java so that the thumbnail shows the percentage. It is not ideal, but I really like the fact that I don't need additional virtual folders. I'm thinking about creating a patch that would allow plugins that can alter plugins and resource names. I will put everything in a google code project later, so others might have a look at it as well.
It is actually SeeDoubleYou...
SeeSoubleYou
 
Posts: 21
Joined: Sun Jan 10, 2010 8:57 pm

Re: Duration is always 0

Postby SeeSoubleYou » Thu Nov 17, 2011 9:17 pm

The project is now online at https://code.google.com/p/ps3mediaserver-plugin-viewstatus/

If anyone has any comments, please let me know. Please bear in mind that it is a work in progress though :)
It is actually SeeDoubleYou...
SeeSoubleYou
 
Posts: 21
Joined: Sun Jan 10, 2010 8:57 pm

Previous

Return to Developers

Who is online

Users browsing this forum: No registered users and 1 guest