diff options
author | sr55 <[email protected]> | 2011-03-13 16:44:49 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2011-03-13 16:44:49 +0000 |
commit | b6a5d4eba610711d15ed99dc5f2e9e126ce06086 (patch) | |
tree | e72eb5be161c3ac9b01bbc3b3efcd4ab8f91e06c /win/CS/HandBrake.ApplicationServices/Model | |
parent | 38f64c238720fe0524f99b380fbb1a8c795a7586 (diff) |
Rename Direction C# to CS
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3846 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrake.ApplicationServices/Model')
22 files changed, 1148 insertions, 0 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Model/DriveInformation.cs b/win/CS/HandBrake.ApplicationServices/Model/DriveInformation.cs new file mode 100644 index 000000000..65708cee2 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/DriveInformation.cs @@ -0,0 +1,44 @@ +/* DriveInformation.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model
+{
+ /// <summary>
+ /// Information about a DVD drive
+ /// </summary>
+ public class DriveInformation
+ {
+ /// <summary>
+ /// Gets or sets A Unique ID That represemts this model.
+ /// </summary>
+ public int Id { get; set; }
+
+ /// <summary>
+ /// Gets or sets The Drive Volume Name
+ /// </summary>
+ public string VolumeLabel { get; set; }
+
+ /// <summary>
+ /// Gets or sets The Root Directory
+ /// </summary>
+ public string RootDirectory { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether this is a BluRay Drive.
+ /// </summary>
+ public bool IsBluRay { get; set; }
+
+ /// <summary>
+ /// Returns "Drive" + Id (e.g Drive2)
+ /// </summary>
+ /// <returns>
+ /// A String that contrains "Drive" and it's ID
+ /// </returns>
+ public override string ToString()
+ {
+ return "Drive" + this.Id;
+ }
+ }
+}
\ No newline at end of file diff --git a/win/CS/HandBrake.ApplicationServices/Model/EncodeTask.cs b/win/CS/HandBrake.ApplicationServices/Model/EncodeTask.cs new file mode 100644 index 000000000..d600ba81c --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/EncodeTask.cs @@ -0,0 +1,326 @@ +/* EncodeTask.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model
+{
+ using System.Collections.Generic;
+
+ using HandBrake.ApplicationServices.Model.Encoding;
+
+ /// <summary>
+ /// An Encode Task
+ /// </summary>
+ public class EncodeTask
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="EncodeTask"/> class.
+ /// </summary>
+ public EncodeTask()
+ {
+ this.Cropping = new Cropping();
+ }
+
+ #region Source
+ /// <summary>
+ /// Gets or sets Source.
+ /// </summary>
+ public string Source { get; set; }
+
+ /// <summary>
+ /// Gets or sets Title.
+ /// </summary>
+ public int Title { get; set; }
+
+ /// <summary>
+ /// Gets or sets the Angle
+ /// </summary>
+ public int Angle { get; set; }
+
+ /// <summary>
+ /// Gets or sets PointToPointMode.
+ /// </summary>
+ public PointToPointMode PointToPointMode { get; set; }
+
+ /// <summary>
+ /// Gets or sets StartPoint.
+ /// </summary>
+ public int StartPoint { get; set; }
+
+ /// <summary>
+ /// Gets or sets EndPoint.
+ /// </summary>
+ public int EndPoint { get; set; }
+ #endregion
+
+ #region Destination
+
+ /// <summary>
+ /// Gets or sets Destination.
+ /// </summary>
+ public string Destination { get; set; }
+
+ #endregion
+
+ #region Output Settings
+ /// <summary>
+ /// Gets or sets OutputFormat.
+ /// </summary>
+ public OutputFormat OutputFormat { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether LargeFile.
+ /// </summary>
+ public bool LargeFile { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether Optimize.
+ /// </summary>
+ public bool OptimizeMP4 { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether IPod5GSupport.
+ /// </summary>
+ public bool IPod5GSupport { get; set; }
+ #endregion
+
+ #region Picture
+
+ /// <summary>
+ /// Gets or sets Width.
+ /// </summary>
+ public int Width { get; set; }
+
+ /// <summary>
+ /// Gets or sets Height.
+ /// </summary>
+ public int Height { get; set; }
+
+ /// <summary>
+ /// Gets or sets MaxWidth.
+ /// </summary>
+ public int MaxWidth { get; set; }
+
+ /// <summary>
+ /// Gets or sets MaxHeight.
+ /// </summary>
+ public int MaxHeight { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether CustomCropping.
+ /// </summary>
+ public bool IsCustomCropping { get; set; }
+
+ /// <summary>
+ /// Gets or sets Cropping.
+ /// </summary>
+ public Cropping Cropping { get; set; }
+
+ /// <summary>
+ /// Gets or sets Anamorphic.
+ /// </summary>
+ public Anamorphic Anamorphic { get; set; }
+
+ /// <summary>
+ /// Gets or sets DisplayWidth.
+ /// </summary>
+ public double DisplayWidth { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether KeepDisplayAspect.
+ /// </summary>
+ public bool KeepDisplayAspect { get; set; }
+
+ /// <summary>
+ /// Gets or sets PixelAspectX.
+ /// </summary>
+ public int PixelAspectX { get; set; }
+
+ /// <summary>
+ /// Gets or sets PixelAspectY.
+ /// </summary>
+ public int PixelAspectY { get; set; }
+
+ /// <summary>
+ /// Gets or sets Modulus.
+ /// </summary>
+ public int Modulus { get; set; }
+ #endregion
+
+ #region Filters
+
+ /// <summary>
+ /// Gets or sets Deinterlace.
+ /// </summary>
+ public Deinterlace Deinterlace { get; set; }
+
+ /// <summary>
+ /// Gets or sets CustomDeinterlace.
+ /// </summary>
+ public string CustomDeinterlace { get; set; }
+
+ /// <summary>
+ /// Gets or sets Decomb.
+ /// </summary>
+ public Decomb Decomb { get; set; }
+
+ /// <summary>
+ /// Gets or sets CustomDecomb.
+ /// </summary>
+ public string CustomDecomb { get; set; }
+
+ /// <summary>
+ /// Gets or sets Detelecine.
+ /// </summary>
+ public Detelecine Detelecine { get; set; }
+
+ /// <summary>
+ /// Gets or sets CustomDetelecine.
+ /// </summary>
+ public string CustomDetelecine { get; set; }
+
+ /// <summary>
+ /// Gets or sets Denoise.
+ /// </summary>
+ public Denoise Denoise { get; set; }
+
+ /// <summary>
+ /// Gets or sets CustomDenoise.
+ /// </summary>
+ public string CustomDenoise { get; set; }
+
+ /// <summary>
+ /// Gets or sets Deblock.
+ /// </summary>
+ public int Deblock { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether Grayscale.
+ /// </summary>
+ public bool Grayscale { get; set; }
+ #endregion
+
+ #region Video
+
+ /// <summary>
+ /// Gets or sets VideoEncodeRateType.
+ /// </summary>
+ public VideoEncodeRateMode VideoEncodeRateType { get; set; }
+
+ /// <summary>
+ /// Gets or sets the VideoEncoder
+ /// </summary>
+ public VideoEncoder VideoEncoder { get; set; }
+
+ /// <summary>
+ /// Gets or sets the Video Encode Mode
+ /// </summary>
+ public FramerateMode FramerateMode { get; set; }
+
+ /// <summary>
+ /// Gets or sets Quality.
+ /// </summary>
+ public double? Quality { get; set; }
+
+ /// <summary>
+ /// Gets or sets VideoBitrate.
+ /// </summary>
+ public int? VideoBitrate { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether TwoPass.
+ /// </summary>
+ public bool TwoPass { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether TurboFirstPass.
+ /// </summary>
+ public bool TurboFirstPass { get; set; }
+
+ /// <summary>
+ /// Gets or sets Framerate.
+ /// Null = Same as Source
+ /// </summary>
+ public double? Framerate { get; set; }
+
+ #endregion
+
+ #region Audio
+
+ /// <summary>
+ /// Gets or sets AudioEncodings.
+ /// </summary>
+ public List<AudioTrack> AudioTracks { get; set; }
+ #endregion
+
+ #region Subtitles
+
+ /// <summary>
+ /// Gets or sets SubtitleTracks.
+ /// </summary>
+ public List<SubtitleTrack> SubtitleTracks { get; set; }
+ #endregion
+
+ #region Chapters
+
+ /// <summary>
+ /// Gets or sets a value indicating whether IncludeChapterMarkers.
+ /// </summary>
+ public bool IncludeChapterMarkers { get; set; }
+
+ /// <summary>
+ /// Gets or sets ChapterMarkersFilePath.
+ /// </summary>
+ public string ChapterMarkersFilePath { get; set; }
+
+ #endregion
+
+ #region Advanced
+
+ /// <summary>
+ /// Gets or sets AdvancedEncoderOptions.
+ /// </summary>
+ public string AdvancedEncoderOptions { get; set; }
+
+ #endregion
+
+ #region Preset Information (TODO This should probably be dropped)
+
+ /// <summary>
+ /// Gets or sets PresetBuildNumber.
+ /// </summary>
+ public int PresetBuildNumber { get; set; }
+
+ /// <summary>
+ /// Gets or sets PresetDescription.
+ /// </summary>
+ public string PresetDescription { get; set; }
+
+ /// <summary>
+ /// Gets or sets PresetName.
+ /// </summary>
+ public string PresetName { get; set; }
+
+ /// <summary>
+ /// Gets or sets Type.
+ /// </summary>
+ public string Type { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether UsesMaxPictureSettings.
+ /// </summary>
+ public bool UsesMaxPictureSettings { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether UsesPictureFilters.
+ /// </summary>
+ public bool UsesPictureFilters { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether UsesPictureSettings.
+ /// </summary>
+ public bool UsesPictureSettings { get; set; }
+ #endregion
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/Anamorphic.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Anamorphic.cs new file mode 100644 index 000000000..c958b777c --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Anamorphic.cs @@ -0,0 +1,24 @@ +/* Anamorphic.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ using System.ComponentModel;
+
+ /// <summary>
+ /// Anamorphic Mode
+ /// </summary>
+ public enum Anamorphic
+ {
+ [Description("None")]
+ None = 0,
+ [Description("Strict")]
+ Strict,
+ [Description("Loose")]
+ Loose,
+ [Description("Custom")]
+ Custom
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioEncoder.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioEncoder.cs new file mode 100644 index 000000000..c6f838ed7 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioEncoder.cs @@ -0,0 +1,33 @@ +/* AudioEncoder.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ using System.ComponentModel;
+
+ public enum AudioEncoder
+ {
+ [Description("AAC (faac)")]
+ Faac = 0,
+
+ [Description("MP3 (lame)")]
+ Lame,
+
+ [Description("AC3 (ffmpeg)")]
+ Ac3,
+
+ [Description("Passthrough (AC3/DTS)")]
+ Passthrough,
+
+ [Description("Passthrough (AC3)")]
+ Ac3Passthrough,
+
+ [Description("Passthrough (DTS)")]
+ DtsPassthrough,
+
+ [Description("Vorbis (vorbis)")]
+ Vorbis
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs new file mode 100644 index 000000000..bcfb27089 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/AudioTrack.cs @@ -0,0 +1,56 @@ +/* AudioTrack.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// An Audio Track for the Audio Panel
+ /// </summary>
+ public class AudioTrack
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="AudioTrack"/> class.
+ /// </summary>
+ public AudioTrack()
+ {
+ // Default Values
+ this.Track = "Automatic";
+ this.MixDown = "Automatic";
+ this.SampleRate = "Auto";
+ this.Bitrate = "Auto";
+ this.DRC = "1";
+ }
+
+ /// <summary>
+ /// Gets or sets Audio Track Name
+ /// </summary>
+ public string Track { get; set; }
+
+ /// <summary>
+ /// Gets or sets Audio Mixdown
+ /// </summary>
+ public string MixDown { get; set; }
+
+ /// <summary>
+ /// Gets or sets Audio Encoder
+ /// </summary>
+ public string Encoder { get; set; }
+
+ /// <summary>
+ /// Gets or sets Audio Bitrate
+ /// </summary>
+ public string Bitrate { get; set; }
+
+ /// <summary>
+ /// Gets or sets Audio SampleRate
+ /// </summary>
+ public string SampleRate { get; set; }
+
+ /// <summary>
+ /// Gets or sets Dynamic Range Compression
+ /// </summary>
+ public string DRC { get; set; }
+ }
+}
\ No newline at end of file diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/Cropping.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Cropping.cs new file mode 100644 index 000000000..2ec98aaca --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Cropping.cs @@ -0,0 +1,63 @@ +/* Cropping.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// Cropping T B L R
+ /// </summary>
+ public class Cropping
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="Cropping"/> class.
+ /// </summary>
+ public Cropping()
+ {
+ }
+
+ /// <summary>
+ /// Initializes a new instance of the <see cref="Cropping"/> class.
+ /// </summary>
+ /// <param name="top">
+ /// The Top Value
+ /// </param>
+ /// <param name="bottom">
+ /// The Bottom Value
+ /// </param>
+ /// <param name="left">
+ /// The Left Value
+ /// </param>
+ /// <param name="right">
+ /// The Right Value
+ /// </param>
+ public Cropping(int top, int bottom, int left, int right)
+ {
+ this.Top = top;
+ this.Bottom = bottom;
+ this.Left = left;
+ this.Right = right;
+ }
+
+ /// <summary>
+ /// Gets or sets Top.
+ /// </summary>
+ public int Top { get; set; }
+
+ /// <summary>
+ /// Gets or sets Bottom.
+ /// </summary>
+ public int Bottom { get; set; }
+
+ /// <summary>
+ /// Gets or sets Left.
+ /// </summary>
+ public int Left { get; set; }
+
+ /// <summary>
+ /// Gets or sets Right.
+ /// </summary>
+ public int Right { get; set; }
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/Decomb.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Decomb.cs new file mode 100644 index 000000000..ae8b8a3d4 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Decomb.cs @@ -0,0 +1,17 @@ +/* Decomb.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// Decomb Mode
+ /// </summary>
+ public enum Decomb
+ {
+ Off = 0,
+ Default,
+ Custom
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/Deinterlace.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Deinterlace.cs new file mode 100644 index 000000000..38dadd04e --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Deinterlace.cs @@ -0,0 +1,20 @@ +/* Deinterlace.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// The Deinterlace Filter
+ /// </summary>
+ public enum Deinterlace
+ {
+ Off = 0,
+ Fast,
+ Slow,
+ Slower,
+ Slowest,
+ Custom
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/Denoise.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Denoise.cs new file mode 100644 index 000000000..fc81e9f20 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Denoise.cs @@ -0,0 +1,19 @@ +/* Denoise.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// The Denose Filters
+ /// </summary>
+ public enum Denoise
+ {
+ Off = 0,
+ Weak,
+ Medium,
+ Strong,
+ Custom
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/Detelecine.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Detelecine.cs new file mode 100644 index 000000000..09c948dbd --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Detelecine.cs @@ -0,0 +1,17 @@ +/* Detelecine.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// Detelecine Filter
+ /// </summary>
+ public enum Detelecine
+ {
+ Off = 0,
+ Default,
+ Custom
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/FramerateMode.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/FramerateMode.cs new file mode 100644 index 000000000..508e63ced --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/FramerateMode.cs @@ -0,0 +1,17 @@ +/* VideoEncoderMode.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// The Mode of Video Encoding. CFR, VFR, PFR
+ /// </summary>
+ public enum FramerateMode
+ {
+ CFR = 0,
+ PFR,
+ VFR
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/Mixdown.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Mixdown.cs new file mode 100644 index 000000000..12611b454 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/Mixdown.cs @@ -0,0 +1,33 @@ +/* Mixdown.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ using System.ComponentModel;
+
+ /// <summary>
+ /// The Mixdown Mode
+ /// </summary>
+ public enum Mixdown
+ {
+ [Description("Dolby Pro Logic II")]
+ DolbyProLogicII = 0,
+
+ [Description("Auto")]
+ Auto,
+
+ [Description("Mono")]
+ Mono,
+
+ [Description("Stereo")]
+ Stereo,
+
+ [Description("Dolby Surround")]
+ DolbySurround,
+
+ [Description("6 Channel Discrete")]
+ SixChannelDiscrete
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/OutputFormat.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/OutputFormat.cs new file mode 100644 index 000000000..fa5c3225f --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/OutputFormat.cs @@ -0,0 +1,24 @@ +/* OutputFormat.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ using System.ComponentModel;
+
+ /// <summary>
+ /// The Output format.
+ /// </summary>
+ public enum OutputFormat
+ {
+ [Description("MP4")]
+ Mp4,
+
+ [Description("M4V")]
+ M4V,
+
+ [Description("MKV")]
+ Mkv
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/PointToPointMode.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/PointToPointMode.cs new file mode 100644 index 000000000..dcee4cac4 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/PointToPointMode.cs @@ -0,0 +1,17 @@ +/* PointToPoint.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// Point to Point Mode
+ /// </summary>
+ public enum PointToPointMode
+ {
+ Chapters = 0,
+ Seconds,
+ Frames
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/SubtitleTrack.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/SubtitleTrack.cs new file mode 100644 index 000000000..f69abed7d --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/SubtitleTrack.cs @@ -0,0 +1,95 @@ +/* SubtitleTrack.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ using System.Windows.Forms;
+
+ /// <summary>
+ /// Subtitle Information
+ /// </summary>
+ public class SubtitleTrack
+ {
+ /// <summary>
+ /// Gets or sets Track.
+ /// </summary>
+ public string Track { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether Forced.
+ /// </summary>
+ public bool Forced { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether Burned.
+ /// </summary>
+ public bool Burned { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether Default.
+ /// </summary>
+ public bool Default { get; set; }
+
+ #region SRT Specific Options
+
+ /// <summary>
+ /// Gets or sets the SRT Language
+ /// </summary>
+ public string SrtLang { get; set; }
+
+ /// <summary>
+ /// Gets or sets the SRT Character Code
+ /// </summary>
+ public string SrtCharCode { get; set; }
+
+ /// <summary>
+ /// Gets or sets the SRT Offset
+ /// </summary>
+ public int SrtOffset { get; set; }
+
+ /// <summary>
+ /// Gets or sets the Path to the SRT file
+ /// </summary>
+ public string SrtPath { get; set; }
+
+ /// <summary>
+ /// Gets or sets the SRT Filename
+ /// </summary>
+ public string SrtFileName { get; set; }
+
+ /// <summary>
+ /// Gets a value indicating whether this is an SRT subtitle.
+ /// </summary>
+ public bool IsSrtSubtitle
+ {
+ get { return this.SrtFileName != "-"; }
+ }
+
+ #endregion
+
+ /// <summary>
+ /// Gets or sets the type of the subtitle
+ /// </summary>
+ public SubtitleType SubtitleType { get; set; }
+
+ /// <summary>
+ /// Gets A ListViewItem Containing information about this subitlte
+ /// </summary>
+ public ListViewItem ListView
+ {
+ get
+ {
+ var listTrack = new ListViewItem(this.Track);
+ listTrack.SubItems.Add(this.Forced ? "Yes" : "No");
+ listTrack.SubItems.Add(this.Burned ? "Yes" : "No");
+ listTrack.SubItems.Add(this.Default ? "Yes" : "No");
+ listTrack.SubItems.Add(this.SrtLang);
+ listTrack.SubItems.Add(this.SrtCharCode);
+ listTrack.SubItems.Add(this.SrtOffset.ToString());
+ return listTrack;
+ }
+ }
+ }
+}
\ No newline at end of file diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/SubtitleType.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/SubtitleType.cs new file mode 100644 index 000000000..5a69d0105 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/SubtitleType.cs @@ -0,0 +1,30 @@ +/* SubtitleType.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ using System.ComponentModel;
+
+ /// <summary>
+ /// Subtitle Type.
+ /// </summary>
+ public enum SubtitleType
+ {
+ [Description("SSA")]
+ SSA,
+ [Description("SRT")]
+ SRT,
+ [Description("VobSub")]
+ VobSub,
+ [Description("CC")]
+ CC,
+ [Description("UTF8")]
+ UTF8Sub,
+ [Description("TX3G")]
+ TX3G,
+ [Description("Unknown")]
+ Unknown
+ }
+}
\ No newline at end of file diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/VideoEncodeRateMode.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/VideoEncodeRateMode.cs new file mode 100644 index 000000000..636d7829d --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/VideoEncodeRateMode.cs @@ -0,0 +1,17 @@ +/* VideoEncoderRateMode.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ /// <summary>
+ /// The Mode of Video Encoding. Bitrate, Filesize or Quality
+ /// </summary>
+ public enum VideoEncodeRateMode
+ {
+ TargetSize = 0,
+ AverageBitrate,
+ ConstantQuality
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Encoding/VideoEncoder.cs b/win/CS/HandBrake.ApplicationServices/Model/Encoding/VideoEncoder.cs new file mode 100644 index 000000000..b5a2556e3 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Encoding/VideoEncoder.cs @@ -0,0 +1,24 @@ +/* VideoEncoder.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.Encoding
+{
+ using System.ComponentModel;
+
+ /// <summary>
+ /// The Video Encoder
+ /// </summary>
+ public enum VideoEncoder
+ {
+ [Description("H.264 (x264)")]
+ X264 = 0,
+
+ [Description("MPEG-4 (FFMpeg)")]
+ FFMpeg,
+
+ [Description("VP3 (Theora)")]
+ Theora
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/General/UpdateCheckInformation.cs b/win/CS/HandBrake.ApplicationServices/Model/General/UpdateCheckInformation.cs new file mode 100644 index 000000000..5932aa402 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/General/UpdateCheckInformation.cs @@ -0,0 +1,53 @@ +/* UpdateCheckInformation.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.General
+{
+ using System;
+
+ /// <summary>
+ /// Provides information about an update check.
+ /// </summary>
+ public struct UpdateCheckInformation
+ {
+ /// <summary>
+ /// Gets or sets a value indicating whether a New Version is Available.
+ /// </summary>
+ public bool NewVersionAvailable { get; set; }
+
+ /// <summary>
+ /// Gets a value indicating whether an Error Occured.
+ /// </summary>
+ public bool ErrorOccured
+ {
+ get { return this.Error != null; }
+ }
+
+ /// <summary>
+ /// Gets or sets Information about an update to HandBrake
+ /// </summary>
+ public Uri DescriptionUrl { get; set; }
+
+ /// <summary>
+ /// Gets or sets HandBrake's version from the appcast.xml file.
+ /// </summary>
+ public string Version { get; set; }
+
+ /// <summary>
+ /// Gets or sets HandBrake's Build from the appcast.xml file.
+ /// </summary>
+ public string Build { get; set; }
+
+ /// <summary>
+ /// Gets or sets the URL for update file.
+ /// </summary>
+ public string DownloadFile { get; set; }
+
+ /// <summary>
+ /// Gets or sets the error that occurred, if any. This will be null if no error occured.
+ /// </summary>
+ public Exception Error { get; set; }
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/General/UpdateCheckResult.cs b/win/CS/HandBrake.ApplicationServices/Model/General/UpdateCheckResult.cs new file mode 100644 index 000000000..2f7c7e874 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/General/UpdateCheckResult.cs @@ -0,0 +1,71 @@ +/* UpdateCheckResult.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model.General
+{
+ using System;
+ using System.Threading;
+
+ /// <summary>
+ /// Used in EndUpdateCheck() for update checking and the IAsyncResult design pattern.
+ /// </summary>
+ public class UpdateCheckResult : IAsyncResult
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="UpdateCheckResult"/> class.
+ /// </summary>
+ /// <param name="asyncState">
+ /// The async state.
+ /// </param>
+ /// <param name="info">
+ /// The info.
+ /// </param>
+ public UpdateCheckResult(object asyncState, ApplicationServices.Model.General.UpdateCheckInformation info)
+ {
+ this.AsyncState = asyncState;
+ this.Result = info;
+ }
+
+ /// <summary>
+ /// Gets whether the check was executed in debug mode.
+ /// </summary>
+ public object AsyncState { get; private set; }
+
+ /// <summary>
+ /// Gets the result of the update check.
+ /// </summary>
+ public ApplicationServices.Model.General.UpdateCheckInformation Result { get; private set; }
+
+ /// <summary>
+ /// Gets AsyncWaitHandle.
+ /// </summary>
+ /// <exception cref="NotImplementedException">
+ /// </exception>
+ public WaitHandle AsyncWaitHandle
+ {
+ get { throw new NotImplementedException(); }
+ }
+
+ /// <summary>
+ /// Gets a value indicating whether CompletedSynchronously.
+ /// </summary>
+ /// <exception cref="NotImplementedException">
+ /// </exception>
+ public bool CompletedSynchronously
+ {
+ get { throw new NotImplementedException(); }
+ }
+
+ /// <summary>
+ /// Gets a value indicating whether IsCompleted.
+ /// </summary>
+ /// <exception cref="NotImplementedException">
+ /// </exception>
+ public bool IsCompleted
+ {
+ get { throw new NotImplementedException(); }
+ }
+ }
+}
diff --git a/win/CS/HandBrake.ApplicationServices/Model/Preset.cs b/win/CS/HandBrake.ApplicationServices/Model/Preset.cs new file mode 100644 index 000000000..e20ad2dee --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/Preset.cs @@ -0,0 +1,64 @@ +/* Preset.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model
+{
+ /// <summary>
+ /// A Preset for encoding with.
+ /// </summary>
+ public class Preset
+ {
+ /// <summary>
+ /// Gets or sets the category which the preset resides under
+ /// </summary>
+ public string Category { get; set; }
+
+ /// <summary>
+ /// Gets or sets the preset name
+ /// </summary>
+ public string Name { get; set; }
+
+ /// <summary>
+ /// Gets or sets the preset query
+ /// </summary>
+ public string Query { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether to use picture Settings in presets.
+ /// </summary>
+ public bool CropSettings { get; set; }
+
+ /// <summary>
+ /// Gets or sets the Settings for this encode/preset. Can be used in place of Query property.
+ /// </summary>
+ public EncodeTask EncodeSettings { get; set; }
+
+ /// <summary>
+ /// Gets or sets The version number which associates this preset with a HB build
+ /// </summary>
+ public string Version { get; set; }
+
+ /// <summary>
+ /// Gets or sets the Description for the preset
+ /// </summary>
+ public string Description { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether this is a built in preset
+ /// </summary>
+ public bool IsBuildIn { get; set; }
+
+ /// <summary>
+ /// Override the ToString Method
+ /// </summary>
+ /// <returns>
+ /// The Preset Name
+ /// </returns>
+ public override string ToString()
+ {
+ return this.Name;
+ }
+ }
+}
\ No newline at end of file diff --git a/win/CS/HandBrake.ApplicationServices/Model/QueueTask.cs b/win/CS/HandBrake.ApplicationServices/Model/QueueTask.cs new file mode 100644 index 000000000..83948a1f3 --- /dev/null +++ b/win/CS/HandBrake.ApplicationServices/Model/QueueTask.cs @@ -0,0 +1,84 @@ +/* QueueTask.cs $
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr>.
+ It may be used under the terms of the GNU General Public License. */
+
+namespace HandBrake.ApplicationServices.Model
+{
+ /// <summary>
+ /// The QueueTask.
+ /// </summary>
+ public class QueueTask
+ {
+ /*
+ * TODO
+ * - Update the Query property to generate the query from the EncodeTask object.
+ * - Remove Sourcee, Destination and Title when they are no longer used.
+ */
+
+ /// <summary>
+ /// Initializes a new instance of the <see cref="QueueTask"/> class.
+ /// </summary>
+ public QueueTask()
+ {
+ }
+
+ /// <summary>
+ /// Initializes a new instance of the <see cref="QueueTask"/> class.
+ /// </summary>
+ /// <param name="query">
+ /// The query.
+ /// </param>
+ public QueueTask(string query)
+ {
+ this.Query = query;
+ }
+
+ /// <summary>
+ /// Gets or sets the job ID.
+ /// </summary>
+ public int Id { get; set; }
+
+ /// <summary>
+ /// Gets or sets Title.
+ /// </summary>
+ public int Title { get; set; }
+
+ /// <summary>
+ /// Gets or sets Source.
+ /// </summary>
+ public string Source { get; set; }
+
+ /// <summary>
+ /// Gets or sets Destination.
+ /// </summary>
+ public string Destination { get; set; }
+
+ /// <summary>
+ /// Gets or sets the query string.
+ /// </summary>
+ public string Query { get; set; }
+
+ /// <summary>
+ /// Gets or sets a value indicating whether if this is a user or GUI generated query
+ /// </summary>
+ public bool CustomQuery { get; set; }
+
+ /// <summary>
+ /// Gets or sets the Encode Task.
+ /// </summary>
+ public EncodeTask Task { get; set; }
+
+ /// <summary>
+ /// Gets a value indicating whether or not this instance is empty.
+ /// </summary>
+ public bool IsEmpty
+ {
+ get
+ {
+ return this.Id == 0 && string.IsNullOrEmpty(this.Query) && string.IsNullOrEmpty(this.Task.Source) &&
+ string.IsNullOrEmpty(this.Task.Destination);
+ }
+ }
+ }
+}
\ No newline at end of file |