Skip to content

Commit 769c920

Browse files
committed
Run DC_FlushRange on each loaded frame to prevent incorrect colors and/or pixels appearing
1 parent 930999f commit 769c920

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

arm9/source/main.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -533,6 +533,7 @@ static inline void loadFramePal(const int num, const int loadedFrameNum) {
533533
}
534534
}
535535
}
536+
DC_FlushRange(palBuffer[num], 256*2);
536537

537538
previousNum = num;
538539
}
@@ -581,6 +582,7 @@ void loadFrame(const int num) {
581582
}
582583
// applyColorLutToFrame((u16*)dst);
583584
}
585+
DC_FlushRange(dst, rvidHRes*rvidVRes);
584586
sndUpdateStream();
585587
rvidCurrentOffset = frameOffsets[loadedSingleFrames];
586588
loadedSingleFrames++;
@@ -599,6 +601,7 @@ void loadFrame(const int num) {
599601
fread(dst, 1, rvidHRes*rvidVRes, rvid);
600602
// applyColorLutToFrame((u16*)dst);
601603
}
604+
DC_FlushRange(dst, rvidHRes*rvidVRes);
602605
sndUpdateStream();
603606
rvidCurrentOffset = frameOffsets[loadedSingleFrames];
604607
loadedSingleFrames++;
@@ -627,6 +630,7 @@ void loadFrame(const int num) {
627630
}
628631
// applyColorLutToFrame((u16*)dst);
629632
}
633+
DC_FlushRange(dst, rvidHRes*rvidVRes);
630634
sndUpdateStream();
631635
rvidCurrentOffset = frameOffsets[loadedFrames];
632636
}

0 commit comments

Comments
 (0)