QQ音乐下载qmc0/3批量转MP3工具

部署运行你感兴趣的模型镜像

qmc3转MP3工具

QQ音乐下载的文件为qmc0或者qmc3格式,导致其他播放器不能播放,为此找到了转化源码并制作批量转化工具。

运行环境:windows7 64bit
编译环境:VS2010

使用方法:
1,把exe拷贝到本地存放qmc3文件夹
2,双击exe运行
3,转换后的mp3文件在同一目录

运行截图
下载链接可执行程序下载地址
百度链接https://pan.baidu.com/s/1WRzkgvQNGnfHnrl78HTtWQ
提取码: tfir

解码器源码

class Seed{
public:
    Seed():x(-1),y(8),dx(1),index(-1){
    }

    unsigned char NextMask(){
        unsigned char ret;
        index++;
        if(x < 0)
        {
            dx  = 1;
            y   = (8 - y) % 8;
            ret = 0xc3;
        }else if(x > 6){
            dx  = -1;
            y   = 7-y;
            ret = 0xd8;
        }else{
            ret = seedMap[y][x];
        }

        x += dx;
        if(index == 0x8000 || (index > 0x8000 && (index+1) % 0x8000 == 0) )
            return NextMask();
        return ret;
    }


private:

    int x;
    int y;
    int dx;
    int index;
    static unsigned char seedMap[8][8];
};

unsigned char Seed::seedMap[8][8]={
    {0x4a, 0xd6, 0xca, 0x90, 0x67, 0xf7, 0x52},
    {0x5e, 0x95, 0x23, 0x9f, 0x13, 0x11, 0x7e},
    {0x47, 0x74, 0x3d, 0x90, 0xaa, 0x3f, 0x51},
    {0xc6, 0x09, 0xd5, 0x9f, 0xfa, 0x66, 0xf9},
    {0xf3, 0xd6, 0xa1, 0x90, 0xa0, 0xf7, 0xf0},
    {0x1d, 0x95, 0xde, 0x9f, 0x84, 0x11, 0xf4},
    {0x0e, 0x74, 0xbb, 0x90, 0xbc, 0x3f, 0x92},
    {0x00, 0x09, 0x5b, 0x9f, 0x62, 0x66, 0xa1}
};

int processDecodeqmc(unsigned char* in, int len, unsigned char* out)
{
    int i = 0;
    Seed seed;
    for(i = 0; i < len; ++i)
    {
        out[i] = seed.NextMask() ^ in[i];
    }
    return i;
}

调用顺序

  1. qmc0,qmc3文件按字节流读取到in
  2. 调用processDecodeqmc解码in,解码到字节流out
  3. 把out存储为.mp3文件
//伪代码
FILE* fpIn = fopen("xx.qmc3", "rb");
FILE* fpOut= fopen("xx.mp3", "wb");
int   nSize = filesize;
char  in = new char[nSize];
char  out= new char[nSize];

int   nRead = 0, nOutLen;
while(fpIn != NULL && !feof(fpIn))
{
	nRead = fread(in, 1, nSize, fpIn);
	nOutLen = processDecodeqmc(in, nRead, out);
	fwrite(out, 1, nOutLen, fpOut);
}
fclose(fpIn);
fclose(fpOut);
delete[] in;
delete[] out;

您可能感兴趣的与本文相关的镜像

LobeChat

LobeChat

AI应用

LobeChat 是一个开源、高性能的聊天机器人框架。支持语音合成、多模态和可扩展插件系统。支持一键式免费部署私人ChatGPT/LLM 网络应用程序。

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值