mirror of https://github.com/stella-emu/stella.git
"tia" command actually starting to do something useful, still needs a
lot more. git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@582 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
741efd226a
commit
c64d9b5f64
|
@ -13,7 +13,7 @@
|
|||
// See the file "license" for information on usage and redistribution of
|
||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
//
|
||||
// $Id: Debugger.cxx,v 1.40 2005-06-29 03:43:37 urchlay Exp $
|
||||
// $Id: Debugger.cxx,v 1.41 2005-06-29 04:23:41 urchlay Exp $
|
||||
//============================================================================
|
||||
|
||||
#include "bspf.hxx"
|
||||
|
@ -346,6 +346,9 @@ const string Debugger::dumpTIA()
|
|||
result += "\n";
|
||||
|
||||
result += booleanWithLabel("VSYNC", myTIAdebug->vsync());
|
||||
result += "\n";
|
||||
|
||||
result += myTIAdebug->spriteState();
|
||||
|
||||
return result;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
|
||||
#include "TIADebug.hxx"
|
||||
#include "System.hxx"
|
||||
#include "Debugger.hxx"
|
||||
|
||||
TIADebug::TIADebug(TIA *tia) {
|
||||
myTIA = tia;
|
||||
|
@ -25,3 +26,45 @@ void TIADebug::updateTIA() {
|
|||
// not working the way I expected:
|
||||
// myTIA->updateFrame(myTIA->mySystem->cycles() * 3);
|
||||
}
|
||||
|
||||
string TIADebug::spriteState() {
|
||||
string ret;
|
||||
|
||||
// TODO: prettier printing (table?)
|
||||
// TODO: NUSIZ
|
||||
// TODO: missiles, ball, PF
|
||||
// TODO: collisions
|
||||
// TODO: audio
|
||||
|
||||
ret += "P0: data=";
|
||||
ret += Debugger::to_bin_8(myTIA->myGRP0);
|
||||
ret += "/";
|
||||
ret += Debugger::to_hex_8(myTIA->myGRP0);
|
||||
ret += ", ";
|
||||
if(!myTIA->myREFP0) ret += "not ";
|
||||
ret += "reflected, pos=";
|
||||
ret += Debugger::to_hex_8(myTIA->myPOSP0);
|
||||
ret += ", color=";
|
||||
ret += Debugger::to_hex_8(myTIA->myCOLUP0 & 0xff);
|
||||
ret += ", ";
|
||||
if(!myTIA->myVDELP0) ret += "not ";
|
||||
ret += " delayed";
|
||||
ret += "\n";
|
||||
|
||||
ret += "P1: data=";
|
||||
ret += Debugger::to_bin_8(myTIA->myGRP1);
|
||||
ret += "/";
|
||||
ret += Debugger::to_hex_8(myTIA->myGRP1);
|
||||
ret += ", ";
|
||||
if(!myTIA->myREFP1) ret += "not ";
|
||||
ret += "reflected, pos=";
|
||||
ret += Debugger::to_hex_8(myTIA->myPOSP1);
|
||||
ret += ", color=";
|
||||
ret += Debugger::to_hex_8(myTIA->myCOLUP1 & 0xff);
|
||||
ret += ", ";
|
||||
if(!myTIA->myVDELP1) ret += "not ";
|
||||
ret += "delayed";
|
||||
ret += "\n";
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -13,6 +13,7 @@ class TIADebug {
|
|||
int frameCount();
|
||||
bool vsync();
|
||||
void updateTIA();
|
||||
string spriteState();
|
||||
|
||||
private:
|
||||
TIA *myTIA;
|
||||
|
|
Loading…
Reference in New Issue