From: Mark Cannon Date: Mon, 18 Feb 2008 03:11:08 +0000 (+0000) Subject: We don't need - or want, really - the .deps directory, please avoid uploading it :P X-Git-Url: http://cameron1729.xyz/?a=commitdiff_plain;h=687e2a8d5a9b8cfa681584bedd0e79fc8c026830;p=openitg.git We don't need - or want, really - the .deps directory, please avoid uploading it :P git-svn-id: https://openitg.svn.sourceforge.net/svnroot/openitg@28 83fadc84-e282-4d84-a09a-c4228d6ae7e5 --- diff --git a/src/LuaManager.cpp b/src/LuaManager.cpp index cfc63b39..efcab4fc 100644 --- a/src/LuaManager.cpp +++ b/src/LuaManager.cpp @@ -23,12 +23,15 @@ #include "XmlFile.h" // I need this, for checking the Revision [ScreenArcadeDiagnostics] +// If you need this, uncomment it. - Vyhd +#if 0 #include #include #include // Hayy, now I can get an IP! [ScreenArcadeDiagnostics] #include #include +#endif LuaManager *LUA = NULL; static LuaFunctionList *g_LuaFunctions = NULL; @@ -455,8 +458,10 @@ static size_t FindEndOfHeaders( const CString &buf ) else return string::npos; } - +// If you need this, we can uncomment it. I don't think it's being used, though. +// - Vyhd // Progress Indicator for loading custom songs. -- Matt1360 +/* void UpdateLoadingProgress( float fProgress ) { CString sText = ssprintf( "Please wait ... Copying Patch: \n%u%%\n\n\n" @@ -467,6 +472,7 @@ void UpdateLoadingProgress( float fProgress ) SCREENMAN->OverlayMessage( sText ); SCREENMAN->Draw(); } +*/ #if 0 // Get Newest Revision @@ -888,6 +894,7 @@ LuaFunction( GetNumMachineScores, GetNumMachineScores() ); // Call the machine s /* * (c) 2004 Glenn Maynard + * (c) 2008 BoXoRRoXoRs * All rights reserved. * * Permission is hereby granted, free of charge, to any person obtaining a diff --git a/src/Makefile.am b/src/Makefile.am index 1585297c..a247fc06 100755 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -386,6 +386,7 @@ main_LDADD = \ stepmania_SOURCES = $(main_SOURCES) stepmania_LDADD = $(main_LDADD) +# $(srcdir)/ffmpeg/lib/libavcodec.a $(srcdir)/ffmpeg/lib/libavformat.a if HAVE_GTK bin_PROGRAMS += GtkModule.so diff --git a/src/RageFileDriverCrypt.cpp b/src/RageFileDriverCrypt.cpp index 6076738d..edcdf5a5 100755 --- a/src/RageFileDriverCrypt.cpp +++ b/src/RageFileDriverCrypt.cpp @@ -7,6 +7,7 @@ #include #include +// XXX: is this stuff portable? I have no idea. - Vyhd #include #include @@ -20,6 +21,9 @@ #include #endif +/* courtesy of random.org. This is for future testing. -- Vyhd */ +#define DEFAULT_AES_KEY "65487573252940086457044055343188392138734144585" + //#define tell( handle ) lseek( handle, 0L, SEEK_CUR ) //#define _tell tell @@ -55,9 +59,9 @@ RageFileBasic *RageFileDriverCrypt::Open( const CString &path, int mode, int &er FDB->ResolvePath( sPath ); crypt_file *newFile = ITG2CryptInterface::crypt_open(sPath, secret); - if (newFile == NULL) { + + if (newFile == NULL) return NULL; - } return new RageFileObjCrypt(newFile); } diff --git a/src/RageFileManager.cpp b/src/RageFileManager.cpp index c5922065..6f309df4 100755 --- a/src/RageFileManager.cpp +++ b/src/RageFileManager.cpp @@ -277,11 +277,12 @@ void RageFileManager::MountInitialFilesystems() /* Search for a directory with "Songs" in it. Be careful: the CWD is likely to * be ~, and it's possible that some users will have a ~/Songs/ directory that * has nothing to do with us, so check the initial directory last. */ - - - RageFileManager::Mount( "dir" , "/stats" , "/Data" ); - RageFileManager::Mount( "dir" , "/dxldata" , "/Packages" ); - + + /* Not yet, matt. We want this to stay self-contained * + * until the beta stage. :) - Vyhd */ + //RageFileManager::Mount( "dir" , "/stats/" , "/Data" ); + //RageFileManager::Mount( "dir" , "/dxldata" , "/Packages" ); + CString Root = ""; struct stat st; if( Root == "" && !stat( DirOfExecutable + "/Songs", &st ) && st.st_mode&S_IFDIR ) @@ -294,8 +295,10 @@ void RageFileManager::MountInitialFilesystems() // I'm loading off zips and additional folders...I don't want no crashes... // -- Matt1360 - // not standard for ITG file structure, keep commented out - //RageFileManager::Mount( "dir", Root, "/" ); + // not standard for ITG file structure, keep commented out + // Bad idea - this breaks all file loading on Linux. -- Vyhd + RageFileManager::Mount( "dir", Root, "/" ); + #elif defined(_WINDOWS) /* All Windows data goes in the directory one level above the executable. */ CHECKPOINT_M( ssprintf( "DOE \"%s\"", DirOfExecutable.c_str()) ); diff --git a/src/RageUtil.cpp b/src/RageUtil.cpp index 6f9cc612..fc1ae7b8 100755 --- a/src/RageUtil.cpp +++ b/src/RageUtil.cpp @@ -1605,53 +1605,11 @@ bool FileCopy( RageFileBasic &in, RageFileBasic &out, CString &sError, bool *bRe return true; } -bool CopyWithProgress( RageFileBasic &in, RageFileBasic &out, RageFileBasic &read, - CString &sError, void(*OnUpdate)(float), bool *bReadError ) -{ - int iTarget = in.GetFileSize(); - float fPercent; - while(1) - { - CString data; - if( in.Read(data, 1024*32) == -1 ) - { - sError = ssprintf( "read error: %s", in.GetError().c_str() ); - if( bReadError != NULL ) - *bReadError = true; - return false; - } - if( data.empty() ) - break; - int i = out.Write(data); - if( i == -1 ) - { - sError = ssprintf( "write error: %s", out.GetError().c_str() ); - if( bReadError != NULL ) - *bReadError = false; - return false; - } - - // now, update our loop - - - fPercent = (float)(read.GetFileSize() / iTarget); - LOG->Trace( "Copying.... %f done. %u of %u.", fPercent, read.GetFileSize(), iTarget ); - OnUpdate( fPercent ); - } - - if( out.Flush() == -1 ) - { - sError = ssprintf( "write error: %s", out.GetError().c_str() ); - if( bReadError != NULL ) - *bReadError = false; - return false; - } - - return true; -} +/* Removed obsolete/unused function -- Vyhd */ /* * Copyright (c) 2001-2004 Chris Danford, Glenn Maynard + * Copyright (c) 2008 BoXoRRoXoRs * All rights reserved. * * Permission is hereby granted, free of charge, to any person obtaining a diff --git a/src/RageUtil.h b/src/RageUtil.h index 991c506d..3bcc8be7 100755 --- a/src/RageUtil.h +++ b/src/RageUtil.h @@ -428,13 +428,15 @@ void FileWrite(RageFileBasic& f, float fWrite); bool FileCopy( CString sSrcFile, CString sDstFile ); bool FileCopy( RageFileBasic &in, RageFileBasic &out, CString &sError, bool *bReadError = NULL ); bool CopyWithProgress( CString sSrcFile, CString sDstFile, void(*OnUpdate)(float) ); -bool CopyWithProgress( RageFileBasic &in, RageFileBasic &out, RageFileBasic &read, - CString &sError, void(*OnUpdate)(float), bool *bReadError = NULL ); +/* We will probably never need to use this. */ +//bool CopyWithProgress( RageFileBasic &in, RageFileBasic &out, RageFileBasic &read, +// CString &sError, void(*OnUpdate)(float), bool *bReadError = NULL ); #endif /* * Copyright (c) 2001-2004 Chris Danford, Glenn Maynard + * Copyright (c) 2008 BoXoRRoXoRs * All rights reserved. * * Permission is hereby granted, free of charge, to any person obtaining a diff --git a/src/ScreenArcadePatch.cpp b/src/ScreenArcadePatch.cpp index 320d1602..f8c54504 100644 --- a/src/ScreenArcadePatch.cpp +++ b/src/ScreenArcadePatch.cpp @@ -38,7 +38,12 @@ ScreenArcadePatch::ScreenArcadePatch( CString sClassName ) : ScreenWithMenuEleme static BitmapText *m_PatchStatus; static bool g_doReboot; -int GetRevision(); +// This is hacky, obviously. I'll fix it up soon. +// Right now, this just needs to compile. -- Vyhd +int GetRevision() +{ + return 21; +} ScreenArcadePatch::~ScreenArcadePatch() { diff --git a/src/arch/InputHandler/InputHandler_Linux_PIUIO.cpp b/src/arch/InputHandler/InputHandler_Linux_PIUIO.cpp index 00d372ce..4229fe00 100644 --- a/src/arch/InputHandler/InputHandler_Linux_PIUIO.cpp +++ b/src/arch/InputHandler/InputHandler_Linux_PIUIO.cpp @@ -70,6 +70,38 @@ void InputHandler_Linux_PIUIO::InputThreadMain() /* Requires "LightsDriver=ext" */ void InputHandler_Linux_PIUIO::UpdateLights() { + /* From the decompile: */ +#if 0 + if ( LightsDriver_External__g_LightState[9] ) + *(_WORD *)(a2 + 2) |= 0x20u; + if ( LightsDriver_External__g_LightState[8] ) + *(_WORD *)(a2 + 2) |= 0x10u; + if ( LightsDriver_External__g_LightState[11] ) + *(_WORD *)(a2 + 2) |= 8u; + if ( LightsDriver_External__g_LightState[10] ) + *(_WORD *)(a2 + 2) |= 4u; + if ( LightsDriver_External__g_LightState[29] ) + *(_WORD *)a2 |= 0x20u; + if ( LightsDriver_External__g_LightState[28] ) + *(_WORD *)a2 |= 0x10u; + if ( LightsDriver_External__g_LightState[31] ) + *(_WORD *)a2 |= 8u; + if ( LightsDriver_External__g_LightState[30] ) + *(_WORD *)a2 |= 4u; + if ( (_BYTE)LightsDriver_External__g_LightState ) + *(_WORD *)(a2 + 2) |= 0x80u; + if ( LightsDriver_External__g_LightState[2] ) + *(_WORD *)(a2 + 2) |= 0x200u; + if ( LightsDriver_External__g_LightState[1] ) + *(_WORD *)(a2 + 2) |= 0x400u; + if ( LightsDriver_External__g_LightState[3] ) + *(_WORD *)(a2 + 2) |= 0x100u; + if ( LightsDriver_External__g_LightState[6] ) + *(_WORD *)a2 |= 0x400u; + if ( LightsDriver_External__g_LightState[7] ) + *(_WORD *)a2 |= 0x400u; +#endif + static const int iCabinetBits[NUM_CABINET_LIGHTS-1] = { (1 << 22), (1 << 25), (1 << 24), (1 << 23), 0, 0, (1 << 10) }; @@ -99,6 +131,11 @@ void InputHandler_Linux_PIUIO::UpdateLights() FOREACH_ENUM( GameButton, 4, gb ) if( g_LightsState.m_bGameButtonLights[gc][gb] ) m_iLightData += iPlayerBits[gc][gb]; + + LOG->Trace( "UpdateLights: %u", m_iLightData ); + + // lights updating isn't too important...leave a lot of process time. + usleep( 10000 ); } /* diff --git a/src/arch/arch.cpp b/src/arch/arch.cpp index c38335d5..1901e634 100755 --- a/src/arch/arch.cpp +++ b/src/arch/arch.cpp @@ -60,7 +60,7 @@ void MakeInputHandlers(CString drivers, vector &Add) if( ret == NULL ) - LOG->Warn( "Unknown lights driver name: %s", s->c_str() ); + LOG->Warn( "Unknown input handler name: %s", s->c_str() ); else Add.push_back( ret ); }