Author Topic: DVD Profiler  (Read 16757 times)

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
DVD Profiler
« on: August 12, 2011, 07:18:09 pm »
Sonata31 has submitted a DVD Profiler driver for review and I thought I would start a thread for it here and post a few recommendations.

John Hughes
Codecore Technologies

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
Re: DVD Profiler
« Reply #1 on: August 12, 2011, 07:26:50 pm »
* Please write up a little documentation on what the driver is for and how to set it up, for example how to export from dvd profile, how to generate images folder that he driver uses, etc.

* The RescanLibrary() method is not implemented. This method should rescan the library and then replace the data in memory in a way that does not return partial data if the library is viewed while the file is being loaded. I think you can simply create a new GV object and replace the old one when done loading.

* The driver should automatically refresh the library once every 24 hours to ensure the most recent data is loaded.

* This might be a big one and I mentioned it to you before. It does not appear that the driver supports discs, but only collections. Perhaps I am wrong but it looks to me like when requesting Titles, it actually returns a disc collection and not individual discs. The driver should support the Albums grouping and should return the collection names there. When the titles are requested for a given album/collection then the driver should return the discs for that album/collection. Without this a user will not be able to choose an individual disc and play a media file (or disc) from Elve. If you are not sure what I am referring to I can post example xml from an export file.

* The driver does not currently support locations so that a media player could play the disc/file. I believe the ItemLocation property should be set to the individual disc location. It looks like it is getting set tot he collection number instead. Here's a snippet from my export file:
<Location>c:\vids\Rome.AVI</Location>
You simply need to set the ItemLocation property to the Location value in the file for each disc. Once this is done then the media player drivers will handle the location.

* When reading Genres there are consecutive reader.Read() statements but there is no verification of what is being read. If the xml file format changes your driver may break(?). You should probably be checking reader.NodeType.
Here's the code I am referring to:
Code: [Select]
case "Genres":
// We only remember the first genre
reader.Read();
// Reading the genre (XmlNodeType.Text)
reader.Read();
reader.Read();
// Update the movie
newItem.Genre = reader.Value;
if (String.Compare(newItem.Genre, "a") < 0)
{
newItem.Genre = "Undefined";
}
break;
John Hughes
Codecore Technologies

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
Re: DVD Profiler
« Reply #2 on: August 12, 2011, 07:29:17 pm »
Also, Sonata31 you are more than welcome to post your driver dll or source code here if you would like other users to test or help you with the development.
John Hughes
Codecore Technologies

sonata31

  • Sr. Member
  • ****
  • Posts: 307
    • View Profile
    • Dialou Home-Cinéma
Re: DVD Profiler
« Reply #3 on: September 13, 2011, 03:24:23 am »
« Last Edit: September 26, 2011, 02:43:36 am by sonata31 »

sonata31

  • Sr. Member
  • ****
  • Posts: 307
    • View Profile
    • Dialou Home-Cinéma
Re: DVD Profiler
« Reply #4 on: September 13, 2011, 03:28:59 am »

...

* This might be a big one and I mentioned it to you before. It does not appear that the driver supports discs, but only collections. Perhaps I am wrong but it looks to me like when requesting Titles, it actually returns a disc collection and not individual discs. The driver should support the Albums grouping and should return the collection names there. When the titles are requested for a given album/collection then the driver should return the discs for that album/collection. Without this a user will not be able to choose an individual disc and play a media file (or disc) from Elve. If you are not sure what I am referring to I can post example xml from an export file.

...


Can you detail for example ?

sonata31

  • Sr. Member
  • ****
  • Posts: 307
    • View Profile
    • Dialou Home-Cinéma
Re: DVD Profiler
« Reply #5 on: September 13, 2011, 03:32:33 am »

...

* The driver does not currently support locations so that a media player could play the disc/file. I believe the ItemLocation property should be set to the individual disc location. It looks like it is getting set tot he collection number instead. Here's a snippet from my export file:
<Location>c:\vids\Rome.AVI</Location>
You simply need to set the ItemLocation property to the Location value in the file for each disc. Once this is done then the media player drivers will handle the location.

...


ItemLocation is the number assigned to the physical disk DVD, not a file on hard drive

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
Re: DVD Profiler
« Reply #6 on: September 13, 2011, 08:35:09 am »

...

* The driver does not currently support locations so that a media player could play the disc/file. I believe the ItemLocation property should be set to the individual disc location. It looks like it is getting set tot he collection number instead. Here's a snippet from my export file:
<Location>c:\vids\Rome.AVI</Location>
You simply need to set the ItemLocation property to the Location value in the file for each disc. Once this is done then the media player drivers will handle the location.

...


ItemLocation is the number assigned to the physical disk DVD, not a file on hard drive


The Location XML element can be set to anything you want, it can be a box number or a filename for example.  Many automation users will assign it to the file path of the ripped dvd.

