diff --git a/src/drivers/Qt/TasEditor/TasEditorWindow.h b/src/drivers/Qt/TasEditor/TasEditorWindow.h index da35ccee..0c75ea28 100644 --- a/src/drivers/Qt/TasEditor/TasEditorWindow.h +++ b/src/drivers/Qt/TasEditor/TasEditorWindow.h @@ -104,7 +104,7 @@ enum PIANO_ROLL_COLUMNS #define HEADER_LIGHT_HOLD 5 #define HEADER_LIGHT_MOUSEOVER_SEL 3 #define HEADER_LIGHT_MOUSEOVER 0 -#define HEADER_LIGHT_UPDATE_TICK (40 * (CLOCKS_PER_SEC / 1000)) // 25FPS +#define HEADER_LIGHT_UPDATE_TICK (CLOCKS_PER_SEC / 25) // 25FPS struct NewProjectParameters { diff --git a/src/drivers/Qt/TasEditor/bookmarks.h b/src/drivers/Qt/TasEditor/bookmarks.h index bfe957f9..7eda6c40 100644 --- a/src/drivers/Qt/TasEditor/bookmarks.h +++ b/src/drivers/Qt/TasEditor/bookmarks.h @@ -42,7 +42,7 @@ enum BOOKMARK_COMMANDS #define ITEM_UNDER_MOUSE_CLOUD (-1) #define ITEM_UNDER_MOUSE_FIREBALL (TOTAL_BOOKMARKS) -#define BOOKMARKS_FLASH_TICK (100 * CLOCKS_PER_SEC / 1000) // in milliseconds +#define BOOKMARKS_FLASH_TICK (CLOCKS_PER_SEC / 10) // 10 Hz // listview columns enum diff --git a/src/drivers/Qt/TasEditor/branches.cpp b/src/drivers/Qt/TasEditor/branches.cpp index cc296d6d..d9afe7b0 100644 --- a/src/drivers/Qt/TasEditor/branches.cpp +++ b/src/drivers/Qt/TasEditor/branches.cpp @@ -388,7 +388,8 @@ void BRANCHES::update() // teleport cornersCursorX = playbackCursorX; cornersCursorY = playbackCursorY; - } else + } + else { // advance double speed = sqrt(distance); @@ -403,10 +404,12 @@ void BRANCHES::update() mustRedrawBranchesBitmap = true; lastItemUnderMouse = bookmarks->itemUnderMouse; } - if (mustRedrawBranchesBitmap) - { - redrawBranchesBitmap(); - } + //printf("Draw Clock: %lu \n", nextAnimationTime ); + mustRedrawBranchesBitmap = true; + //if (mustRedrawBranchesBitmap) + //{ + // redrawBranchesBitmap(); + //} } } if ( mustRedrawBranchesBitmap ) diff --git a/src/drivers/Qt/TasEditor/branches.h b/src/drivers/Qt/TasEditor/branches.h index 22b7ee0f..9a2b1137 100644 --- a/src/drivers/Qt/TasEditor/branches.h +++ b/src/drivers/Qt/TasEditor/branches.h @@ -8,7 +8,7 @@ #include #include -#define BRANCHES_ANIMATION_TICK (40 * CLOCKS_PER_SEC / 1000) // animate at 25FPS +#define BRANCHES_ANIMATION_TICK (CLOCKS_PER_SEC / 25) // animate at 25FPS #define BRANCHES_TRANSITION_MAX 12 #define CURSOR_MIN_DISTANCE 1.0 #define CURSOR_MAX_DISTANCE 256.0 diff --git a/src/drivers/Qt/TasEditor/greenzone.h b/src/drivers/Qt/TasEditor/greenzone.h index 194ae4ae..edf1770d 100644 --- a/src/drivers/Qt/TasEditor/greenzone.h +++ b/src/drivers/Qt/TasEditor/greenzone.h @@ -7,7 +7,7 @@ #define GREENZONE_ID_LEN 10 -#define TIME_BETWEEN_CLEANINGS (10000 * (CLOCKS_PER_SEC / 1000)) // in milliseconds +#define TIME_BETWEEN_CLEANINGS (10 * CLOCKS_PER_SEC) // Greenzone cleaning masks #define EVERY16TH 0xFFFFFFF0 diff --git a/src/drivers/Qt/TasEditor/history.h b/src/drivers/Qt/TasEditor/history.h index 8de1156f..bcfcb2dd 100644 --- a/src/drivers/Qt/TasEditor/history.h +++ b/src/drivers/Qt/TasEditor/history.h @@ -8,10 +8,10 @@ #include "Qt/TasEditor/bookmark.h" #include "Qt/TasEditor/snapshot.h" -#define UNDO_HINT_TIME (200 * (CLOCKS_PER_SEC / 1000)) // in milliseconds +#define UNDO_HINT_TIME (CLOCKS_PER_SEC / 5) // in milliseconds #define SAVING_HISTORY_PROGRESSBAR_UPDATE_RATE 10 -#define TIME_BETWEEN_AUTOCOMPRESSIONS (500 * (CLOCKS_PER_SEC / 1000)) // in milliseconds +#define TIME_BETWEEN_AUTOCOMPRESSIONS (CLOCKS_PER_SEC / 2) // in milliseconds #define HISTORY_LIST_WIDTH 500 diff --git a/src/drivers/Qt/TasEditor/playback.h b/src/drivers/Qt/TasEditor/playback.h index 5256c4b9..bf4008ea 100644 --- a/src/drivers/Qt/TasEditor/playback.h +++ b/src/drivers/Qt/TasEditor/playback.h @@ -6,10 +6,10 @@ #define PROGRESSBAR_WIDTH 200 -#define PAUSEFRAME_BLINKING_PERIOD_WHEN_SEEKING (100 * (CLOCKS_PER_SEC / 1000)) -#define PAUSEFRAME_BLINKING_PERIOD_WHEN_PAUSED (250 * (CLOCKS_PER_SEC / 1000)) +#define PAUSEFRAME_BLINKING_PERIOD_WHEN_SEEKING (CLOCKS_PER_SEC / 10) +#define PAUSEFRAME_BLINKING_PERIOD_WHEN_PAUSED (CLOCKS_PER_SEC / 4) -#define BUTTON_HOLD_REPEAT_DELAY (250 * (CLOCKS_PER_SEC / 1000)) // in milliseconds +#define BUTTON_HOLD_REPEAT_DELAY (CLOCKS_PER_SEC / 4) // in milliseconds class UpperMarkerNoteEdit : public QLineEdit { diff --git a/src/drivers/Qt/fceuWrapper.cpp b/src/drivers/Qt/fceuWrapper.cpp index e87f7a75..0ff3063e 100644 --- a/src/drivers/Qt/fceuWrapper.cpp +++ b/src/drivers/Qt/fceuWrapper.cpp @@ -1312,7 +1312,7 @@ int fceuWrapperUpdate( void ) // sleep to allow request to be serviced. if ( mutexPending > 0 ) { - msleep( 100 ); + msleep( 16 ); } lock_acq = fceuWrapperTryLock( __FILE__, __LINE__, __func__ ); @@ -1323,7 +1323,7 @@ int fceuWrapperUpdate( void ) { printf("Error: Emulator Failed to Acquire Mutex\n"); } - msleep( 100 ); + msleep( 16 ); return -1; }