dgrfactory / spcplay Goto Github PK
View Code? Open in Web Editor NEWSNES SPC700 Player + Improved SNESAPU.DLL
Home Page: https://dgrfactory.jp/spcplay/
License: GNU General Public License v2.0
SNES SPC700 Player + Improved SNESAPU.DLL
Home Page: https://dgrfactory.jp/spcplay/
License: GNU General Public License v2.0
有任何方法可以把程式翻譯成其他語言嗎?
Is there a way that can translate the program to other language?
When you load any song from Asterix soundtrack, the note appears to be cut off as soon attack phrase is done. Envelope is cut to 00.
Probably, something is wrong on GAIN emulation.
Once again, I am merely forwarding a playback difference report from the Discord servers that I am in, since I myself don't use the player because of a platform incompatibility.
This is related to #23, except instead of a playback failure, it is a failure to emulate an overflow effect (by wraparound, instead of clamping) in the echo buffer related to the FIR coefficients. An example SPC file straight out of Super Famicompo 3 has been attached, since the difference in question occurs immediately at the beginning.
Here is the SPC file in question in a .zip file.
I actually gave it a quick go on my SD2SNES Pro/FXPak Pro cartridge on a 2/1/3 North American SNES/SFC unit and confirmed the bug in question. Feel free to double check the playback on your own SPU (SHVC-SOUND unit).
when you export the audio channel as a .wav all audio channels will skip the silence and it causes all the audio channel samples to be out of sync. if possible could the author fix the time skip when converting a audio channel to .wav
There should be a seek bar even when in endless mode, the play head should just jump between the start and limit point when looping.
平素より、大変お世話になっております。
仮に私の計算が正しいとしても、このような命令を実行する可能性はドライバの不具合を除いて 0 であると思われ、修正する必要があるのかどうか疑問なレベルですが、ご報告いたします。
MOVW ($BA) や MOV ($E7) の 16 ビットメモリ読み込みをチェックしましたところ、実効アドレスが $00FF や $01FF の場合はその次のアドレスを上位バイトとして読み込んでいるようですので、JMP ($1F) も $FFFF と $0000 をそれぞれ下位・上位バイトとしたアドレスにジャンプすると予想して命令実行後の PC の値を計算しました。
しかし、APU.asm の [pAPURAM + 0x10000] は InitAPU で 0 に初期化されたまま更新されていません (?) ので、SNESAPU.DLL v2.18.4.7350 の PC には 0x0000 ~ 0x00FF の範囲の値が設定されるようです。
もし動作変更なさる場合は、他の命令と同じように PC への設定が 16 ビットアクセスのみで実現できるように、メモリへのデータ転送命令実行時に [pAPURAM + 0x10000] へ [pAPURAM + 0x00000] の値をコピーする処理を追加してくださいますか。
#エコーによる $0000 の書き換えをどうするのかという問題が発生しますが…
平素より、大変お世話になっております。
SETP ($40) を実行いたしますと、PSW の P フラグに 1 が、更に I フラグに 0 が設定されるのを確認いたしました。
#動作は問題ございませんが、RETI ($7F) の PSW に関するコメントは実際の動作と異なるようです。 (I = 1, 他 = ?)
Linux 環境で SNES SPC700 Player を動作させた場合、以下の不具合を確認しています。
The following problems have been observed when running the SNES SPC700 Player on Linux.
Here I am again, forwarding more playback differences. This is the sequel to #37.
This particular song is the next test case (it uses a different set of FIR coefficients, as I had refined the distortion effect from the past two songs): https://battleofthebits.com/arena/Entry/Stop_+Duck_+Rock+and+Roll/60690/
The overflow effect appears to have been emulated incorrectly, as this song's distortion effect came out more as static noise instead of the intended distortion effect that was being done (the feedback parameter was also being fooled around in the middle of the song). To make matters worse, the static lasts throughout the entire song instead of actually stopping as intended.
When you try to save as wave when playtime is set to endless, the player freezes.
(I'm using the beta if that's relevant)
I caught an interesting hardware bug relating to how the echo buffer can be used for an unusual kind of distortion effect that I was exploiting with my own music twice now relating to deliberately overflowing the FIR coefficents with an EDL of zero (and a non-zero EFB, though I made sure to keep it under just enough control to ger the desired effect). I'm don't actually use the player myself due to a platform incompatibility, but two of my Battle of the Bits entries have been getting reports of stopping the SPC the moment my distortion effects start playing. They are Extra Distortion Mania and New Wave Beat: the former made with SNESMod, the latter made with AddMusicKFF, a fork of AddMusicK that I created.
For Extra Distortion Mania, the track cuts off at 0:18, and for New Wave Beat, the track cuts off at 1:36. In both cases, it is because I started to use my distortion effects. Notably, it only happens once the audio starts to output: merely writing these kind of values to the DSP registers is not what causes the program to stop playing the SPCs.
https://battleofthebits.org/arena/Entry/Extra+Distortion+Mania/27243/
https://battleofthebits.org/arena/Entry/New+Wave+Beat/43032/
I have mirrored the original SPC files in a zip file here. The renders on Battle of the Bits contains the intended result.
SetSPCDbg または SNESAPUCallbackProc に SetSPCDbg の SPC_RETURN の機能と更に SPC700.asm の clkLeft を 0 にするフラグが欲しい。
Games: http://gdri.smspower.org/wiki/index.php/Super_Famicom/Super_NES_Sound_Driver_List#SFX_SOUND_DRIVER_.28Hudson.29
The player either doesn't skip or skips more than 5 seconds.
極端に短い時間を設定して EmuAPU でエミュレーションを続けると、DSP のエミュレーションが(一部 ?)実行されない。
Windows 8.1 Update1
SNESAPU v2.18.1
len に SPC700 の命令を一つ分など極端に短い時間を設定し、EmuAPU を連続で実行する。
キーオンされて時間が経過しても *Voice::bCur, DSPVoice::envx, DSPVoice::outx の値が変化しない。
This is a bit weird for one reason: I'm using Wine instead of running it natively on Windows. However, saving does work on previous versions (such as 2.19.1_7540) so I blame the program.
The exact problem: When trying to save to a .wav file the program gives me the error 252.
How to reproduce it:
I will test this on Windows as soon as possible, and post a comment.
Hello! I found a little oddity while exporting .spc files as .wav while having the option for endless playback enabled. Basically, every time I use the .wav export function, I get an audio file that's exactly 2 minutes and 11 seconds (default time?), which doesn't happen when I enable the option for ID666 play time.
While this barely an issue, it's worth noting that the previous stable release seemed to use the ID666 tags to determine the length of the song before exporting it to .wav, even in endless playback mode.
I am making a oscilloscope view video,
so it is nice to have a option that will not ignore silent in the first seconds in wav output.
ファイル保存時のファイルの選択ダイアログのファイル名には、最後に読み込んだ SPC ファイルのファイル名またはタイトルが保存するファイル名として設定されますが、タイトルが存在せず かつ ファイル名が短い(?)場合、ファイルの種類にかかわらず ファイル名.spc がファイル名として指定されるようです。
Windows Vista 環境で SNES SPC700 Player を動作させた場合、以下の動作不具合を確認しています。
The following problems have been observed when running the SNES SPC700 Player on Windows Vista.
League Champs from Brett Hull Hockey, Playoff Standings from Brett Hull Hockey '95 and Sucess! from Speed Racer in My Most Dangerous Adventures crash on the last build of spcplay.
When trying to build the spcplay.exe frontend it seems to compile ok but I get the following error every time I run the resulting exe "Initializing application is failed. (ERROR 119)"
Is this related to the version of dcc32 used? Can you share more information on how to set up a working dev environment for this project? You mention Delphi6 UP2 RTL3 in the readme, but I'm not certain where to obtain this software or how to get it running on a modern system.
The title should be self-explanatory. By adding this useful feature, we might be able to, to say, more precisely catch the values of strong frequency-based effects (such as tremolo and pitch bends) in SPCs for which there's no dedicated engine documentation or tools to extract the MML data from or see if there are very slight tick desyncs which cannot be perceived even when slowed down to 25%. Thanks in advance!
I used the latest pre-release build of SPCplay and some songs (such as the Dr. Mario config theme from Tetris & Dr. Mario, as well as the title themes from Extra Innings and Smash Tennis). This issue was present on older builds and I'm surprised how it wasn't fixed in years.
in spcplay, tcall seems to ignore the r flag at $F1 (r-ba-210) which controls if $FFC0-$FFFF is IPL ROM or normal RAM, always treating it as the latter. this spcplay quirk is apparently not real SNES behaviour.
i stumbled upon this while trying to narrow down the cause of my spc files playing fine on spcplay, but not on anything else (i.e. foobar, and discord bots generating empty mp3 files out of my spc files). when i replaced every instance of tcall on my driver with generic call commands, it worked fine, and with help from KungFuFurby who used bsnes+, i discovered disabling the previously said flag would allow tcall to work properly so i can only blame spcplay for innacuracy here
Hello! I compose SNES music with AddMusicK and the EarthBound Music Editor, and I'd love there to be a new debug view, or possibly a seperate window launched from one of the menus, that looks like this:
S# ADSR/GAIN TUNING
00: FF F0 B8 0380
01: FF E0 B8 0300
02: FF F2 B8 0260
(information for the rest of the loaded samples goes here)
== DELAY PARAMETERS ==
CHANNELS: 3F | VOLUME: 2A 2A
DELAY: 03 | FEEDBACK: 20
FIR FILTER: 34 33 00 D9 E5 01 FC E6
To construct an instrument table in AddMusicK and EBMusEd, you need the ADSR and tuning data in this format - this kind of hexadecimal layout would make recreating this data in new musical arrangements much easier. Is something like this feasible in a future release?
In the emulators that I tested with, while the note is in the "decay" mode, if the ADSR's sustain value changes mid-note and its changed sustain value is higher (which causes less decay time), the decay time still has to decay to its initial sustain value, despite the higher sustain value that causes less decay time.
However, in SPCPlay, when the sustain value gets higher mid-note while the note is decaying, it skips the decay and goes straight into sustain/release, which is inaccurate.
I wanted to check what the spccmd.exe had for commands, so I tried to get help from the program by appending the -h
flag to the command line.
This makes the program spew gibberish except some characters. From reading the source code I believe the issue lie with the program trying to output Japanese characters into command line which doesn't know how to deal with it.
Attached is a screenshot of windows powershell when I tried to run the command ./spccmd.exe -h
I was thinking of this visualizer to be added:
While the music may be a tracker format and does not know the notes in advance like a midi file, it at least knows the notes currently being played. This is why notes that have been played are displayed as a "rain" (named after miditrail) only to be displayed under the piano keys.
Source: https://www.youtube.com/watch?v=igP51SMfCYA
Hello, this is something I noticed a long time ago: I have a SPC that constantly updates the FIR Filter along some other echo parameters, and at one point, the echo in the kick drum channel is disabled so that it isn't affected by the FIR Filter any further, however, bsnes and many other emulators and players still output the first kick note with echo even after I disabled it, whereas SPCplay does not. I was wondering if it could be some kind of inaccurate emulation regarding SPCplay?
I have attached two audio files (including two extra ones with the kick isolated) and the original SPC file, the event occurs at 0:08.
spcplay echo.zip
If run SNES SPC700 Player on English OS, playlist might be 1 line smaller.
You can adjust it with LISTHGT option in spcplay.ini file.
サンプリングレートを 32,000 Hz 以外に設定した場合、一部の曲で実機と極端に異なる音が出力されることがあります。
以下の作品で不具合を確認しています。
When the sampling rate is set to a value other than 32,000 Hz, some songs may output sounds extremely different from those of the actual device.
I have confirmed the problem with the following games.
音量が負に設定されている曲を演奏中、フェードアウトが終了しても、完全に音量が0になりません。
以下のすべての条件に一致する場合に発生します。
クリックノイズ防止アルゴリズムの不具合。
v2.18.3 以降で対応予定です。
v2.18.3 (build 7206) で対応しました。
→ https://github.com/dgrfactory/spcplay/releases
It would be really nice if there was an option to save SPC files as wav files
SNESAPUCallbackProc で設定するコールバック関数 effect = CBE_DSPREG の仕様が @dgrfactory 様のサイトの説明では
addr | DSP レジスタのアドレス (0x00~0x7F)
となっていますが、実際はアドレスの範囲チェック前に呼び出されるため 0x80 - 0xFF の値を指定可能になっています。
想定していないアプリは誤動作や異常終了する可能性があります。
I've noticed that spcplay has a define WIN10DARK
that's commented out. I have not seen what spcplay in a dark theme looks like, as I'm unable to build the executable, but having a dark theme available would be very welcome. Can this feature be uncommented and exposed as a toggleable setting?
Some people may prefer the old fonts, so I suggest to make it can be config by user.
Maybe the setting can be in spcplay.ini?
特定のポートを読み込むまで待機 [入力ポート]
サウンドドライバは bsnes などエミュレータでは正しく演奏されることを確認済です。
ご検討よろしくお願いいたします。
For exmple:
When opening a file on non-Japanese operating systems, and the file name contains Japanese characters, the program will not be able to read the file.
And if you open a file with Chinese characters on a non-Chinese system, it will show the same error.
Apologies for not using Japanese, but watashi do not speak nihongu
Ever since version 2.19.2 (mostly because i am lazy and did not test versions before that) the spcplay zip archive / individual exe components trigger at least 1 antivirus in virustotal, if they provide detail it's usually a trojan.
Example scans:
2.19.2 zip - https://www.virustotal.com/gui/file/a7885ac661c9105f322275175af9de9570c287e97ed63bfca8f4379f616bc996
2.19.3 zip - https://www.virustotal.com/gui/file/e92c0df5c94f53088f0d62cd0e6adeb2bcfe6a7c50088b43db6a889b2d44193d
2.19.4 zip - https://www.virustotal.com/gui/file/be8ddd2bbf14e0e64053bb212ba790292938124dee558de19c468197c9d43bee
2.19.4 spcplay.exe - https://www.virustotal.com/gui/file/92aa50575eeef2eb0cc143762c73ba613db970bfdcdd9e619881879d793f40a6
Steps to reproduce:
When i export separate channels, it seems the timing is off.
For instance: Secret of the Forest from Chrono Trigger. When you export channel 1, 2, 3 and 4 separately and merge them back together (in my DAW), the arpeggiator notes are locked on the same grid instead of doing the 4-step arpeggiator. See image attached.
It seems they all start at the exact same beat instead of having the small offset it should need. When i export them as a group, it sounds fine.
In other words: it seems like the start time is off when you export a separate channel (missing the right offset). Maybe it's skipping the silence and goes right to the first sample?
Please advise, thank you.
Hopefully this make it bit more clear what i mean looking at the waveforms in my DAW:
Wrong render:
.How it should be:
ResetSPC の Enable ROM reading のコメントがある行の命令 Mov byte [EAX-0Fh],80h で ARAM $00E1 の値が 0xFF から 0x80 に上書きされるようです。
#Timer status is preserved, other bits are reset のコメントがある行の次の行の命令 Or byte [EAX+1],80h で既に IPL ROM 読み込みフラグがオンに設定されているようです。
Hi! I compose and arrange SNES music and it would be great if there was an option for the envelopes (GAIN/ADSR) to be synchronized with the speed controls, this would be super useful for debugging fast or subtle GAIN changes in a song.
Having to manually click to mute and unmute each channel, and then saving with a different file name to export each channel as its own file can be annoying, so preferably there should be a way in spccmd to easily specify which channels should be played when exporting to WAV with the -cw
option.
Then to output all channels as it's own file, you could just do a for /L
from 1 to 8 in CMD.
When the BRK instruction is encountered, the PC should be pushed, the PSW should be pushed, and the Break flag should be set. However, spcplay will set the Break flag before the PSW is pushed, meaning that the PSW pushed to stack (and the PSW restored when RETI is called) has the Break flag set also, resulting in it never being cleared until power is turned off. I'm aware that this is somewhat of a non-issue, seeing as the Break flag isn't used whatsoever, but it's still erroneous, so I figured it worthwhile to point out.
先日は 16 ビットデータアクセスの件でご修正いただき、誠にありがとうございます。
#27 の @dgrfactory 様の検証内容に関する質問内容でございますこと心より謝罪申し上げます。
MOVW YA,dp などのオペランドに dp を使用する 16 ビットデータを処理する命令ではダイレクトページを超えないメモリ参照が行われるのを確認いたしましたが、MOV A,[dp+X] などのポインタ値を取得する命令の場合ポインタ値取得時にダイレクトページを超えるのが正しい処理でよろしいでしょうか。
お手数をおかけしますが、ご回答いただけますと幸いです。
必要最小限の APU サイクルで EmuAPU を利用し SPC700 の命令を一つ分実行すると、GetSPCRegs の PC の値が想定した値と異なる値になる。
Windows 8.1 Update1
SNESAPU v2.18.1
LoadSPCFile で SPC ファイルを読み込む。
GetSPCRegs で PC の値を取得する。
PC の指す APU メモリの値を取得し、次の命令の実行に必要な APU サイクル数 [*1] と、実行後の PC の値 [*2] を計算する。
EmuAPU (len = [*1]) を実行する。
GetSPCRegs で PC の値を取得し、[*2] の値と比較すると異なる値である。
再現手順 4 で EmuAPU (len = [*1] - 1) と EmuAPU (len = 1) を実行する。
ただし時間が短すぎるためか、 DSP のエミュレーションは実行されないようである(#17)。
ブレークポイント設定コマンド [ブレークポイントを設定するアドレス]
実行ファイルと違いスクリプトであれば spcplay.exe (と転送用のデータのみ)で実行可能ですので、ハードルが低いかなと…
以上です。ご検討よろしくお願いいたします。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.