BOS.* -> BOS.*

This commit is contained in:
Matt Nadareski
2023-03-07 16:59:14 -05:00
parent e32b24c9f6
commit 473cbc5694
591 changed files with 1214 additions and 1214 deletions

View File

@@ -0,0 +1,31 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo.html"/>
public sealed class AudioSubPictureAttributesTable
{
/// <summary>
/// Number of title sets
/// </summary>
public ushort NumberOfTitleSets;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
/// <summary>
/// End address (last byte of last VTS_ATRT)
/// </summary>
public uint EndAddress;
/// <summary>
/// Offset to VTS_ATRT n
/// </summary>
public uint[] Offsets;
/// <summary>
/// Entries
/// </summary>
public AudioSubPictureAttributesTableEntry[] Entries;
}
}

View File

@@ -0,0 +1,23 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo.html"/>
public sealed class AudioSubPictureAttributesTableEntry
{
/// <summary>
/// End address (EA)
/// </summary>
public uint EndAddress;
/// <summary>
/// VTS_CAT (copy of offset 022-025 of the VTS IFO file)
/// 0=unspecified, 1=Karaoke
/// </summary>
public uint Category;
/// <summary>
/// Copy of VTS attributes (offset 100 and on from the VTS IFO
/// file, usually 0x300 bytes long)
/// </summary>
public byte[] AttributesCopy;
}
}

View File

@@ -0,0 +1,26 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo.html"/>
public sealed class CellAddressTable
{
/// <summary>
/// Number of VOB IDs
/// </summary>
public ushort NumberOfVOBIDs;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
/// <summary>
/// End address (last byte of last entry)
/// </summary>
public uint EndAddress;
/// <summary>
/// 12-byte entries
/// </summary>
public CellAddressTableEntry[] Entries;
}
}

View File

@@ -0,0 +1,31 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo.html"/>
public sealed class CellAddressTableEntry
{
/// <summary>
/// VOBidn
/// </summary>
public ushort VOBIdentity;
/// <summary>
/// CELLidn
/// </summary>
public byte CellIdentity;
/// <summary>
/// Reserved
/// </summary>
public byte Reserved;
/// <summary>
/// Starting sector within VOB
/// </summary>
public uint StartingSectorWithinVOB;
/// <summary>
/// Ending sector within VOB
/// </summary>
public uint EndingSectorWithinVOB;
}
}

View File

@@ -0,0 +1,9 @@
namespace BinaryObjectScanner.Models.DVD
{
public static class Constants
{
public const string VideoManagerIFOSignature = "DVDVIDEO-VMG";
public const string VideoTitleSetIFOSignature = "DVDVIDEO-VTS";
}
}

View File

@@ -0,0 +1,56 @@
using System;
namespace BinaryObjectScanner.Models.DVD
{
[Flags]
public enum ProgramChainCategory : byte
{
MenuTypeTitle = 0x02,
Entry = 0x80,
}
[Flags]
public enum TitleType : byte
{
/// <summary>
/// Uop0 Time play or search
/// </summary>
Uop0TimePlayOrSearch = 0x01,
/// <summary>
/// Uop1 PTT play or search
/// </summary>
Uop1PTTPlayOrSearch = 0x02,
/// <summary>
/// Jump/Link/Call commands - exist
/// </summary>
JumpLinkCallExist = 0x04,
/// <summary>
/// Jump/Link/Call commands - button
/// </summary>
JumpLinkCallButton = 0x08,
/// <summary>
/// Jump/Link/Call commands - pre/post
/// </summary>
JumpLinkCallPrePost = 0x10,
/// <summary>
/// Jump/Link/Call commands - cell
/// </summary>
JumpLinkCallCell = 0x20,
/// <summary>
/// 0=one_sequential_pgc
/// 1=not one_sequential (random, shuffle, stills, loops, or more than one pgc)
/// </summary>
ComplexPGC = 0x40,
/// <summary>
/// Reserved
/// </summary>
Reserved = 0x80,
}
}

View File

