[mythtv] hack for using removable with mythvideo

Xavier Hervy maxpower44 at tiscali.fr
Fri Aug 20 19:09:39 EDT 2004


J. Donavan Stanley wrote:
> Leo Weppelman wrote:
> 
>> Attached is a quick hack to use the stuff on an inserted cdrom
>> in the video browser. The hack assumes a '/cdrom' mountpoint.
>>  
>>
> 
> There was a fairly comprehensive patch for this some time ago but the 
> author never seemed to manage submitting a version that didn't tack on a 
> bunch of other crap as well...
> 
That's true, "the author" never seemed to manage submitting a version 
that didn't tack on a bunch of others powerfull features like cd 
collection and some easy to use filter in videogallery. The author use 
it actually too this powerfull feature to manage
  movies collection on usb/firewire drive. And the author is very happy 
to have it on his version of mythvideo. But the author decide to stop to 
work with people like you (maybe only you) that take the liberty to crap 
on his patch without trying it before.

Leo, you should use something like this :
MythMediaMonitor *mediamonitor = MythMediaMonitor::MediaMonitor();
if (mediamonitor){
	QValueList <MythMediaDevice*> media = 		
		mediamonitor->getMedias(MEDIATYPE_DATA)
	QValueList <MythMediaDevice*>::Iterator itr = medias.begin()
	While(itr!=medias.end()){
		MythMediaDevice * media = *itr;
		/*
		 * here do stuff with media->getMountPoint() instead of
		 * using /cdrom . that's allow you to have more than one
		 * cdrom in your system
		 */
		itr++;
         }
}

it's only by memory then sorry for mistake.

Xavier
PS : but someone call me too "The author" .



More information about the mythtv-dev mailing list