From c188aafb22c91774c8b526675a35056e5ac84e10 Mon Sep 17 00:00:00 2001 From: Zachary Hall Date: Tue, 15 Oct 2024 09:44:56 -0700 Subject: [PATCH] Fix loop position --- .codelite/neko-player-someone.tags | Bin 98304 -> 0 bytes .gitignore | 1 + backends/playback/zsm/zsm_backend.cpp | 3 ++- 3 files changed, 3 insertions(+), 1 deletion(-) delete mode 100644 .codelite/neko-player-someone.tags diff --git a/.codelite/neko-player-someone.tags b/.codelite/neko-player-someone.tags deleted file mode 100644 index db051cd141d2ea45ac4bd878e467603796f4edeb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 98304 zcmeI)Z*S8^9Ki9IKS>Le|G`w#w417`jVOf^AcG$~0s=q40})(sYI(mF1q zNZS;&2fUy?n8eH28{pxl?b)8};qK0kW1DW8c!u?jXz}@cKmYD?=W|X-)E|}|&lX!< zccH^>9?ny zvERnrQ@@W(&&#molX0t*J}5gFKoBxbUV%cjG9!ITtOd7s-ek(blD`IX7h-=mz!D%4*qa zt`z5M)p~QWRJLMg@*Ajb#<$++iUa%aH)yv%|u>ur9wuh)$LPR^V7Uh*U{9JZAl)gbFqzc3a-F8PRjv zotC%n%G1Gomk0LF?siKq44d|r({Vhx#1;CL(cC8!`H|OMxu&$+wyW;ibUHnGqz;4o zH)^G&C9CGIM}Dm+E;i(uQl)Oy8lqa!bz-qv6IOA4S=6eJ#G_@aA}ZFSSv^(7T`_gX zAM&rJ#C>b2R1xYEL?~4n)#wxw(~j(o8fclhKbyqY#qyd}7t@usa(PBa_UqL>%N19zxrcSguMIl1V3jSo#vj_DVbZ}>i?!-XENR*0niV}W>*p>z zUo9`lBvp>fIr-F^MmwBp^`?3<^*TFp*of;IeT^D&UGkUI{*i3XoSHKF^ZKO{TXbWE z+@Rn3wGyim)1?JD2n|aO@M^8JQmn0u2iCeMt~IKqifp(dSH&5jCRy<6@y8`76#BQ0 z=gjeO<8?_V;XhRV?`-V0{<#mj-?r1Sh12nDIYnc4pAk;4xwYTfP}8}&?L60)%?Q_) zbA7|!k&ASgbofvVGWU+8&6yJu zMqjSd@{2%Z5sVxji)9e0_`i9m2P5owFb4y_!s?N%dF6_+uJ0dwS?Jk&`*vr;P85&E z@<>$b_wkHuS$KWl$eH=P@l#vJl=thYpChr>>dXhFADemcnV{CZu$!$7nSU=VCWl+E zjh^jx!Ylljcvy5g&urK6h7r_S8rBBuXjt|aHUGQVp^IyHrQ+Xp<=fiz9D5jjr?ugB z@!_KN-d=NkY0R#|0009ILKmY**5I`WU0_^|OIAb{}6;D1Q0*~0R#|0009ILKmY**QYgUwKZS!zmk>Yz0R#|0009ILKmY**5J(8H z|4)EWL;wK<5I_I{1Q0*~0R#|0AcX?#|5G@qbO`|j5I_I{1Q0*~0R#|00D*)6`~L(8 zMFbE)009ILKmY**5I_I{1X3u#{y&9-N|z8o009ILKmY**5I_I{1Q19Fu>VhhP(%O$ z1Q0*~0R#|0009ILKp=$z?Eh0ZsB{Sd1Q0*~0R#|0009ILKmdV+0Q>(02t@=CKmY** z5I_I{1Q0*~0R&Pg!2UmlgG!eWKmY**5I_I{1Q0*~0R#|82(bT8fKWsL0R#|0009IL zKmY**5I`V>0_^`&IH+_90R#|0009ILKmY**5I_KdgaG^h1PDb05I_I{1Q0*~0R#|0 z009J2D8T+dg@a0$5I_I{1Q0*~0R#|0009ILNC=F{vT^3mjQqm~0R#|0009ILKmY** z5I_I{1X3Vye(%WD`R=A&c060WnEP_}`s_{h@BhY`KQi(U9|RCU009ILKmY**5I_I{ u1Q7W61uh=FY9zP+d+h%|{(+?j2q1s}0tg_000IagfB*srLget_pos() == (size_t)loop_point) loop_pos = time; ZsmCommand cmd = get_command(); if (cmd.id == ZsmEOF) { break; @@ -65,7 +66,7 @@ void ZsmBackend::load(const char *filename) { music_data_len = file->get_pos(); switch_stream(0); loop_end = length; - loop_start = ((double)this->loop_point) / ((double)tick_rate); + loop_start = this->loop_pos; fm_stream = SDL_NewAudioStream(AUDIO_S16SYS, 2, YM_FREQ, AUDIO_S16SYS, 2, PSG_FREQ); DEBUG.writefln("fm_stream: %ld -> %ld", YM_FREQ, PSG_FREQ); }