Author Topic: Tagging AVI's,MPG's etc as Movies / TV Shows  (Read 4810 times)

jonesam31

  • Newbie
  • *
  • Posts: 6
    • View Profile
Tagging AVI's,MPG's etc as Movies / TV Shows
« on: May 05, 2008, 10:55:57 pm »
I have a large collection of AVI's/MPG's/BIN's some Movies and some TV Shows.

I have tagged all my movies by genre, by using the "Edit attributes for all files in this directory", what I can't find is a method to do the same for tagging the files as TV Shows or Movies. What would be good is a tool that recursively tags files in an entire directory structure to a certain specification.

Any ideas?

Thanks. Andy.

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: Tagging AVI's,MPG's etc as Movies / TV Shows
« Reply #1 on: May 06, 2008, 12:30:20 am »
I think you may be looking for "Media Subtype" dropdown rather than the actual attributes - if you got to the properties of a file in Media File Sync, you will see it there. Not sure but I think the tool that somebody wrote for copying attributes from one file to many others will propagate this setting as well. Can't remember, but it could have been Niz23 or Lon22 that wrote this - do a search on the forums or wiki for their contributions.

Also, golgoj is writing a nice GUI for creating/editing playlists - he maybe convinced to extend this interface to cover attribute editing...

golgoj4

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1193
  • hrumpf!
    • View Profile
    • Mah Website
Re: Tagging AVI's,MPG's etc as Movies / TV Shows
« Reply #2 on: May 06, 2008, 01:54:13 am »
I think you may be looking for "Media Subtype" dropdown rather than the actual attributes - if you got to the properties of a file in Media File Sync, you will see it there. Not sure but I think the tool that somebody wrote for copying attributes from one file to many others will propagate this setting as well. Can't remember, but it could have been Niz23 or Lon22 that wrote this - do a search on the forums or wiki for their contributions.

Also, golgoj is writing a nice GUI for creating/editing playlists - he maybe convinced to extend this interface to cover attribute editing...

he has been convinced, its just a rather daunting task. But im still working on it (including browser by file/directory) :)
Linuxmce - Where everyone is never wrong, but we are always behind xbmc in the media / ui department.

royw

  • Guru
  • ****
  • Posts: 261
    • View Profile
Re: Tagging AVI's,MPG's etc as Movies / TV Shows
« Reply #3 on: May 06, 2008, 10:50:47 am »
I'm taking a slightly different tack developing a rails web application that allows you to select a set of database records by selecting a set of conditions then apply a set of actions to the selected records.  The db model work is complete, I did a UI, then ran across hobo and am currently reimplementing the UI in hobo.  It's going a little slower than I had hoped but is still progressing.

In the short term, if you are familiar with SQL, you can hack your database.  Here's a script that I have used to set the MediaType to LinuxDVD, the MediaSubType to Movie, and the FileFormat to DVD for all files under /home/pluto/data/videos:
Code: [Select]
$ mysql -u root <fix_dvd_database.sql
# fix_dvd_database.sql:
Code: [Select]
use pluto_media;
update File set EK_MediaType = '3' where IsDirectory = '0' and Path like '/home/public/data/videos%' and EK_MediaType = '5';
update File set FK_MediaSubType = '2' where IsDirectory = '0' and Path like '/home/public/data/videos%' and FK_MediaSubType is null;
update File set FK_FileFormat = '2' where IsDirectory = '0' and Path like '/home/public/data/videos%' and FK_FileFormat is null;
select Path,Filename,FK_FileFormat,FK_MediaSubType,EK_MediaType from File where IsDirectory = '0' and Path like '/home/public/data/videos%';
commit;

Just FYI, here are some useful values (from my 0710 RC1 database):
Code: [Select]
linuxmce@dcerouter:~$ mysql -u root
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 170164
Server version: 5.0.45-Debian_1ubuntu3 Debian etch distribution

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> use pluto_main;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> select PK_MediaType,Description from MediaType;
+--------------+-----------------------+
| PK_MediaType | Description           |
+--------------+-----------------------+
|            1 | LinuxMCE LiveTV       |
|            2 | LinuxMCE CD           |
|            3 | LinuxMCE DVD          |
|            4 | LinuxMCE Audio File   |
|            5 | LinuxMCE Video File   |
|            6 | LinuxMCE Live Radio   |
|            7 | LinuxMCE Pictures     |
|           11 | LiveTV                |
|           12 | DVD                   |
|           13 | OTARadio              |
|           14 | SatelliteRadio        |
|           15 | CableRadio            |
|           16 | VideoTape             |
|           17 | LaserDisc             |
|           18 | Game                  |
|           19 | CD                    |
|           20 | Burning               |
|           21 | Playlist              |
|           22 | Edit Playlist         |
|           23 | Blank Media           |
|           24 | Doc Viewer            |
|           25 | Cassette              |
|           26 | Picture               |
|           27 | LinuxMCE HD-DVD       |
|           28 | LinuxMCE Blu-ray Disc |
|           29 | LinuxMCE Game         |
+--------------+-----------------------+
26 rows in set (0.02 sec)

mysql> use pluto_media;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> select PK_MediaSubType,Description from MediaSubType;
+-----------------+-----------------+
| PK_MediaSubType | Description     |
+-----------------+-----------------+
|               1 | TV Shows        |
|               2 | Movies          |
|               3 | Home Videos     |
|               4 | Sports Events   |
|               5 | Music Videos    |
|               6 | Alternative     |
|               7 | Popular Music   |
|               8 | Classical Music |
|               9 | Learning        |
|              10 | Audio Books     |
+-----------------+-----------------+
10 rows in set (0.00 sec)

mysql> select PK_FileFormat,Description from FileFormat;
+---------------+----------------+
| PK_FileFormat | Description    |
+---------------+----------------+
|             1 | Low Res        |
|             2 | DVD            |
|             3 | Standard Def   |
|             4 | HD 720         |
|             5 | HD 1080        |
|             6 | Low Quality    |
|             7 | MP3            |
|             8 | CD Quality     |
|             9 | High-def audio |
+---------------+----------------+
9 rows in set (0.00 sec)

mysql> quit
Bye

Have fun,
Roy

jonesam31

  • Newbie
  • *
  • Posts: 6
    • View Profile
Re: Tagging AVI's,MPG's etc as Movies / TV Shows
« Reply #4 on: May 14, 2008, 05:20:06 pm »
Guys,

Thankyou so much, that's exactly what I wanted and needed, I do know SQL pretty well and what you've put there will really help. Don't know why I didn't think of it!!!?!?!?!?

Cheers again!

Andy