This commit is contained in:
Nishi 2025-11-24 20:16:42 +09:00
commit d8cec5cc3d
Signed by: nishi
GPG key ID: 27EF69B208EB9343
3 changed files with 18 additions and 18 deletions

View file

@ -203,21 +203,21 @@ int queue_last = -1;
static void window_tick(MwWidget handle, void* user, void* client) {
pthread_mutex_lock(&audio_mutex);
if(queue_last != queue_seek && queue_seek != -1) {
int ind;
char* buf;
size_t sz;
int ind;
char* buf;
size_t sz;
unsigned char* img;
img = id3_findimage(queue[queue_seek].path, &sz);
if(img != NULL){
int iw, ih, ic;
if(img != NULL) {
int iw, ih, ic;
unsigned char* data = stbi_load_from_memory(img, sz, &iw, &ih, &ic, 4);
if(data != NULL){
if(data != NULL) {
int y, x;
for(y = 0; y < ALBUMWIDTH; y++){
for(x = 0; x < ALBUMWIDTH; x++){
int ix = x * iw / ALBUMWIDTH;
int iy = y * ih / ALBUMWIDTH;
for(y = 0; y < ALBUMWIDTH; y++) {
for(x = 0; x < ALBUMWIDTH; x++) {
int ix = x * iw / ALBUMWIDTH;
int iy = y * ih / ALBUMWIDTH;
unsigned char* ipx = &data[(iy * iw + ix) * 4];
unsigned char* opx = &((MwLLCommonPixmap)pxalbum)->raw[(y * ALBUMWIDTH + x) * 4];