For example here is a snippet from my xml file:

Code: [Select]
<Location>c:\vids\Rome.AVI</Location>

Every media library driver's ItemLocation must be a string which provides a means for the media player driver(s) to play the item. This would normally be a file path such as "c:\vids\Rome.AVI".

So all you need to do is set the ItemLocation property equal to the value in the XML Location element.
« Last Edit: September 13, 2011, 08:41:22 am by John Hughes »
John Hughes
Codecore Technologies

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
Re: DVD Profiler
« Reply #7 on: September 13, 2011, 08:57:14 am »

...

* This might be a big one and I mentioned it to you before. It does not appear that the driver supports discs, but only collections. Perhaps I am wrong but it looks to me like when requesting Titles, it actually returns a disc collection and not individual discs. The driver should support the Albums grouping and should return the collection names there. When the titles are requested for a given album/collection then the driver should return the discs for that album/collection. Without this a user will not be able to choose an individual disc and play a media file (or disc) from Elve. If you are not sure what I am referring to I can post example xml from an export file.

...


Can you detail for example ?


ItemLocation is the number assigned to the physical disk DVD, not a file on hard drive
[/quote]

Using DVDProfiler, add the HBO series called "Rome" to your list. You will see that this is a collection of discs. Each disc also has it's own location per the prior post.


Your driver is currently marked as supporting Titles and Genre's in the SupportedGroupings property. This should be set to Titles, Albums, and Genres.

You have currently implemented the GetGenresArtistsAlbumsOrTitles as follows:

* Titles returns collections BUT it should return individual disc information
* Albums is not supported but it should basically return what you are currently returning for Titles.
* Genres returns Genres (this is probably correct)
* Artist is not supported (this is probably fine although I suppose it could support directors, actors, etc)

I  have taken part of the xml and trimmed it down to demonstrate what I mean below:

Titles should be returning information from: Collection/DVD/Discs/Disc
Albums should be returning information from the: Collection/DVD   (this is what you are returning for titles now)

Code: [Select]
<?xml version="1.0" encoding="windows-1252"?>
<!--DVD Profiler Collection Export-->
<Collection>
  <DVD>
    <ProfileTimestamp>2007-09-09T13:52:00.000Z</ProfileTimestamp>
    <ID>026359379727</ID>
    <MediaTypes>
      <DVD>true</DVD>
      <HDDVD>false</HDDVD>
      <BluRay>false</BluRay>
    </MediaTypes>
    <UPC>026359-379727</UPC>
    <CollectionNumber>1</CollectionNumber>
    <CollectionType>Owned</CollectionType>
    <Title>Rome: The Complete First Season</Title>
    <DistTrait/>
    <OriginalTitle/>
    <CountryOfOrigin>United States</CountryOfOrigin>
    <ProductionYear>2005</ProductionYear>
    <Released>2006-08-15</Released>
    <RunningTime>619</RunningTime>
    <RatingSystem>Film</RatingSystem>
    <Rating>NR</Rating>
    <RatingAge>0</RatingAge>
    <RatingVariant>1</RatingVariant>
    <CaseType>Clamshell</CaseType>
    <Genres>
      <Genre>Drama</Genre>
      <Genre>Action</Genre>
      <Genre>Television</Genre>
    </Genres>
     
...

    <Discs>
      <Disc>
        <DescriptionSideA>Episodes 1-2</DescriptionSideA>
        <DescriptionSideB/>
        <DiscIDSideA/>
        <DiscIDSideB/>
        <LabelSideA/>
        <LabelSideB/>
        <DualLayeredSideA>true</DualLayeredSideA>
        <DualLayeredSideB>false</DualLayeredSideB>
        <DualSided>false</DualSided>
        <Location>c:\vids\rome1.1.vob</Location>
        <Slot/>
      </Disc>
      <Disc>
        <DescriptionSideA>Episodes 3-5</DescriptionSideA>
        <DescriptionSideB/>
        <DiscIDSideA/>
        <DiscIDSideB/>
        <LabelSideA/>
        <LabelSideB/>
        <DualLayeredSideA>true</DualLayeredSideA>
        <DualLayeredSideB>false</DualLayeredSideB>
        <DualSided>false</DualSided>
        <Location>c:\vids\rome1.2.vob</Location>
        <Slot/>
      </Disc>
      <Disc>
        <DescriptionSideA>Episodes 6-8</DescriptionSideA>
        <DescriptionSideB/>
        <DiscIDSideA/>
        <DiscIDSideB/>
        <LabelSideA/>
        <LabelSideB/>
        <DualLayeredSideA>true</DualLayeredSideA>
        <DualLayeredSideB>false</DualLayeredSideB>
        <DualSided>false</DualSided>
        <Location/>
        <Slot/>
      </Disc>
      <Disc>
        <DescriptionSideA>Episodes 9-10</DescriptionSideA>
        <DescriptionSideB/>
        <DiscIDSideA/>
        <DiscIDSideB/>
        <LabelSideA/>
        <LabelSideB/>
        <DualLayeredSideA>true</DualLayeredSideA>
        <DualLayeredSideB>false</DualLayeredSideB>
        <DualSided>false</DualSided>
        <Location/>
        <Slot/>
      </Disc>
      <Disc>
        <DescriptionSideA>Episodes 11-12</DescriptionSideA>
        <DescriptionSideB/>
        <DiscIDSideA/>
        <DiscIDSideB/>
        <LabelSideA/>
        <LabelSideB/>
        <DualLayeredSideA>true</DualLayeredSideA>
        <DualLayeredSideB>false</DualLayeredSideB>
        <DualSided>false</DualSided>
        <Location/>
        <Slot/>
      </Disc>
      <Disc>
        <DescriptionSideA>Bonus Materials</DescriptionSideA>
        <DescriptionSideB/>
        <DiscIDSideA/>
        <DiscIDSideB/>
        <LabelSideA/>
        <LabelSideB/>
        <DualLayeredSideA>false</DualLayeredSideA>
        <DualLayeredSideB>false</DualLayeredSideB>
        <DualSided>false</DualSided>
        <Location/>
        <Slot/>
      </Disc>
    </Discs>
