summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs
diff options
context:
space:
mode:
Diffstat (limited to 'win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs')
-rw-r--r--win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeCompletedEventArgs.cs35
-rw-r--r--win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeProgressEventArgs.cs120
-rw-r--r--win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/MessageLoggedEventArgs.cs35
-rw-r--r--win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/ScanProgressEventArgs.cs71
4 files changed, 261 insertions, 0 deletions
diff --git a/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeCompletedEventArgs.cs b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeCompletedEventArgs.cs
new file mode 100644
index 000000000..158d2eb84
--- /dev/null
+++ b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeCompletedEventArgs.cs
@@ -0,0 +1,35 @@
+// --------------------------------------------------------------------------------------------------------------------
+// <copyright file="EncodeCompletedEventArgs.cs" company="HandBrake Project (https://handbrake.fr)">
+// This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.
+// </copyright>
+// <summary>
+// Defines the EncodeCompletedEventArgs type.
+// </summary>
+// --------------------------------------------------------------------------------------------------------------------
+
+namespace HandBrake.Interop.Interop.Interfaces.EventArgs
+{
+ using System;
+
+ /// <summary>
+ /// Encode Completed Event Args
+ /// </summary>
+ public class EncodeCompletedEventArgs : EventArgs
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="EncodeCompletedEventArgs"/> class.
+ /// </summary>
+ /// <param name="error">
+ /// The error.
+ /// </param>
+ public EncodeCompletedEventArgs(int error)
+ {
+ this.Error = error;
+ }
+
+ /// <summary>
+ /// Gets a value indicating whether an error occurred during the encode.
+ /// </summary>
+ public int Error { get; private set; }
+ }
+}
diff --git a/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeProgressEventArgs.cs b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeProgressEventArgs.cs
new file mode 100644
index 000000000..54e9d6f5d
--- /dev/null
+++ b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/EncodeProgressEventArgs.cs
@@ -0,0 +1,120 @@
+// --------------------------------------------------------------------------------------------------------------------
+// <copyright file="EncodeProgressEventArgs.cs" company="HandBrake Project (https://handbrake.fr)">
+// This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.
+// </copyright>
+// <summary>
+// Defines the EncodeProgressEventArgs type.
+// </summary>
+// --------------------------------------------------------------------------------------------------------------------
+
+namespace HandBrake.Interop.Interop.Interfaces.EventArgs
+{
+ using System;
+
+ /// <summary>s
+ /// Encode Progress Event Args
+ /// </summary>
+ public class EncodeProgressEventArgs : EventArgs
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="EncodeProgressEventArgs"/> class.
+ /// </summary>
+ /// <param name="fractionComplete">
+ /// The fraction complete.
+ /// </param>
+ /// <param name="currentFrameRate">
+ /// The current frame rate.
+ /// </param>
+ /// <param name="averageFrameRate">
+ /// The average frame rate.
+ /// </param>
+ /// <param name="estimatedTimeLeft">
+ /// The estimated time left.
+ /// </param>
+ /// <param name="passId">
+ /// The pass id.
+ /// </param>
+ /// <param name="pass">
+ /// The pass.
+ /// </param>
+ /// <param name="passCount">
+ /// The pass count.
+ /// </param>
+ /// <param name="stateCode">
+ /// The code for the state the encode process is in.
+ /// </param>
+ public EncodeProgressEventArgs(double fractionComplete, double currentFrameRate, double averageFrameRate, TimeSpan estimatedTimeLeft, int passId, int pass, int passCount, string stateCode)
+ {
+ this.FractionComplete = fractionComplete;
+ this.CurrentFrameRate = currentFrameRate;
+ this.AverageFrameRate = averageFrameRate;
+ this.EstimatedTimeLeft = estimatedTimeLeft;
+ this.PassId = passId;
+ this.Pass = pass;
+ this.PassCount = passCount;
+ this.StateCode = stateCode;
+ }
+
+ /// <summary>
+ /// Gets the % Complete.
+ /// </summary>
+ public double FractionComplete { get; private set; }
+
+ /// <summary>
+ /// Gets the Current FrameRate.
+ /// </summary>
+ public double CurrentFrameRate { get; private set; }
+
+ /// <summary>
+ /// Gets the Average FrameRate.
+ /// </summary>
+ public double AverageFrameRate { get; private set; }
+
+ /// <summary>
+ /// Gets the Estimated Time Left.
+ /// </summary>
+ public TimeSpan EstimatedTimeLeft { get; private set; }
+
+ /// <summary>
+ /// Gets the pass ID.
+ /// </summary>
+ /// <remarks>
+ /// -1: Subtitle scan
+ /// 0: Encode
+ /// 1: Encode first pass
+ /// 2: Encode second pass
+ /// </remarks>
+ public int PassId { get; private set; }
+
+ /// <summary>
+ /// Gets the current encoding pass. (1-based)
+ /// </summary>
+ public int Pass { get; private set; }
+
+ /// <summary>
+ /// Gets the pass count.
+ /// </summary>
+ public int PassCount { get; private set; }
+
+ /// <summary>
+ /// Gets the state code of the encode process.
+ /// </summary>
+ public string StateCode { get; }
+
+ /// <summary>
+ /// Gets a value indicating that we are doing a subtitle scan pass.
+ /// </summary>
+ public bool IsSubtitleScan
+ {
+ get
+ {
+ if (this.PassId == -1)
+ {
+ return true;
+ }
+
+ return false;
+ }
+ }
+ }
+}
diff --git a/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/MessageLoggedEventArgs.cs b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/MessageLoggedEventArgs.cs
new file mode 100644
index 000000000..7fb6b314e
--- /dev/null
+++ b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/MessageLoggedEventArgs.cs
@@ -0,0 +1,35 @@
+// --------------------------------------------------------------------------------------------------------------------
+// <copyright file="MessageLoggedEventArgs.cs" company="HandBrake Project (https://handbrake.fr)">
+// This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.
+// </copyright>
+// <summary>
+// Defines the MessageLoggedEventArgs type.
+// </summary>
+// --------------------------------------------------------------------------------------------------------------------
+
+namespace HandBrake.Interop.Interop.Interfaces.EventArgs
+{
+ using System;
+
+ /// <summary>
+ /// The Message Logged Event Args
+ /// </summary>
+ public class MessageLoggedEventArgs : EventArgs
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="MessageLoggedEventArgs"/> class.
+ /// </summary>
+ /// <param name="message">
+ /// The message.
+ /// </param>
+ public MessageLoggedEventArgs(string message)
+ {
+ this.Message = message;
+ }
+
+ /// <summary>
+ /// Gets the Message.
+ /// </summary>
+ public string Message { get; private set; }
+ }
+}
diff --git a/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/ScanProgressEventArgs.cs b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/ScanProgressEventArgs.cs
new file mode 100644
index 000000000..c16f0fd0a
--- /dev/null
+++ b/win/CS/HandBrake.Interop/Interop/Interfaces/EventArgs/ScanProgressEventArgs.cs
@@ -0,0 +1,71 @@
+// --------------------------------------------------------------------------------------------------------------------
+// <copyright file="ScanProgressEventArgs.cs" company="HandBrake Project (https://handbrake.fr)">
+// This file is part of the HandBrake source code - It may be used under the terms of the GNU General Public License.
+// </copyright>
+// <summary>
+// Defines the ScanProgressEventArgs type.
+// </summary>
+// --------------------------------------------------------------------------------------------------------------------
+
+namespace HandBrake.Interop.Interop.Interfaces.EventArgs
+{
+ using System;
+
+ /// <summary>
+ /// The Scan Progress Event Args
+ /// </summary>
+ public class ScanProgressEventArgs : EventArgs
+ {
+ /// <summary>
+ /// Initializes a new instance of the <see cref="ScanProgressEventArgs"/> class.
+ /// </summary>
+ /// <param name="progress">
+ /// The progress.
+ /// </param>
+ /// <param name="currentPreview">
+ /// The current preview.
+ /// </param>
+ /// <param name="previews">
+ /// The previews.
+ /// </param>
+ /// <param name="currentTitle">
+ /// The current title.
+ /// </param>
+ /// <param name="titles">
+ /// The titles.
+ /// </param>
+ public ScanProgressEventArgs(double progress, int currentPreview, int previews, int currentTitle, int titles)
+ {
+ this.Progress = progress;
+ this.CurrentPreview = currentPreview;
+ this.Previews = previews;
+ this.CurrentTitle = currentTitle;
+ this.Titles = titles;
+ }
+
+ /// <summary>
+ /// Gets the total progress fraction for the scan.
+ /// </summary>
+ public double Progress { get; private set; }
+
+ /// <summary>
+ /// Gets the current preview being processed on the scan.
+ /// </summary>
+ public int CurrentPreview { get; private set; }
+
+ /// <summary>
+ /// Gets the total number of previews to process.
+ /// </summary>
+ public int Previews { get; private set; }
+
+ /// <summary>
+ /// Gets the current title being processed on the scan.
+ /// </summary>
+ public int CurrentTitle { get; private set; }
+
+ /// <summary>
+ /// Gets the total number of titles to process.
+ /// </summary>
+ public int Titles { get; private set; }
+ }
+}