@@ -95,6 +95,7 @@ static UINT32 masterVol = 0x10000; // fixed point 16.16
95
95
static UINT8 showTags = 1 ;
96
96
static bool showFileInfo = false ;
97
97
static UINT8 logLevel = DEVLOG_INFO;
98
+ static UINT8 pbTimeMode = PLAYTIME_LOOP_INCL | PLAYTIME_TIME_FILE;
98
99
99
100
static PlayerA mainPlr;
100
101
@@ -364,7 +365,7 @@ int main(int argc, char* argv[])
364
365
pState = " Playing" ;
365
366
if (vgmPcmStrms == NULL || vgmPcmStrms->empty ())
366
367
{
367
- printf (" %s %.2f / %.2f ... \r " , pState, mainPlr.GetCurTime (1 ), mainPlr.GetTotalTime (1 ));
368
+ printf (" %s %.2f / %.2f ... \r " , pState, mainPlr.GetCurTime (pbTimeMode ), mainPlr.GetTotalTime (pbTimeMode ));
368
369
}
369
370
else
370
371
{
@@ -377,7 +378,7 @@ int main(int argc, char* argv[])
377
378
if (pbMode.length () == 1 )
378
379
pbMode = " " ;
379
380
printf (" %s %.2f / %.2f [%02X / %02X at %4.1f KHz%s] ... \r " ,
380
- pState, mainPlr.GetCurTime (1 ), mainPlr.GetTotalTime (1 ),
381
+ pState, mainPlr.GetCurTime (pbTimeMode ), mainPlr.GetTotalTime (pbTimeMode ),
381
382
1 + strmDev->lastItem , strmDev->maxItems , strmDev->freq / 1000.0 ,
382
383
pbMode.c_str ());
383
384
}
@@ -509,6 +510,7 @@ Sound Chip ID:
509
510
T param - show tags (0/D/OFF - off, 1/E/ON - on)
510
511
FI param - show file information (see above)
511
512
LL param - set log level (0..5 = off/error/warn/info/debug/trace, see emu/EmuStructs.h)
513
+ TD param - set time display mode (bit mask: 0/1 = exclude/include loops, 0/2 = file/playback time, 4 = with fade time)
512
514
Q - quit
513
515
P - player configuration
514
516
SPD param - set playback speed (1.0 = 100%)
@@ -913,7 +915,7 @@ static void DoChipControlMode(PlayerBase* player)
913
915
char * tokenStr;
914
916
915
917
// Tags / FileInfo
916
- printf (" Command [T/FI/LL data]: " );
918
+ printf (" Command [T/FI/LL/TD data]: " );
917
919
fgets (line, 0x80 , stdin);
918
920
StripNewline (line);
919
921
@@ -951,6 +953,12 @@ static void DoChipControlMode(PlayerBase* player)
951
953
if (endPtr > tokenStr)
952
954
logLevel = newLevel;
953
955
}
956
+ else if (! strcmp (line, " TD" ))
957
+ {
958
+ UINT8 newTimeMode = (UINT8)strtoul (tokenStr, &endPtr, 0 );
959
+ if (endPtr > tokenStr)
960
+ pbTimeMode = newTimeMode;
961
+ }
954
962
else if (! strcmp (line, " Q" ))
955
963
mode = -1 ;
956
964
else
0 commit comments