SubNESHawk: Play Movie dialog now calculates time correctly
This commit is contained in:
parent
0444b35899
commit
982dc479e7
|
@ -110,7 +110,7 @@ namespace BizHawk.Client.Common
|
|||
|
||||
private double GetSeconds(IMovie movie)
|
||||
{
|
||||
double frames = movie.InputLogLength;
|
||||
double frames = movie.TimeLength;
|
||||
|
||||
if (frames < 1)
|
||||
{
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
using System.Collections.Generic;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
using BizHawk.Emulation.Common;
|
||||
|
||||
|
@ -69,12 +70,27 @@ namespace BizHawk.Client.Common
|
|||
{
|
||||
return double.PositiveInfinity;
|
||||
}
|
||||
|
||||
|
||||
return Log.Count;
|
||||
}
|
||||
}
|
||||
|
||||
public int InputLogLength => Log.Count;
|
||||
public int InputLogLength
|
||||
{
|
||||
get
|
||||
{
|
||||
return Log.Count;
|
||||
}
|
||||
}
|
||||
|
||||
public int TimeLength
|
||||
{
|
||||
get
|
||||
{
|
||||
if (Header.ContainsKey("VBlankCount")) { return Convert.ToInt32(Header["VBlankCount"]); }
|
||||
return Log.Count;
|
||||
}
|
||||
}
|
||||
|
||||
#region Log Editing
|
||||
|
||||
|
|
|
@ -45,6 +45,8 @@ namespace BizHawk.Client.Common
|
|||
|
||||
public int InputLogLength => _log.Count;
|
||||
|
||||
public int TimeLength => _log.Count;
|
||||
|
||||
public double FrameCount
|
||||
{
|
||||
get
|
||||
|
|
|
@ -34,6 +34,11 @@ namespace BizHawk.Client.Common
|
|||
/// </summary>
|
||||
int InputLogLength { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the actual length of time a movie lasts for. For subframe cores, this will be different then the above two options
|
||||
/// </summary>
|
||||
int TimeLength { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the file extension for the current <see cref="IMovie"/> implementation
|
||||
/// </summary>
|
||||
|
|
Loading…
Reference in New Issue