diff options
author | sr55 <[email protected]> | 2011-07-16 15:09:30 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2011-07-16 15:09:30 +0000 |
commit | 7d0c1740460d7221636b657bc6671d62e1c413b6 (patch) | |
tree | af53caccbcdabfc2e8032fb6ccef87a46b22fc09 /win | |
parent | cdf0fe9271bd5c370e104b9b1c6d6618dca7a543 (diff) |
WinGui: Switch from using the Interop binary lib, to the source version which is now part of the project.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4107 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win')
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs | 64 | ||||
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj | 10 | ||||
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs | 1 | ||||
-rw-r--r-- | win/CS/HandBrake.ApplicationServices/Services/LibScan.cs | 24 | ||||
-rw-r--r-- | win/CS/libraries/HandBrakeInterop.dll | bin | 72192 -> 0 bytes | |||
-rw-r--r-- | win/CS/libraries/HandBrakeInterop.pdb | bin | 83456 -> 0 bytes |
6 files changed, 51 insertions, 48 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs b/win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs index f03d93688..8485480fc 100644 --- a/win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs +++ b/win/CS/HandBrake.ApplicationServices/Functions/InteropModelCreator.cs @@ -10,9 +10,9 @@ namespace HandBrake.ApplicationServices.Functions using HandBrake.ApplicationServices.Model;
using HandBrake.ApplicationServices.Model.Encoding;
- using HandBrake.Interop;
+ using HandBrake.Interop.Model;
+ using HandBrake.Interop.Model.Encoding;
- using Cropping = HandBrake.Interop.Cropping;
using Decomb = HandBrake.ApplicationServices.Model.Encoding.Decomb;
using Deinterlace = HandBrake.ApplicationServices.Model.Encoding.Deinterlace;
using Denoise = HandBrake.ApplicationServices.Model.Encoding.Denoise;
@@ -58,16 +58,16 @@ namespace HandBrake.ApplicationServices.Functions switch (work.Anamorphic)
{
case Model.Encoding.Anamorphic.Custom:
- profile.Anamorphic = Interop.Anamorphic.Custom;
+ profile.Anamorphic = Interop.Model.Encoding.Anamorphic.Custom;
break;
case Model.Encoding.Anamorphic.Strict:
- profile.Anamorphic = Interop.Anamorphic.Strict;
+ profile.Anamorphic = Interop.Model.Encoding.Anamorphic.Strict;
break;
case Model.Encoding.Anamorphic.Loose:
- profile.Anamorphic = Interop.Anamorphic.Loose;
+ profile.Anamorphic = Interop.Model.Encoding.Anamorphic.Loose;
break;
case Model.Encoding.Anamorphic.None:
- profile.Anamorphic = Interop.Anamorphic.None;
+ profile.Anamorphic = Interop.Model.Encoding.Anamorphic.None;
break;
}
@@ -89,7 +89,7 @@ namespace HandBrake.ApplicationServices.Functions profile.AudioEncodings.Add(newTrack);
}
- profile.Cropping = new Cropping
+ profile.Cropping = new HandBrake.Interop.Model.Cropping
{
Top = work.Cropping.Top,
Bottom = work.Cropping.Bottom,
@@ -106,35 +106,35 @@ namespace HandBrake.ApplicationServices.Functions switch (work.Decomb)
{
case Decomb.Default:
- profile.Decomb = Interop.Decomb.Default;
+ profile.Decomb = Interop.Model.Encoding.Decomb.Default;
break;
case Decomb.Custom:
- profile.Decomb = Interop.Decomb.Custom;
+ profile.Decomb = Interop.Model.Encoding.Decomb.Custom;
break;
case Decomb.Off:
- profile.Decomb = Interop.Decomb.Off;
+ profile.Decomb = Interop.Model.Encoding.Decomb.Off;
break;
}
switch (work.Deinterlace)
{
case Deinterlace.Fast:
- profile.Deinterlace = Interop.Deinterlace.Fast;
+ profile.Deinterlace = Interop.Model.Encoding.Deinterlace.Fast;
break;
case Deinterlace.Slow:
- profile.Deinterlace = Interop.Deinterlace.Slow;
+ profile.Deinterlace = Interop.Model.Encoding.Deinterlace.Slow;
break;
case Deinterlace.Slower:
- profile.Deinterlace = Interop.Deinterlace.Slower;
+ profile.Deinterlace = Interop.Model.Encoding.Deinterlace.Slower;
break;
case Deinterlace.Slowest:
- profile.Deinterlace = Interop.Deinterlace.Slower;
+ profile.Deinterlace = Interop.Model.Encoding.Deinterlace.Slower;
break;
case Deinterlace.Custom:
- profile.Deinterlace = Interop.Deinterlace.Custom;
+ profile.Deinterlace = Interop.Model.Encoding.Deinterlace.Custom;
break;
case Deinterlace.Off:
- profile.Deinterlace = Interop.Deinterlace.Off;
+ profile.Deinterlace = Interop.Model.Encoding.Deinterlace.Off;
break;
}
@@ -142,32 +142,32 @@ namespace HandBrake.ApplicationServices.Functions switch (work.Denoise)
{
case Denoise.Off:
- profile.Denoise = Interop.Denoise.Off;
+ profile.Denoise = Interop.Model.Encoding.Denoise.Off;
break;
case Denoise.Custom:
- profile.Denoise = Interop.Denoise.Custom;
+ profile.Denoise = Interop.Model.Encoding.Denoise.Custom;
break;
case Denoise.Strong:
- profile.Denoise = Interop.Denoise.Strong;
+ profile.Denoise = Interop.Model.Encoding.Denoise.Strong;
break;
case Denoise.Medium:
- profile.Denoise = Interop.Denoise.Medium;
+ profile.Denoise = Interop.Model.Encoding.Denoise.Medium;
break;
case Denoise.Weak:
- profile.Denoise = Interop.Denoise.Weak;
+ profile.Denoise = Interop.Model.Encoding.Denoise.Weak;
break;
}
switch (work.Detelecine)
{
case Detelecine.Default:
- profile.Detelecine = Interop.Detelecine.Default;
+ profile.Detelecine = Interop.Model.Encoding.Detelecine.Default;
break;
case Detelecine.Custom:
- profile.Detelecine = Interop.Detelecine.Custom;
+ profile.Detelecine = Interop.Model.Encoding.Detelecine.Custom;
break;
case Detelecine.Off:
- profile.Detelecine = Interop.Detelecine.Off;
+ profile.Detelecine = Interop.Model.Encoding.Detelecine.Off;
break;
}
@@ -189,10 +189,10 @@ namespace HandBrake.ApplicationServices.Functions {
case OutputFormat.Mp4:
case OutputFormat.M4V:
- profile.OutputFormat = Interop.OutputFormat.Mp4;
+ profile.OutputFormat = Interop.Model.Encoding.OutputFormat.Mp4;
break;
case OutputFormat.Mkv:
- profile.OutputFormat = Interop.OutputFormat.Mkv;
+ profile.OutputFormat = Interop.Model.Encoding.OutputFormat.Mkv;
break;
}
profile.PeakFramerate = work.FramerateMode == FramerateMode.PFR;
@@ -202,10 +202,10 @@ namespace HandBrake.ApplicationServices.Functions switch (work.OutputFormat)
{
case OutputFormat.Mp4:
- profile.PreferredExtension = Interop.OutputExtension.Mp4;
+ profile.PreferredExtension = Interop.Model.Encoding.OutputExtension.Mp4;
break;
case OutputFormat.M4V:
- profile.PreferredExtension = Interop.OutputExtension.M4v;
+ profile.PreferredExtension = Interop.Model.Encoding.OutputExtension.M4v;
break;
}
profile.Quality = work.Quality.HasValue ? work.Quality.Value : 0;
@@ -225,16 +225,16 @@ namespace HandBrake.ApplicationServices.Functions switch (work.VideoEncoder)
{
case VideoEncoder.X264:
- profile.VideoEncoder = Interop.VideoEncoder.X264;
+ profile.VideoEncoder = Interop.Model.Encoding.VideoEncoder.X264;
break;
case VideoEncoder.FFMpeg:
- profile.VideoEncoder = Interop.VideoEncoder.FFMpeg;
+ profile.VideoEncoder = Interop.Model.Encoding.VideoEncoder.FFMpeg;
break;
case VideoEncoder.FFMpeg2:
- profile.VideoEncoder = Interop.VideoEncoder.FFMpeg; // TODO Fix This.
+ profile.VideoEncoder = Interop.Model.Encoding.VideoEncoder.FFMpeg; // TODO Fix This.
break;
case VideoEncoder.Theora:
- profile.VideoEncoder = Interop.VideoEncoder.Theora;
+ profile.VideoEncoder = Interop.Model.Encoding.VideoEncoder.Theora;
break;
}
diff --git a/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj b/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj index b88becd39..c84e3d40b 100644 --- a/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj +++ b/win/CS/HandBrake.ApplicationServices/HandBrake.ApplicationServices.csproj @@ -53,9 +53,6 @@ <SpecificVersion>False</SpecificVersion>
<HintPath>..\libraries\Growl.CoreLibrary.dll</HintPath>
</Reference>
- <Reference Include="HandBrakeInterop">
- <HintPath>..\libraries\HandBrakeInterop.dll</HintPath>
- </Reference>
<Reference Include="Microsoft.WindowsAPICodePack, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\libraries\Microsoft.WindowsAPICodePack.dll</HintPath>
@@ -183,7 +180,12 @@ </None>
<None Include="Resources\logo64.png" />
</ItemGroup>
- <ItemGroup />
+ <ItemGroup>
+ <ProjectReference Include="..\HandBrake.Interop\HandBrakeInterop\HandBrakeInterop.csproj">
+ <Project>{F0A61F62-2C3B-4A87-AFF4-0C4256253DA1}</Project>
+ <Name>HandBrakeInterop</Name>
+ </ProjectReference>
+ </ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$(ProgramFiles)\MSBuild\StyleCop\v4.5\StyleCop.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
diff --git a/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs b/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs index d8a951d51..d7af9b224 100644 --- a/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs +++ b/win/CS/HandBrake.ApplicationServices/Services/LibEncode.cs @@ -15,6 +15,7 @@ namespace HandBrake.ApplicationServices.Services using HandBrake.ApplicationServices.Services.Base;
using HandBrake.ApplicationServices.Services.Interfaces;
using HandBrake.Interop;
+ using HandBrake.Interop.Model;
using EncodeCompletedEventArgs = HandBrake.ApplicationServices.EventArgs.EncodeCompletedEventArgs;
using EncodeProgressEventArgs = HandBrake.ApplicationServices.EventArgs.EncodeProgressEventArgs;
diff --git a/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs b/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs index 5022763eb..2ee0c172e 100644 --- a/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs +++ b/win/CS/HandBrake.ApplicationServices/Services/LibScan.cs @@ -270,10 +270,10 @@ namespace HandBrake.ApplicationServices.Services /// <returns>
/// The convert titles.
/// </returns>
- private static List<Title> ConvertTitles(IEnumerable<SourceData.Title> titles)
+ private static List<Title> ConvertTitles(IEnumerable<Interop.SourceData.Title> titles)
{
List<Title> titleList = new List<Title>();
- foreach (SourceData.Title title in titles)
+ foreach (Interop.SourceData.Title title in titles)
{
Title converted = new Title
{
@@ -292,41 +292,41 @@ namespace HandBrake.ApplicationServices.Services Fps = title.Framerate
};
- foreach (SourceData.Chapter chapter in title.Chapters)
+ foreach (Interop.SourceData.Chapter chapter in title.Chapters)
{
converted.Chapters.Add(new Chapter(chapter.ChapterNumber, string.Empty, chapter.Duration));
}
- foreach (SourceData.AudioTrack track in title.AudioTracks)
+ foreach (Interop.SourceData.AudioTrack track in title.AudioTracks)
{
converted.AudioTracks.Add(new AudioTrack(track.TrackNumber, track.Language, track.LanguageCode, track.Description, string.Empty, track.SampleRate, track.Bitrate));
}
- foreach (SourceData.Subtitle track in title.Subtitles)
+ foreach (Interop.SourceData.Subtitle track in title.Subtitles)
{
SubtitleType convertedType = new SubtitleType();
switch (track.SubtitleSource)
{
- case SourceData.SubtitleSource.VobSub:
+ case Interop.SourceData.SubtitleSource.VobSub:
convertedType = SubtitleType.VobSub;
break;
- case SourceData.SubtitleSource.UTF8:
+ case Interop.SourceData.SubtitleSource.UTF8:
convertedType = SubtitleType.UTF8Sub;
break;
- case SourceData.SubtitleSource.TX3G:
+ case Interop.SourceData.SubtitleSource.TX3G:
convertedType = SubtitleType.TX3G;
break;
- case SourceData.SubtitleSource.SSA:
+ case Interop.SourceData.SubtitleSource.SSA:
convertedType = SubtitleType.SSA;
break;
- case SourceData.SubtitleSource.SRT:
+ case Interop.SourceData.SubtitleSource.SRT:
convertedType = SubtitleType.SRT;
break;
- case SourceData.SubtitleSource.CC608:
+ case Interop.SourceData.SubtitleSource.CC608:
convertedType = SubtitleType.CC;
break;
- case SourceData.SubtitleSource.CC708:
+ case Interop.SourceData.SubtitleSource.CC708:
convertedType = SubtitleType.CC;
break;
}
diff --git a/win/CS/libraries/HandBrakeInterop.dll b/win/CS/libraries/HandBrakeInterop.dll Binary files differdeleted file mode 100644 index 7f7a60461..000000000 --- a/win/CS/libraries/HandBrakeInterop.dll +++ /dev/null diff --git a/win/CS/libraries/HandBrakeInterop.pdb b/win/CS/libraries/HandBrakeInterop.pdb Binary files differdeleted file mode 100644 index 80ecd2f24..000000000 --- a/win/CS/libraries/HandBrakeInterop.pdb +++ /dev/null |