change screenshot naming from screen##### to YYYY-MM-DD_HHMMSS, thus fixing the bug where multiple screen00000 shots were being made.
This commit is contained in:
@@ -14,6 +14,12 @@ sm-ssc v1.0 Release Candidate 2 | 201007xx
|
|||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
(work in progress, it's not out yet [hence the "xx" above].)
|
(work in progress, it's not out yet [hence the "xx" above].)
|
||||||
|
|
||||||
|
20100718
|
||||||
|
--------
|
||||||
|
* Change screenshot naming format from "screen#####" to "YYYY-MM-DD_HHMMSS".
|
||||||
|
This should solve an issue where screen00000 was getting written multiple
|
||||||
|
times for unknown reasons.
|
||||||
|
|
||||||
20100717
|
20100717
|
||||||
--------
|
--------
|
||||||
sm4svn:
|
sm4svn:
|
||||||
|
|||||||
+9
-10
@@ -1229,16 +1229,15 @@ int main(int argc, char* argv[])
|
|||||||
|
|
||||||
RString StepMania::SaveScreenshot( RString sDir, bool bSaveCompressed, bool bMakeSignature, int iIndex )
|
RString StepMania::SaveScreenshot( RString sDir, bool bSaveCompressed, bool bMakeSignature, int iIndex )
|
||||||
{
|
{
|
||||||
/* Files should be of the form "screen#####.xxx". Ignore the extension; find
|
/* As of sm-ssc v1.0 rc2, screenshots are no longer named by an arbitrary
|
||||||
* the last file of this form, and use the next number. This way, we don't
|
* index. This was causing naming issues for some unknown reason, so we have
|
||||||
* write the same screenshot number for different formats (screen00011.bmp,
|
* changed the screenshot names to a non-blocking format: date and time.
|
||||||
* screen00011.jpg), and we always increase from the end, so if screen00003.jpg
|
* As before, we ignore the extension. -aj */
|
||||||
* is deleted, we won't fill in the hole (which makes screenshots hard to find). */
|
RString sFileNameNoExtension = DateTime::GetNowDateTime().GetString();
|
||||||
RString sFileNameNoExtension;
|
// replace space with underscore.
|
||||||
if( iIndex == -1 )
|
sFileNameNoExtension.Replace(" ","_");
|
||||||
sFileNameNoExtension = Profile::MakeUniqueFileNameNoExtension( sDir, "screen" );
|
// colons are illegal in filenames.
|
||||||
else
|
sFileNameNoExtension.Replace(":","");
|
||||||
sFileNameNoExtension = Profile::MakeFileNameNoExtension( "screen", iIndex );
|
|
||||||
|
|
||||||
// Save the screenshot. If writing lossy to a memcard, use
|
// Save the screenshot. If writing lossy to a memcard, use
|
||||||
// SAVE_LOSSY_LOW_QUAL, so we don't eat up lots of space.
|
// SAVE_LOSSY_LOW_QUAL, so we don't eat up lots of space.
|
||||||
|
|||||||
Reference in New Issue
Block a user