2013-04-24 22:09:11 +00:00
using System ;
2013-11-10 18:15:32 +00:00
using System.Collections.Generic ;
2013-11-10 21:20:55 +00:00
using System.Linq ;
2013-04-24 22:09:11 +00:00
using System.Text ;
2013-11-04 01:39:19 +00:00
namespace BizHawk.Emulation.Common
2011-06-11 22:15:08 +00:00
{
2012-12-10 00:43:43 +00:00
public class CoreComm
2011-06-11 22:15:08 +00:00
{
2014-12-05 01:56:45 +00:00
public CoreComm ( Action < string > ShowMessage , Action < string > NotifyMessage )
{
this . ShowMessage = ShowMessage ;
this . Notify = NotifyMessage ;
}
2013-04-24 22:09:11 +00:00
2014-12-05 01:56:45 +00:00
public ICoreFileProvider CoreFileProvider ;
2011-06-11 22:15:08 +00:00
2012-07-11 21:37:35 +00:00
public double VsyncRate
{
get
{
return VsyncNum / ( double ) VsyncDen ;
}
}
public int VsyncNum = 60 ;
public int VsyncDen = 1 ;
2012-11-04 23:29:06 +00:00
//a core should set these if you wish to provide rom status information yourself. otherwise it will be calculated by the frontend in a way you may not like, using RomGame-related concepts.
2011-07-10 21:00:28 +00:00
public string RomStatusAnnotation ;
public string RomStatusDetails ;
2012-09-16 19:38:08 +00:00
2012-09-20 00:22:24 +00:00
public int ScreenLogicalOffsetX , ScreenLogicalOffsetY ;
2012-09-30 02:07:14 +00:00
2012-11-26 02:25:23 +00:00
// size hint to a/v out resizer. this probably belongs in VideoProvider? but it's somewhat different than VirtualWidth...
public int NominalWidth = 640 ;
public int NominalHeight = 480 ;
2014-08-23 01:18:59 +00:00
public bool LinkConnected = false ;
public bool UsesLinkCable = false ;
2015-11-06 14:31:50 +00:00
//I know we want to get rid of CoreComm, but while it's still here, I'll use it for this
public string LaunchLibretroCore ;
2013-12-10 17:58:12 +00:00
/// <summary>
/// show a message. reasonably annoying (dialog box), shouldn't be used most of the time
/// </summary>
public Action < string > ShowMessage { get ; private set ; }
2014-03-18 03:03:53 +00:00
/// <summary>
/// show a message. less annoying (OSD message). Should be used for ignorable helpful messages
/// </summary>
public Action < string > Notify { get ; private set ; }
2014-06-08 23:30:34 +00:00
public Func < object > RequestGLContext ;
public Action < object > ActivateGLContext ;
public Action DeactivateGLContext ; //this shouldnt be necessary.. frontend should be changing context before it does anything.. but for now..
2011-06-11 22:15:08 +00:00
}
2012-03-11 06:50:46 +00:00
}