diff options
author | sr55 <[email protected]> | 2013-11-19 22:30:26 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2013-11-19 22:30:26 +0000 |
commit | 830bb18b173a1c68720eb0df2ed860daea7d4c7e (patch) | |
tree | 780e4ad48d4917555121766f5e1f3eb838970042 /win/CS/HandBrake.ApplicationServices/Utilities | |
parent | f83ab26ab8e1d2ce277f0c12f23b5753bf63d763 (diff) |
WinGui: Removed the need for the user settings service from IEncode and IScan interfaces and various other places. This makes the API much simpler to use.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5897 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/CS/HandBrake.ApplicationServices/Utilities')
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs | 46 |
1 files changed, 11 insertions, 35 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs b/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs index 30c1e9eb7..5552f1941 100644 --- a/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs +++ b/win/CS/HandBrake.ApplicationServices/Utilities/QueryGeneratorUtility.cs @@ -34,28 +34,13 @@ namespace HandBrake.ApplicationServices.Utilities /// <param name="task">
/// The task.
/// </param>
- /// <param name="previewScanCount">
- /// The preview Scan Count.
- /// </param>
- /// <param name="verbosity">
- /// The verbosity.
- /// </param>
- /// <param name="disableLibDvdNav">
- /// The disable Lib Dvd Nav.
- /// </param>
- /// <param name="disableQsvDecode">
- /// The disable Qsv Decode.
- /// </param>
- /// <param name="enableHwd">
- /// The enable Hwd.
- /// </param>
- /// <param name="enableOpenCL">
- /// The enable Open CL.
+ /// <param name="configuration">
+ /// The configuration.
/// </param>
/// <returns>
/// A Cli Query
/// </returns>
- public static string GenerateQuery(EncodeTask task, int previewScanCount, int verbosity, bool disableLibDvdNav, bool disableQsvDecode, bool enableHwd, bool enableOpenCL)
+ public static string GenerateQuery(EncodeTask task, HBConfiguration configuration)
{
if (string.IsNullOrEmpty(task.Source))
{
@@ -63,9 +48,9 @@ namespace HandBrake.ApplicationServices.Utilities }
string query = string.Empty;
- query += SourceQuery(task, null, null, previewScanCount);
+ query += SourceQuery(task, null, null, configuration.PreviewScanCount);
query += DestinationQuery(task);
- query += GenerateTabbedComponentsQuery(task, true, verbosity, disableLibDvdNav, disableQsvDecode, enableHwd, enableOpenCL);
+ query += GenerateTabbedComponentsQuery(task, true, configuration.Verbosity, configuration.IsDvdNavDisabled, configuration.DisableQuickSyncDecoding, configuration.EnableDxva, configuration.ScalingMode == VideoScaler.BicubicCl);
return query;
}
@@ -76,33 +61,24 @@ namespace HandBrake.ApplicationServices.Utilities /// <param name="task">
/// The task.
/// </param>
+ /// <param name="configuration">
+ /// The configuration.
+ /// </param>
/// <param name="duration">
/// The duration.
/// </param>
/// <param name="startAtPreview">
/// The start At Preview.
/// </param>
- /// <param name="previewScanCount">
- /// The preview Scan Count.
- /// </param>
- /// <param name="verbosity">
- /// The verbosity.
- /// </param>
- /// <param name="disableLibDvdNav">
- /// The disable Lib Dvd Nav.
- /// </param>
- /// <param name="disableQsvDecode">
- /// The disable Qsv Decode.
- /// </param>
/// <returns>
/// A Cli query suitable for generating a preview video.
/// </returns>
- public static string GeneratePreviewQuery(EncodeTask task, int duration, string startAtPreview, int previewScanCount, int verbosity, bool disableLibDvdNav, bool disableQsvDecode)
+ public static string GeneratePreviewQuery(EncodeTask task, HBConfiguration configuration, int duration, string startAtPreview)
{
string query = string.Empty;
- query += SourceQuery(task, duration, startAtPreview, previewScanCount);
+ query += SourceQuery(task, duration, startAtPreview, configuration.PreviewScanCount);
query += DestinationQuery(task);
- query += GenerateTabbedComponentsQuery(task, true, verbosity, disableLibDvdNav, disableQsvDecode, false, false);
+ query += GenerateTabbedComponentsQuery(task, true, configuration.Verbosity, configuration.IsDvdNavDisabled, configuration.DisableQuickSyncDecoding, false, false);
return query;
}
|