John Hughes
Codecore Technologies

sonata31

  • Sr. Member
  • ****
  • Posts: 307
    • View Profile
    • Dialou Home-Cinéma
Re: DVD Profiler
« Reply #8 on: September 14, 2011, 06:02:08 am »
I would have to specify a number to the physical DVD (I keep my DVD purchase order by assigning a number in chronological order) and a location on hard drive in case the film is as a file
Apart ItemLocation other member can I use for this?

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
Re: DVD Profiler
« Reply #9 on: September 14, 2011, 12:07:31 pm »
I would have to specify a number to the physical DVD (I keep my DVD purchase order by assigning a number in chronological order) and a location on hard drive in case the film is as a file
Apart ItemLocation other member can I use for this?

It is fine if you choose to use the location field for a numeric id. I don't believe DVD Profiler provides any other field to place a ripped dvd filename in... are you aware of one?

John Hughes
Codecore Technologies

sonata31

  • Sr. Member
  • ****
  • Posts: 307
    • View Profile
    • Dialou Home-Cinéma
Re: DVD Profiler
« Reply #10 on: September 14, 2011, 10:45:54 pm »
Yet your screenshot of your previous post shows this possibility!
I do not understand your answer!

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
Re: DVD Profiler
« Reply #11 on: September 15, 2011, 07:45:33 am »
I'm not sure what you mean.

In the screen shots above I only see "Location" and "Slot" as fields related to the location of the disc. You are using these for numeric values which is fine. Other users use "Location" for the file path of a ripped dvd. My question was if you were aware of any other field in DVD Profiler that could be used to store the ripped dvd path by disc.

If not then please set the ItemLocation property in elve to the value in Collection/DVD/Discs/Disc/Location
John Hughes
Codecore Technologies

sonata31

  • Sr. Member
  • ****
  • Posts: 307
    • View Profile
    • Dialou Home-Cinéma
Re: DVD Profiler
« Reply #12 on: September 15, 2011, 09:14:16 am »
In DVD Profiler I do not use Location for the ID but Collection Number
By cons I use ItemLocation in Elve for the ID because I have not found another member to use

John Hughes

  • Administrator
  • Hero Member
  • *****
  • Posts: 2852
    • View Profile
    • Codecore Technologies
Re: DVD Profiler
« Reply #13 on: September 15, 2011, 02:02:24 pm »
In DVD Profiler I do not use Location for the ID but Collection Number
By cons I use ItemLocation in Elve for the ID because I have not found another member to use

The ItemID property should be a unique identifier for the item. For the Album this should be the xml element value at:
Collection/DVD/ID
From the xml in the earlier post this would be: 026359379727

For Titles (individual discs) I don't see a unique disc identifier that DVD Profiler outputs so you can just make up your own ID. As long as it is unique it doesn't matter what you use. I would suggest appending the disc index to the Album ItemID. So using the xml from the earlier post in this thread you could use the following ItemID's for the 6 titles (discs):
026359379727-1
026359379727-2
026359379727-3
026359379727-4
026359379727-5
026359379727-5

For Genres the ItemID can simply be the unique genre name or some other id that uniquely identifies the genre.
« Last Edit: September 15, 2011, 02:07:28 pm by John Hughes »
John Hughes
Codecore Technologies

sonata31

  • Sr. Member
  • ****
  • Posts: 307
    • View Profile
    • Dialou Home-Cinéma
Re: DVD Profiler
« Reply #14 on: September 18, 2011, 11:13:42 pm »
The CollectionNumber is used to find my DVDs that are arranged in chronological order, see photo.
So I can not use the ItemID for that