Closed WNCX closed 3 years ago
补充:已经使用提供的三个文件并置于mirai项目同目录下
请把配置文件中的ffmpeg路径设置为绝对路径。
请把配置文件中的ffmpeg路径设置为绝对路径。
已经照做了,但输出仍然是
2021-01-06 23:02:58 W/stderr: java.io.FileNotFoundException: .\temp\wv1609945376495.amr (系统找不到指定的文件。) 2021-01-06 23:02:58 W/stderr: at java.io.FileInputStream.open0(Native Method) 2021-01-06 23:02:58 W/stderr: at java.io.FileInputStream.open(Unknown Source) 2021-01-06 23:02:58 W/stderr: at java.io.FileInputStream.<init>(Unknown Source) 2021-01-06 23:02:58 W/stderr: at com.khjxiaogu.MiraiSongPlugin.cardprovider.AmrVoiceProvider.process(AmrVoiceProvider.java:71) 2021-01-06 23:02:58 W/stderr: at com.khjxiaogu.MiraiSongPlugin.MiraiSongPlugin.lambda$onEnable$4(MiraiSongPlugin.java:230) 2021-01-06 23:02:58 W/stderr: at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) 2021-01-06 23:02:58 W/stderr: at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) 2021-01-06 23:02:58 W/stderr: at java.lang.Thread.run(Unknown Source)
配置文件是这样写的
ffmpeg_path: "D:\Program Files(Non-inst)\mirairobot\old-mirai-console-launcher\ffmpeg.exe" silkenc_path: "silk_v3_encoder.exe" adddefault: true amrqualityshift: false amrwb: false extracommands: "#分享": source: all card: Share
"#搜歌": source: 网易 card: XML
mirai目录下是否有一个名为temp的文件夹?
请把路径配置改为:"D:\\Program Files(Non-inst)\\mirairobot\\old-mirai-console-launcher\\ffmpeg.exe"再试试
请把路径配置改为:"D:\Program Files(Non-inst)\mirairobot\old-mirai-console-launcher\ffmpeg.exe"再试试
可能是github的转义导致“\\”显示成了\,我在一开始的时候就是写"\\"的 另外mirai目录下的确有temp的文件夹,但并没有错误里所说的amr文件
有可能是ffmpeg安装问题,请准备一个音频文件并打开命令行输入
"D:\\Program Files(Non-inst)\\mirairobot\\old-mirai-console-launcher\\ffmpeg.exe"-i 输入音频文件路径 -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr
并把命令行输出发上来
有可能是ffmpeg安装问题,请准备一个音频文件并打开命令行输入
"D:\\Program Files(Non-inst)\\mirairobot\\old-mirai-console-launcher\\ffmpeg.exe"-i 输入音频文件路径 -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr
并把命令行输出发上来
D:\Program Files(Non-inst)\mirairobot\old-mirai-console-launcher>ffmpeg.exe -i testering.flac -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr FFmpeg version SVN-r11143, Copyright (c) 2000-2007 Fabrice Bellard, et al. configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-liba52 --enable-avisynth --enable-libamr-nb --enable-libamr-wb --enable-libfaac --enable-libfaad --enable-libgsm --enable-libmp3lame --enable-libnut --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --cpu=i686 --enable-memalign-hack --extra-ldflags=-static libavutil version: 49.5.0 libavcodec version: 51.48.0 libavformat version: 52.1.0 built on Dec 3 2007 17:42:57, gcc: 4.2.2 (mingw32) Input #0, flac, from 'testering.flac': Duration: N/A, bitrate: N/A Stream #0.0: Audio: flac, 44100 Hz, stereo Output #0, amr, to 'test.amr': Stream #0.0: Audio: libamr_nb, 8000 Hz, mono, 12 kb/s Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding size= 512kB time=327.4 bitrate= 12.8kbits/s video:0kB audio:512kB global headers:0kB muxing overhead 0.001145%
大概是这样,amr也顺利转出来了
github这里没有显示出换行,可能很乱,将就着看吧
有可能是ffmpeg安装问题,请准备一个音频文件并打开命令行输入
"D:\\Program Files(Non-inst)\\mirairobot\\old-mirai-console-launcher\\ffmpeg.exe"-i 输入音频文件路径 -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr
并把命令行输出发上来
D:\Program Files(Non-inst)\mirairobot\old-mirai-console-launcher>ffmpeg.exe -i testering.flac -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr FFmpeg version SVN-r11143, Copyright (c) 2000-2007 Fabrice Bellard, et al. configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-liba52 --enable-avisynth --enable-libamr-nb --enable-libamr-wb --enable-libfaac --enable-libfaad --enable-libgsm --enable-libmp3lame --enable-libnut --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --cpu=i686 --enable-memalign-hack --extra-ldflags=-static libavutil version: 49.5.0 libavcodec version: 51.48.0 libavformat version: 52.1.0 built on Dec 3 2007 17:42:57, gcc: 4.2.2 (mingw32) Input #0, flac, from 'testering.flac': Duration: N/A, bitrate: N/A Stream #0.0: Audio: flac, 44100 Hz, stereo Output #0, amr, to 'test.amr': Stream #0.0: Audio: libamr_nb, 8000 Hz, mono, 12 kb/s Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding size= 512kB time=327.4 bitrate= 12.8kbits/s video:0kB audio:512kB global headers:0kB muxing overhead 0.001145%
大概是这样,amr也顺利转出来了 github这里没有显示出换行,可能很乱,将就着看吧
请不要使用cd,请直接按照命令行执行。
有可能是ffmpeg安装问题,请准备一个音频文件并打开命令行输入
"D:\\Program Files(Non-inst)\\mirairobot\\old-mirai-console-launcher\\ffmpeg.exe"-i 输入音频文件路径 -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr
并把命令行输出发上来
D:\Program Files(Non-inst)\mirairobot\old-mirai-console-launcher>ffmpeg.exe -i testering.flac -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr FFmpeg version SVN-r11143, Copyright (c) 2000-2007 Fabrice Bellard, et al. configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-liba52 --enable-avisynth --enable-libamr-nb --enable-libamr-wb --enable-libfaac --enable-libfaad --enable-libgsm --enable-libmp3lame --enable-libnut --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --cpu=i686 --enable-memalign-hack --extra-ldflags=-static libavutil version: 49.5.0 libavcodec version: 51.48.0 libavformat version: 52.1.0 built on Dec 3 2007 17:42:57, gcc: 4.2.2 (mingw32) Input #0, flac, from 'testering.flac': Duration: N/A, bitrate: N/A Stream #0.0: Audio: flac, 44100 Hz, stereo Output #0, amr, to 'test.amr': Stream #0.0: Audio: libamr_nb, 8000 Hz, mono, 12 kb/s Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding size= 512kB time=327.4 bitrate= 12.8kbits/s video:0kB audio:512kB global headers:0kB muxing overhead 0.001145%
大概是这样,amr也顺利转出来了 github这里没有显示出换行,可能很乱,将就着看吧请不要使用cd,请直接按照命令行执行。
C:\Users\Administrator>"D:\\Program Files(Non-inst)\\mirairobot\\old-mirai-console-launcher\\ffmpeg.exe" -i F:\tester.flac -ab 12.2k -ar 8000 -ac 1 -fs 1000000 -y test.amr FFmpeg version SVN-r11143, Copyright (c) 2000-2007 Fabrice Bellard, et al. configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-liba52 --enable-avisynth --enable-libamr-nb --enable-libamr-wb --enable-libfaac --enable-libfaad --enable-libgsm --enable-libmp3lame --enable-libnut --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --cpu=i686 --enable-memalign-hack --extra-ldflags=-static libavutil version: 49.5.0 libavcodec version: 51.48.0 libavformat version: 52.1.0 built on Dec 3 2007 17:42:57, gcc: 4.2.2 (mingw32) Input #0, flac, from 'F:\tester.flac': Duration: N/A, bitrate: N/A Stream #0.0: Audio: flac, 44100 Hz, stereo Output #0, amr, to 'test.amr': Stream #0.0: Audio: libamr_nb, 8000 Hz, mono, 12 kb/s Stream mapping: Stream #0.0 -> #0.0 Press [q] to stop encoding size= 512kB time=327.4 bitrate= 12.8kbits/s video:0kB audio:512kB global headers:0kB muxing overhead 0.001145%
amr文件人工找不到,包括ffmpeg.exe的目录还是被转的音频的目录
描述bug问题
就跟题目一样
如何重现
就是普通输入#点歌 网易 AMR hello
你希望的修复后结果
能够正常使用,输出相关信息
截屏/报错信息
2021-01-01 21:39:55 W/stderr: java.io.FileNotFoundException: .\temp\wv1609508394741.amr (系统找不到指定的文件。) 2021-01-01 21:39:55 W/stderr: at java.io.FileInputStream.open0(Native Method) 2021-01-01 21:39:55 W/stderr: at java.io.FileInputStream.open(Unknown Source) 2021-01-01 21:39:55 W/stderr: at java.io.FileInputStream.<init>(Unknown Source) 2021-01-01 21:39:55 W/stderr: at com.khjxiaogu.MiraiSongPlugin.cardprovider.AmrVoiceProvider.process(AmrVoiceProvider.java:71) 2021-01-01 21:39:55 W/stderr: at com.khjxiaogu.MiraiSongPlugin.MiraiSongPlugin.lambda$onEnable$4(MiraiSongPlugin.java:230) 2021-01-01 21:39:55 W/stderr: at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) 2021-01-01 21:39:55 W/stderr: at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) 2021-01-01 21:39:55 W/stderr: at java.lang.Thread.run(Unknown Source)