@@ -0,0 +1,32 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class LanguageUnitTable
{
/// <summary>
/// Number of Language Units
/// </summary>
public ushort NumberOfLanguageUnits;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
/// <summary>
/// End address (last byte of last PGC in last LU)
/// relative to VMGM_PGCI_UT
/// </summary>
public uint EndAddress;
/// <summary>
/// Language Units
/// </summary>
public LanguageUnitTableEntry[] Entries;
/// <summary>
/// Program Chains
/// </summary>
public ProgramChainTable[] ProgramChains;
}
}

View File

@@ -0,0 +1,26 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class LanguageUnitTableEntry
{
/// <summary>
/// ISO639 language code
/// </summary>
public ushort ISO639LanguageCode;
/// <summary>
/// Reserved for language code extension
/// </summary>
public byte Reserved;
/// <summary>
/// Menu existence flag [80 = title]
/// </summary>
public byte MenuExistenceFlag;
/// <summary>
/// Offset to VMGM_LU, relative to VMGM_PGCI_UT
/// </summary>
public uint LanguageUnitOffset;
}
}

View File

@@ -0,0 +1,37 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <summary>
/// The VMG_PTL_MAIT is searched by country, and points to
/// the table for each country.
/// </summary>
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class ParentalManagementMasksTable
{
/// <summary>
/// Number of countries
/// </summary>
public ushort NumberOfCountries;
/// <summary>
/// Number of title sets (NTs)
/// </summary>
public ushort NumberOfTitleSets;
/// <summary>
/// End address (last byte of last PTL_MAIT)
/// </summary>
public uint EndAddress;
/// <summary>
/// Entries
/// </summary>
public ParentalManagementMasksTableEntry[] Entries;
/// <summary>
/// The PTL_MAIT contains the 16-bit masks for the VMG and
/// all title sets for parental management level 8 followed
/// by the masks for level 7, and so on to level 1.
/// </summary>
public byte[][] BitMasks;
}
}

View File

@@ -0,0 +1,21 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class ParentalManagementMasksTableEntry
{
/// <summary>
/// Country code
/// </summary>
public ushort CountryCode;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
/// <summary>
/// Offset to PTL_MAIT
/// </summary>
public uint Offset;
}
}

View File

@@ -0,0 +1,27 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class ProgramChainTable
{
/// <summary>
/// Number of Program Chains
/// </summary>
public ushort NumberOfProgramChains;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
/// <summary>
/// End address (last byte of last PGC in this LU)
/// relative to VMGM_LU
/// </summary>
public uint EndAddress;
/// <summary>
/// Program Chains
/// </summary>
public ProgramChainTableEntry[] Entries;
}
}

View File

@@ -0,0 +1,26 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class ProgramChainTableEntry
{
/// <summary>
/// PGC category
/// </summary>
public ProgramChainCategory Category;
/// <summary>
/// Unknown
/// </summary>
public byte Unknown;
/// <summary>
/// Parental management mask
/// </summary>
public ushort ParentalManagementMask;
/// <summary>
/// Offset to VMGM_PGC, relative to VMGM_LU
/// </summary>
public uint Offset;
}
}

View File

@@ -0,0 +1,26 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class TitlesTable
{
/// <summary>
/// Number of titles
/// </summary>
public ushort NumberOfTitles;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
/// <summary>
/// End address (last byte of last entry)
/// </summary>
public uint EndAddress;
/// <summary>
/// 12-byte entries
/// </summary>
public TitlesTableEntry[] Entries;
}
}

View File

@@ -0,0 +1,42 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo_vmg.html"/>
public sealed class TitlesTableEntry
{
/// <summary>
/// Title type
/// </summary>
public TitleType TitleType;
/// <summary>
/// Number of angles
/// </summary>
public byte NumberOfAngles;
/// <summary>
/// Number of chapters (PTTs)
/// </summary>
public ushort NumberOfChapters;
/// <summary>
/// Parental management mask
/// </summary>
public ushort ParentalManagementMask;
/// <summary>
/// Video Title Set number (VTSN)
/// </summary>
public byte VideoTitleSetNumber;
/// <summary>
/// Title number within VTS (VTS_TTN)
/// </summary>
public byte TitleNumberWithinVTS;
/// <summary>
/// Start sector for VTS, referenced to whole disk
/// (video_ts.ifo starts at sector 00000000)
/// </summary>
public uint VTSStartSector;
}
}

