Class ClosedCaptions
Namespace: ValveResourceFormat.ClosedCaptions
Assembly: ValveResourceFormat.dll
Represents a collection of closed captions from a VCCD file.
csharp
public class ClosedCaptions : IEnumerable<ClosedCaption>, IEnumerableInheritance
Implements
IEnumerable<ClosedCaption>, IEnumerable
Fields
MAGIC
Magic number for VCCD files ("VCCD").
csharp
public const int MAGIC = 1145258838Field Value
Properties
Captions
Gets the list of captions.
csharp
public List<ClosedCaption> Captions { get; }Property Value
this[string]
Gets a caption by its key.
csharp
public ClosedCaption? this[string key] { get; }Property Value
Methods
GetEnumerator()
Returns an enumerator that iterates through the captions.
csharp
public IEnumerator<ClosedCaption> GetEnumerator()Returns
Read(string)
Opens the specified file and reads all caption entries into memory.
csharp
public void Read(string filename)Parameters
filename string
The file to open and read.
Read(string, Stream)
Reads caption data from the provided stream.
csharp
public void Read(string filename, Stream input)Parameters
filename string
The name of the caption file (used for metadata only).
input Stream
The input to read from.
ToString()
Returns a string that represents the current object.
csharp
public override string ToString()Returns
A string that represents the current object.
Remarks
Exports the captions to KeyValues1 text format (VCD format).

