Permalink
Browse files

-

  • Loading branch information...
stax76
stax76 committed Aug 2, 2017
1 parent 7564222 commit 80d31761216f88fe0c43ad6495df0d173467a786
View
@@ -76,7 +76,7 @@ Public Class VCEEnc
proc.Package = Package.VCEEnc
proc.SkipStrings = {"%]", " frames: "}
proc.File = "cmd.exe"
proc.Arguments = "/S /C call """ + Params.GetCommandLine(True, True) + """"
proc.Arguments = "/S /C """ + Params.GetCommandLine(True, True) + """"
proc.Start()
End Using
@@ -213,10 +213,7 @@ Public Class VCEEnc
Dim ret As String
Dim sourcePath As String
Dim targetPath = p.VideoEncoder.OutputPath.ChangeExt(p.VideoEncoder.OutputExt)
If includePaths AndAlso includeExecutable Then
ret = Package.VCEEnc.Path.Escape
End If
If includePaths AndAlso includeExecutable Then ret = Package.VCEEnc.Path.Escape
Select Case Decoder.ValueText
Case "avs"
@@ -236,7 +233,6 @@ Public Class VCEEnc
End Select
Dim q = From i In Items Where i.GetArgs <> ""
If q.Count > 0 Then ret += " " + q.Select(Function(item) item.GetArgs).Join(" ")
Select Case Mode.Value
@@ -262,7 +258,6 @@ Public Class VCEEnc
End If
If sourcePath = "-" Then ret += " --y4m"
If includePaths Then ret += " -i " + sourcePath.Escape + " -o " + targetPath.Escape
Return ret.Trim
View
@@ -1805,7 +1805,7 @@ Public Class MainForm
If p.SourceFiles.Count = 1 AndAlso
p.Script.Filters(0).Name = "Manual" AndAlso
Not p.NoDialogs AndAlso Not p.BatchMode AndAlso
Not p.SourceFile.Ext = "vpy" Then
Not p.SourceFile.Ext.EqualsAny("avs", "vpy") Then
preferredSourceFilter = ShowSourceFilterSelectionDialog(files(0))
End If
View
@@ -617,24 +617,24 @@ Public Class GUIAudioProfile
proc.Header = "Audio encoding"
If cl.Contains("|") Then
proc.SkipStrings = {", ETA ", "x)", "frame=", "size=", "process: ", "analyze: "}
proc.File = "cmd.exe"
proc.Arguments = "/S /C """ + cl + """"
Else
proc.CommandLine = cl
End If
If cl.Contains("qaac64.exe") Then
proc.Package = Package.qaac
proc.SkipStrings = {", ETA ", "x)"}
ElseIf cl.Contains("eac3to.exe") Then
proc.Package = Package.eac3to
proc.SkipStrings = {"process: ", "analyze: "}
proc.TrimChars = {"-"c, " "c}
proc.RemoveChars = {VB6.ChrW(8)} 'backspace
proc.CommandLine = cl
ElseIf cl.Contains("ffmpeg.exe") Then
proc.Package = Package.ffmpeg
proc.SkipStrings = {"frame=", "size="}
proc.Encoding = Encoding.UTF8
proc.CommandLine = cl
ElseIf cl.Contains("qaac64.exe") Then
proc.Package = Package.qaac
proc.SkipString = ", ETA "
proc.CommandLine = cl
End If
proc.Start()
View
@@ -795,26 +795,28 @@ Public Class mkvDemuxer
proj.Log.WriteLine(MediaInfo.GetSummary(outPath) + BR)
If outPath.Ext = "aac" Then
Dim m4aPath As String
Using proc As New Proc
proc.Project = proj
proc.Header = "Mux AAC to M4A"
proc.SkipString = "|"
proc.Package = Package.MP4Box
Dim sbr = If(outPath.Contains("SBR"), ":sbr", "")
Dim m4aPath = outPath.ChangeExt("m4a")
m4aPath = outPath.ChangeExt("m4a")
proc.Arguments = "-add """ + outPath + sbr + ":name= "" -new " + m4aPath.Escape
proc.Process.StartInfo.EnvironmentVariables("TEMP") = proj.TempDir
proc.Process.StartInfo.EnvironmentVariables("TMP") = proj.TempDir
proc.Start()
If File.Exists(m4aPath) Then
If Not ap Is Nothing Then ap.File = m4aPath
FileHelp.Delete(outPath)
proj.Log.WriteLine(BR + MediaInfo.GetSummary(m4aPath))
Else
Throw New ErrorAbortException("Error mux AAC to M4A", outPath)
End If
End Using
If File.Exists(m4aPath) Then
If Not ap Is Nothing Then ap.File = m4aPath
FileHelp.Delete(outPath)
proj.Log.WriteLine(BR + MediaInfo.GetSummary(m4aPath))
Else
Throw New ErrorAbortException("Error mux AAC to M4A", outPath)
End If
End If
Else
proj.Log.Write("Error", "no output found")
View
@@ -208,11 +208,11 @@ Public Class GlobalCommands
Try
proc.Start()
For Each i In proc.Log.ToString.SplitLinesNoEmpty
If Not g.MainForm.CommandManager.ProcessCommandLineArgument(i) Then
Log.WriteLine("Failed to interpret output:" + BR2 + i)
End If
Next
If interpretOutput Then
For Each i In proc.Log.ToString.SplitLinesNoEmpty
If Not g.MainForm.CommandManager.ProcessCommandLineArgument(i) Then Log.WriteLine("Failed to interpret output:" + BR2 + i)
Next
End If
Catch ex As Exception
g.ShowException(ex)
Log.WriteLine(ex.Message)
View
@@ -65,11 +65,13 @@ Public Class LogBuilder
Return "-=".Multiply(30) + "-" + BR + value.PadLeft(30 + value.Length \ 2) + BR + "-=".Multiply(30) + "-" + BR2
End Function
Shared EnvironmentString As String 'cached due to bug report
Sub WriteEnvironment()
If ToString.Contains("System Environment" + BR + "-=") Then Exit Sub
WriteHeader("System Environment")
Dim temp =
If EnvironmentString = "" Then EnvironmentString =
"StaxRip:" + Application.ProductVersion + BR +
"Windows:" + Registry.LocalMachine.GetString("SOFTWARE\Microsoft\Windows NT\CurrentVersion", "ProductName") + " " + Registry.LocalMachine.GetString("SOFTWARE\Microsoft\Windows NT\CurrentVersion", "ReleaseId") + BR +
"Language:" + CultureInfo.CurrentCulture.EnglishName + BR +
@@ -78,7 +80,7 @@ Public Class LogBuilder
"Resolution:" & Screen.PrimaryScreen.Bounds.Width & " x " & Screen.PrimaryScreen.Bounds.Height & BR +
"DPI:" & g.MainForm.DeviceDpi
WriteLine(temp.FormatColumn(":"))
WriteLine(EnvironmentString.FormatColumn(":"))
End Sub
Sub WriteStats()
@@ -7,4 +7,4 @@ Imports System.Runtime.InteropServices
<Assembly: AssemblyCopyright("stax76")>
<Assembly: ComVisible(False)>
<Assembly: Guid("54d5dc0f-6ba7-42f0-a82f-9c71d561cb8b")>
<Assembly: AssemblyVersion("1.6.0.1")>
<Assembly: AssemblyVersion("1.6.0.2")>
View
@@ -10,6 +10,14 @@ https://drive.google.com/open?id=0B-gPKiJYuKuITld4dzhuTC1WWWM
https://onedrive.live.com/redir?resid=604D4754F64B0ABC!4140&authkey=!ANUm9V3vTPmEFNI&ithint=folder%2c7z
#### 1.6.0.2 unstable test build
- fix: incorrect command line generated for VCEEnc
- fix: opening avs as source staxrip shouldn't ask which source filter to use
- fix: executing the command to run a command line showed an error: Failed to interpret output
- change: environment values of the log file header are cached
#### 1.6.0.1 unstable test build
- new: menus and shortcuts added to the job dialogs for improved management of large jobs lists
View
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.PowerShell.5.ReferenceAssemblies" version="1.0.0" targetFramework="net461" />
<package id="Microsoft.PowerShell.5.ReferenceAssemblies" version="1.0.0" targetFramework="net47" />
</packages>

0 comments on commit 80d3176

Please sign in to comment.