View File

@@ -0,0 +1,16 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo.html"/>
public sealed class VOBUAddressMap
{
/// <summary>
/// End address (last byte of last entry)
/// </summary>
public uint EndAddress;
/// <summary>
/// Starting sector within VOB of nth VOBU
/// </summary>
public uint[] StartingSectors;
}
}

View File

@@ -0,0 +1,150 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo.html"/>
public sealed class VideoManagerIFO
{
/// <summary>
/// "DVDVIDEO-VMG"
/// </summary>
public string Signature;
/// <summary>
/// Last sector of VMG set (last sector of BUP)
/// </summary>
public uint LastVMGSetSector;
/// <summary>
/// Last sector of IFO
/// </summary>
public uint LastIFOSector;
/// <summary>
/// Version number
/// - Byte 0 - Reserved, should be 0
/// - Byte 1, Bits 7-4 - Major version number
/// - Byte 1, Bits 3-0 - Minor version number
/// </summary>
public ushort VersionNumber;
/// <summary>
/// VMG category
/// </summary>
/// <remarks>byte1=prohibited region mask</remarks>
public uint VMGCategory;
/// <summary>
/// Number of volumes
/// </summary>
public ushort NumberOfVolumes;
/// <summary>
/// Volume number
/// </summary>
public ushort VolumeNumber;
/// <summary>
/// Side ID
/// </summary>
public byte SideID;
/// <summary>
/// Number of title sets
/// </summary>
public ushort NumberOfTitleSets;
/// <summary>
/// Provider ID
/// </summary>
public byte[] ProviderID;
/// <summary>
/// VMG POS
/// </summary>
public ulong VMGPOS;
/// <summary>
/// End byte address of VMGI_MAT
/// </summary>
public uint InformationManagementTableEndByteAddress;
/// <summary>
/// Start address of FP_PGC (First Play program chain)
/// </summary>
public uint FirstPlayProgramChainStartAddress;
/// <summary>
/// Start sector of Menu VOB
/// </summary>
public uint MenuVOBStartSector;
/// <summary>
/// Sector pointer to TT_SRPT (table of titles)
/// </summary>
public uint TableOfTitlesSectorPointer;
/// <summary>
/// Sector pointer to VMGM_PGCI_UT (Menu Program Chain table)
/// </summary>
public uint MenuProgramChainTableSectorPointer;
/// <summary>
/// Sector pointer to VMG_PTL_MAIT (Parental Management masks)
/// </summary>
public uint ParentalManagementMasksSectorPointer;
/// <summary>
/// Sector pointer to VMG_VTS_ATRT (copies of VTS audio/sub-picture attributes)
/// </summary>
public uint AudioSubPictureAttributesSectorPointer;
/// <summary>
/// Sector pointer to VMG_TXTDT_MG (text data)
/// </summary>
public uint TextDataSectorPointer;
/// <summary>
/// Sector pointer to VMGM_C_ADT (menu cell address table)
/// </summary>
public uint MenuCellAddressTableSectorPointer;
/// <summary>
/// Sector pointer to VMGM_VOBU_ADMAP (menu VOBU address map)
/// </summary>
public uint MenuVOBUAddressMapSectorPointer;
/// <summary>
/// Video attributes of VMGM_VOBS
/// </summary>
public byte[] VideoAttributes;
/// <summary>
/// Number of audio streams in VMGM_VOBS
/// </summary>
public ushort NumberOfAudioStreams;
/// <summary>
/// Audio attributes of VMGM_VOBS
/// </summary>
public byte[][] AudioAttributes;
/// <summary>
/// Unknown
/// </summary>
public byte[] Unknown;
/// <summary>
/// Number of subpicture streams in VMGM_VOBS (0 or 1)
/// </summary>
public ushort NumberOfSubpictureStreams;
/// <summary>
/// Subpicture attributes of VMGM_VOBS
/// </summary>
public byte[] SubpictureAttributes;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
}
}

