Skip to content

Commit 507f830

Browse files
committed
Refactoring indexes
1 parent 1bf5add commit 507f830

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

util/image.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,7 @@ void SaveRAW_TIM(char* out, char** filenames, size_t nbFiles)
141141
{
142142
for (int x = 0; x < rect_w * 2; x++)
143143
{
144-
size_t timDataIndex = (rect_y + y) * 64 * 6 + rect_x + x;
145-
size_t bgImagePieceIndex = y * 128 + x;
146-
bgImagePiece[bgImagePieceIndex] = image_data[timDataIndex];
144+
bgImagePiece[y * 128 + x] = image_data[(rect_y + y) * 64 * 6 + rect_x + x];
147145
}
148146
}
149147
fwrite(bgImagePiece, 1, 0x8000, fp);

0 commit comments

Comments
 (0)