Skip to content

Commit 133ca40

Browse files
committed
Updated Google APIs and some code changes.
1 parent b636873 commit 133ca40

5 files changed

Lines changed: 73 additions & 72 deletions

File tree

opus_gui/Form1.Designer.vb

Lines changed: 48 additions & 48 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

opus_gui/Form1.vb

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ Public Class Form1
189189
Case "opusenc"
190190
If Not (FileExtension = ".wav" Or FileExtension = ".flac" Or FileExtension = ".opus") Then
191191
If Not ffmpeg_version = String.Empty Then
192-
Data = ffmpeg_preprocess(Data)
192+
Data = ffmpeg_preprocess(Data, Input_File)
193193
Else
194194
Return False
195195
End If
@@ -214,13 +214,15 @@ Public Class Form1
214214
ProgressBar1.BeginInvoke(Sub() ProgressBar1.PerformStep())
215215
Return True
216216
End Function
217-
Private Function ffmpeg_preprocess(Input As Byte()) As Byte()
218-
Dim InputPipe As New NamedPipeServerStream("ffin", PipeDirection.Out, -1, PipeTransmissionMode.Byte, PipeOptions.Asynchronous, 16384, 0)
219-
Dim OutputPipe As New NamedPipeServerStream("ffout.flac", PipeDirection.In, -1, PipeTransmissionMode.Byte, PipeOptions.WriteThrough, 0, 16384)
217+
Private Function ffmpeg_preprocess(Input As Byte(), Filename As String) As Byte()
218+
Dim input_file As String = IO.Path.GetFileName(Filename)
219+
Dim output_file As String = IO.Path.GetFileNameWithoutExtension(Filename) + ".flac"
220+
Dim InputPipe As New NamedPipeServerStream(input_file, PipeDirection.Out, -1, PipeTransmissionMode.Byte, PipeOptions.Asynchronous, 16384, 0)
221+
Dim OutputPipe As New NamedPipeServerStream(output_file, PipeDirection.In, -1, PipeTransmissionMode.Byte, PipeOptions.WriteThrough, 0, 16384)
220222
Dim ffmpegProcessInfo As New ProcessStartInfo
221223
Dim ffmpegProcess As Process
222224
ffmpegProcessInfo.FileName = "ffmpeg.exe"
223-
ffmpegProcessInfo.Arguments = "-i \\.\pipe\ffin -c:a flac -c:v copy \\.\pipe\ffout.flac -y"
225+
ffmpegProcessInfo.Arguments = "-i ""\\.\pipe\" + input_file + """ -c:a flac -c:v copy ""\\.\pipe\" + output_file + """ -y"
224226
ffmpegProcessInfo.CreateNoWindow = True
225227
ffmpegProcessInfo.RedirectStandardInput = True
226228
ffmpegProcessInfo.RedirectStandardOutput = True
@@ -271,7 +273,6 @@ Public Class Form1
271273
End If
272274
End Sub
273275

274-
275276
Private Sub GetOpusencVersion()
276277
Try
277278
Dim opusProcessInfo As New ProcessStartInfo

opus_gui/My Project/AssemblyInfo.vb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
3131
' by using the '*' as shown below:
3232
' <Assembly: AssemblyVersion("1.0.*")>
3333

34-
<Assembly: AssemblyVersion("1.13.0.0")>
35-
<Assembly: AssemblyFileVersion("1.13.0.0")>
34+
<Assembly: AssemblyVersion("1.13.1.0")>
35+
<Assembly: AssemblyFileVersion("1.13.1.0")>

