public void SetDisplayBackground(bool show) { if (Neshawk != null) { var s = Neshawk.GetSettings(); s.DispBackground = show; Neshawk.PutSettings(s); } }
public bool GetAllowMoreThanEightSprites() { if (Quicknes != null) { return(Quicknes.GetSettings().NumSprites != 8); } if (Neshawk != null) { return(Neshawk.GetSettings().AllowMoreThanEightSprites); } throw new InvalidOperationException(); }
public bool GetDisplaySprites() { if (Quicknes != null) { return(Quicknes.GetSettings().NumSprites > 0); } if (Neshawk != null) { return(Neshawk.GetSettings().DispSprites); } throw new InvalidOperationException(); }
public bool GetDisplayBackground() { if (Quicknes != null) { return(true); } if (Neshawk != null) { return(Neshawk.GetSettings().DispBackground); } throw new InvalidOperationException(); }
public bool GetClipLeftAndRight() { if (Quicknes != null) { return(Quicknes.GetSettings().ClipLeftAndRight); } if (Neshawk != null) { return(Neshawk.GetSettings().ClipLeftAndRight); } throw new InvalidOperationException(); }
public void SetDisplaySprites(bool show) { if (Neshawk != null) { var s = Neshawk.GetSettings(); s.DispSprites = show; Neshawk.PutSettings(s); } else if (Quicknes != null) { var s = Quicknes.GetSettings(); s.NumSprites = show ? 8 : 0; Quicknes.PutSettings(s); } }
public void SetClipLeftAndRight(bool leftandright) { if (Neshawk != null) { var s = Neshawk.GetSettings(); s.ClipLeftAndRight = leftandright; Neshawk.PutSettings(s); } else if (Quicknes != null) { var s = Quicknes.GetSettings(); s.ClipLeftAndRight = leftandright; Quicknes.PutSettings(s); } }
public void SetAllowMoreThanEightSprites(bool allow) { if (Neshawk != null) { var s = Neshawk.GetSettings(); s.AllowMoreThanEightSprites = allow; Neshawk.PutSettings(s); } else if (Quicknes != null) { var s = Quicknes.GetSettings(); s.NumSprites = allow ? 64 : 8; Quicknes.PutSettings(s); } }
public int GetBottomScanline(bool pal = false) { if (Quicknes != null) { return(Quicknes.GetSettings().ClipTopAndBottom ? 231 : 239); } if (Neshawk != null) { return(pal ? Neshawk.GetSettings().PAL_BottomLine : Neshawk.GetSettings().NTSC_BottomLine); } throw new InvalidOperationException(); }
public void SetScanlines(int top, int bottom, bool pal = false) { if (Neshawk != null) { if (top > 127) { top = 127; } else if (top < 0) { top = 0; } if (bottom > 239) { bottom = 239; } else if (bottom < 128) { bottom = 128; } var s = Neshawk.GetSettings(); if (pal) { s.PAL_TopLine = top; s.PAL_BottomLine = bottom; } else { s.NTSC_TopLine = top; s.NTSC_BottomLine = bottom; } Neshawk.PutSettings(s); } }