metadata.proto 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. syntax = "proto2";
  2. message AudioFile {
  3. optional bytes file_id = 1;
  4. optional AudioFormat format = 2;
  5. }
  6. message Restriction {
  7. optional string countries_allowed = 0x2;
  8. optional string countries_forbidden = 0x3;
  9. }
  10. message Image {
  11. optional bytes file_id = 0x1;
  12. }
  13. message ImageGroup {
  14. repeated Image image = 0x1;
  15. }
  16. message Album {
  17. optional bytes gid = 0x1;
  18. optional string name = 0x2;
  19. optional ImageGroup cover_group = 0x11;
  20. }
  21. message Artist {
  22. optional bytes gid = 0x1;
  23. optional string name = 0x2;
  24. }
  25. message Track {
  26. optional bytes gid = 1;
  27. optional string name = 2;
  28. optional sint32 duration = 0x7;
  29. optional Album album = 0x3;
  30. repeated Artist artist = 0x4;
  31. repeated Restriction restriction = 0xb;
  32. repeated AudioFile file = 0xc;
  33. repeated Track alternative = 0xd;
  34. }
  35. message Episode {
  36. optional bytes gid = 1;
  37. optional string name = 2;
  38. optional sint32 duration = 7;
  39. repeated AudioFile file = 12;
  40. repeated Restriction restriction = 0x4B;
  41. optional ImageGroup covers = 0x44;
  42. }
  43. enum AudioFormat {
  44. OGG_VORBIS_96 = 0;
  45. OGG_VORBIS_160 = 1;
  46. OGG_VORBIS_320 = 2;
  47. MP3_256 = 3;
  48. MP3_320 = 4;
  49. MP3_160 = 5;
  50. MP3_96 = 6;
  51. MP3_160_ENC = 7;
  52. AAC_24 = 8;
  53. AAC_48 = 9;
  54. }