View File

@@ -0,0 +1,160 @@
namespace BinaryObjectScanner.Models.DVD
{
/// <see href="https://dvd.sourceforge.net/dvdinfo/ifo.html"/>
public sealed class VideoTitleSetIFO
{
/// <summary>
/// "DVDVIDEO-VTS"
/// </summary>
public string Signature;
/// <summary>
/// Last sector of title set (last sector of BUP)
/// </summary>
public uint LastTitleSetSector;
/// <summary>
/// Last sector of IFO
/// </summary>
public uint LastIFOSector;
/// <summary>
/// Version number
/// - Byte 0 - Reserved, should be 0
/// - Byte 1, Bits 7-4 - Major version number
/// - Byte 1, Bits 3-0 - Minor version number
/// </summary>
public ushort VersionNumber;
/// <summary>
/// VTS category
/// </summary>
/// <remarks>0=unspecified, 1=Karaoke</remarks>
public uint VMGCategory;
/// <summary>
/// Number of volumes
/// </summary>
public ushort NumberOfVolumes;
/// <summary>
/// Volume number
/// </summary>
public ushort VolumeNumber;
/// <summary>
/// Side ID
/// </summary>
public byte SideID;
/// <summary>
/// Number of title sets
/// </summary>
public ushort NumberOfTitleSets;
/// <summary>
/// Provider ID
/// </summary>
public byte[] ProviderID;
/// <summary>
/// VMG POS
/// </summary>
public ulong VMGPOS;
/// <summary>
/// End byte address of VTS_MAT
/// </summary>
public uint InformationManagementTableEndByteAddress;
/// <summary>
/// Start address of FP_PGC (First Play program chain)
/// </summary>
public uint FirstPlayProgramChainStartAddress;
/// <summary>
/// Start sector of Menu VOB
/// </summary>
public uint MenuVOBStartSector;
/// <summary>
/// Start sector of Title VOB
/// </summary>
public uint TitleVOBStartSector;
/// <summary>
/// Sector pointer to VTS_PTT_SRPT (table of Titles and Chapters)
/// </summary>
public uint TableOfTitlesAndChaptersSectorPointer;
/// <summary>
/// Sector pointer to VTS_PGCI (Title Program Chain table)
/// </summary>
public uint TitleProgramChainTableSectorPointer;
/// <summary>
/// Sector pointer to VTSM_PGCI_UT (Menu Program Chain table)
/// </summary>
public uint MenuProgramChainTableSectorPointer;
/// <summary>
/// Sector pointer to VTS_TMAPTI (time map)
/// </summary>
public uint TimeMapSectorPointer;
/// <summary>
/// Sector pointer to VTSM_C_ADT (menu cell address table)
/// </summary>
public uint MenuCellAddressTableSectorPointer;
/// <summary>
/// Sector pointer to VTSM_VOBU_ADMAP (menu VOBU address map)
/// </summary>
public uint MenuVOBUAddressMapSectorPointer;
/// <summary>
/// Sector pointer to VTS_C_ADT (title set cell address table)
/// </summary>
public uint TitleSetCellAddressTableSectorPointer;
/// <summary>
/// Sector pointer to VTS_VOBU_ADMAP (title set VOBU address map)
/// </summary>
public uint TitleSetVOBUAddressMapSectorPointer;
/// <summary>
/// Video attributes of VTSM_VOBS
/// </summary>
public byte[] VideoAttributes;
/// <summary>
/// Number of audio streams in VTSM_VOBS
/// </summary>
public ushort NumberOfAudioStreams;
/// <summary>
/// Audio attributes of VTSM_VOBS
/// </summary>
public byte[][] AudioAttributes;
/// <summary>
/// Unknown
/// </summary>
public byte[] Unknown;
/// <summary>
/// Number of subpicture streams in VTSM_VOBS (0 or 1)
/// </summary>
public ushort NumberOfSubpictureStreams;
/// <summary>
/// Subpicture attributes of VTSM_VOBS
/// </summary>
public byte[] SubpictureAttributes;
/// <summary>
/// Reserved
/// </summary>
public byte[] Reserved;
}
}