opus_gui/opus_gui.vbproj

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -58,23 +58,23 @@
5858
<NoWarn>41999,42016,42017,42018,42019,42020,42021,42022,42032,42036</NoWarn>
5959
</PropertyGroup>
6060
<ItemGroup>
61-
<Reference Include="Google.Apis, Version=1.40.2.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
62-
<HintPath>..\packages\Google.Apis.1.40.2\lib\net45\Google.Apis.dll</HintPath>
61+
<Reference Include="Google.Apis, Version=1.40.3.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
62+
<HintPath>..\packages\Google.Apis.1.40.3\lib\net45\Google.Apis.dll</HintPath>
6363
</Reference>
64-
<Reference Include="Google.Apis.Auth, Version=1.40.2.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
65-
<HintPath>..\packages\Google.Apis.Auth.1.40.2\lib\net45\Google.Apis.Auth.dll</HintPath>
64+
<Reference Include="Google.Apis.Auth, Version=1.40.3.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
65+
<HintPath>..\packages\Google.Apis.Auth.1.40.3\lib\net45\Google.Apis.Auth.dll</HintPath>
6666
</Reference>
67-
<Reference Include="Google.Apis.Auth.PlatformServices, Version=1.40.2.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
68-
<HintPath>..\packages\Google.Apis.Auth.1.40.2\lib\net45\Google.Apis.Auth.PlatformServices.dll</HintPath>
67+
<Reference Include="Google.Apis.Auth.PlatformServices, Version=1.40.3.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
68+
<HintPath>..\packages\Google.Apis.Auth.1.40.3\lib\net45\Google.Apis.Auth.PlatformServices.dll</HintPath>
6969
</Reference>
70-
<Reference Include="Google.Apis.Core, Version=1.40.2.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
71-
<HintPath>..\packages\Google.Apis.Core.1.40.2\lib\net45\Google.Apis.Core.dll</HintPath>
70+
<Reference Include="Google.Apis.Core, Version=1.40.3.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
71+
<HintPath>..\packages\Google.Apis.Core.1.40.3\lib\net45\Google.Apis.Core.dll</HintPath>
7272
</Reference>
73-
<Reference Include="Google.Apis.Drive.v3, Version=1.40.2.1649, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
74-
<HintPath>..\packages\Google.Apis.Drive.v3.1.40.2.1649\lib\net45\Google.Apis.Drive.v3.dll</HintPath>
73+
<Reference Include="Google.Apis.Drive.v3, Version=1.40.3.1671, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
74+
<HintPath>..\packages\Google.Apis.Drive.v3.1.40.3.1671\lib\net45\Google.Apis.Drive.v3.dll</HintPath>
7575
</Reference>
76-
<Reference Include="Google.Apis.PlatformServices, Version=1.40.2.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
77-
<HintPath>..\packages\Google.Apis.1.40.2\lib\net45\Google.Apis.PlatformServices.dll</HintPath>
76+
<Reference Include="Google.Apis.PlatformServices, Version=1.40.3.0, Culture=neutral, PublicKeyToken=4b01fa6e34db77ab, processorArchitecture=MSIL">
77+
<HintPath>..\packages\Google.Apis.1.40.3\lib\net45\Google.Apis.PlatformServices.dll</HintPath>
7878
</Reference>
7979
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
8080
<HintPath>..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>

opus_gui/packages.config

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="Google.Apis" version="1.40.2" targetFramework="net472" />
4-
<package id="Google.Apis.Auth" version="1.40.2" targetFramework="net472" />
5-
<package id="Google.Apis.Core" version="1.40.2" targetFramework="net472" />
6-
<package id="Google.Apis.Drive.v3" version="1.40.2.1649" targetFramework="net48" />
3+
<package id="Google.Apis" version="1.40.3" targetFramework="net48" />
4+
<package id="Google.Apis.Auth" version="1.40.3" targetFramework="net48" />
5+
<package id="Google.Apis.Core" version="1.40.3" targetFramework="net48" />
6+
<package id="Google.Apis.Drive.v3" version="1.40.3.1671" targetFramework="net48" />
77
<package id="Newtonsoft.Json" version="12.0.2" targetFramework="net472" />
88
</packages>

0 commit comments

Comments
 (0)