View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 6 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Thu May 24, 2007 3:16 pm 
Offline
Joined: Tue Aug 31, 2004 12:52 pm
Posts: 23
I have some music videos. Is there is a way to randomly play them in a folder or a set of folders?

I'm running R5F1. Everything works, just would be neat to have some music video's running for parties and such. Thanks.


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 4:26 pm 
Offline
Joined: Mon Jul 31, 2006 10:41 pm
Posts: 149
Although I've only used it to play one avi after one other, you might try in the video manager by selecting a video then the return key. You should see an option to play another file following the current file. Maybe it will work.


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 24, 2007 10:03 pm 
Offline
Joined: Tue Mar 22, 2005 9:18 pm
Posts: 1422
Location: Brisbane, Queensland, Australia
Using that method you have to specify the next file and then you have to specify the next one and the next one and so on.

This would be a nice function though.

_________________
Girkers


Top
 Profile  
 
 Post subject:
PostPosted: Fri May 25, 2007 7:05 am 
Offline
Joined: Sat Sep 02, 2006 9:17 am
Posts: 359
I've thought about this in the past, but other projects have kept me from working on it. what's needed is some sort of shuffler to automate mythedoff's suggestion. The "shuffler" can be implemented as anything from a command-line script to a Java GUI to a full-blown myth plugin. I'm a java guy -- YMMV. Here's the outline:

You would need to query the videometadata table for the intid column value for all of your music videos. I would recommend putting all your videos in a particular folder, then your query would be
Code:
select intid from mythconverg.videometadata where filename like '/your/folder/path/%';

copy the int ids into some sort of list or array, and shuffle it. A random shuffle like java's Collections.shuffle, would be fine.
Assuming you have an array called intIds what you need to do looks something like:
Code:
for(int i=0; i<intIds.length; ++i) {
int j = i+1;
if (j == intIds.length) j=0;
update mythconverg.videometadata set childid=intIds[j] where intid=intIds[i];
}

I realize that's not true code. The idea is that each row's childid, gets set to intid of the next video on the shuffled list. After your script/app runs you can start mythvideo and play any of your videos. Mythvideo will then continue to play all your videos in shuffled order until you tell it to stop.

I don't know perl well enough to implement this as a script. And I think a java implementation would be overblown, (and require the MySQL JDBC Connector) Anyone got some mad perl skills?


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 27, 2007 8:11 pm 
Offline
Joined: Tue Mar 22, 2005 9:18 pm
Posts: 1422
Location: Brisbane, Queensland, Australia
Whilst keeping all your music vids in one folder is something that I do, some people might like to keep them listed by artist and that sort of thing. What would probably be more robust would be to query the mythconverg DB for all videos listed as music videos, that way they can be stored where ever the user likes.

_________________
Girkers


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 28, 2007 11:14 am 
Offline
Joined: Sat Sep 02, 2006 9:17 am
Posts: 359
I wasn't suggesting dumping all the music videos into a SINGLE folder, although I see how it reads that way. More specifically I was suggesting structuring all music videos under a single parent folder, for example:
/myth/videos/music/artist1/...
/myth/videos/music/artist2/...

With your idea how do music videos get listed as music videos instead of non-music videos? by category? The select for that would still be pretty basic:
Code:
select a.intid
from
    mythconverg.videometadata a,
    mythconverg.videocategory b
where
    a.category=b.intid and
    b.category='Music Video'


I think both implementations would work equally well, wouldn't call either implementation more or less robust than the other. (IMO managing categories in VideoManager is a royal PITA, whereas directories are a bit easier) What I think would add robustness to either implementation is if the videometadata rating or userrating columns were brought in so that you could shuffle at or below a certain rating; For grown-up parties versus family parties for instance.


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu