# YuanGeTingLe - Audio Player
*You can also read a translated version of this file [in Chinese 简体中文版](README_CN.md).*
This is an audio player project based on PyQt5 and follows the MVC framework. The project was developed on Ubuntu 20.04 and supports playing songs in a specific folder, sequential playback, single-song loop, random playback, and other basic functions. Additionally, it implements the feature of variable playback speed.
- Project Repository: https://github.com/yuan2001425/yuanMusic
- Demo Video: https://www.bilibili.com/video/BV1aa4y1B7WW
- Blog Address: https://yuan425.blog.csdn.net/article/details/135234255
## Environment Setup
Use the following commands to create the virtual environment required for the project:
```bash
conda env create -f environment.yml
conda activate yuanMusic
```
## Run the Project
**1. Prepare Audio Files**
You can choose to create an empty `music` folder and add audio files yourself:
```bash
mkdir music
```
Alternatively, unzip the provided sample music (popular songs by Eason Chan):
> Link: https://pan.baidu.com/s/1EG0QBhtZ_KfbkuHmxejUeA?pwd=i9pz
>
> Extraction Code: i9pz
>
> --Shared from Baidu Cloud Super Member V5
```bash
unzip music.zip
```
**2. Configure Audio File Types (Optional)**
Open the `src/controller/controller.py` file.
Modify the `ALLOW_VOICE_TYPE` variable to allow playing other file types. The default is:
```python
ALLOW_VOICE_TYPE = [".mp3", ".wav"]
```
**3. Launch the Audio Player**
Run the following command in the terminal to start the audio player:
```bash
python main.py
```
## Features
- **Specify Folder for Playback:** Choose a specific folder to play songs only from that folder.
- **Playback Modes:** Support sequential playback, single-song loop, and random playback.
- **Variable Playback Speed:** Provide options for variable playback speed to accelerate or decelerate audio playback.
## Usage Instructions
1. **Launch the Application:**
- After opening the application, use the controls on the interface to select the playback mode and target folder.
- The system will automatically detect playable audio files in the directory and display them in the list.
- By default, the system will automatically play the first song in the playlist.
2. **Audio Playback Control:**
- Click the play button to play and pause audio.
- Adjust the audio playback progress easily by dragging the slider.
3. **Audio Switching and Adjustment:**
- Use the previous and next buttons or double-click on a song in the list to switch audio conveniently.
- Adjust loop mode and playback speed to meet personalized preferences.
4. **Exit the Application:**
- To exit the application, simply click the close button in the upper right corner of the window.
## Directory Structure
- **doc:** Related documents
- **music:** Sample music directory
- **src:** Source code
- **controller:** Control logic
- `controller.py`
- **model:** Audio model
- `model.py`
- **view:** Display interface
- **UI:** UI interface generated by QtDesigner
- `Widget.py`
- `Widget.ui`
- `view.py`: Personalized frontend
- `environment.yml`: Dependency installation
- `main.py`: Function entry point
- `README_CN.md`: Chinese project introduction
- `README.md`: English project introduction
## Notes
- Make sure Python 3.10 or above is installed.
- Before running the application, ensure that the environment is configured and the virtual environment is activated.
## Version Information
- Python Version: 3.10
- PyQt Version: 5.15
## Author Information
Author: `YuanGeTingLe` (CSDN/Bilibili/GitHub/WeChat Official Account with the same name)
For any questions or suggestions, please contact the author: `yuan2001425@163.com`
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
这是一个基于 PyQt5 的音频播放器项目,采用了 MVC 框架。该项目在 Ubuntu 20.04 下进行开发,可指定播放特定文件夹下的歌曲及顺序播放、单曲循环、随机播放等基本功能。此外,还实现了倍速播放功能。 项目地址:https://github.com/yuan2001425/yuanMusic 演示视频:https://www.bilibili.com/video/BV1aa4y1B7WW 博客地址:https://yuan425.blog.csdn.net/article/details/135234255
资源推荐
资源详情
资源评论
收起资源包目录
yuanMusic-master.zip (11个子文件)
yuanMusic-master
README_CN.md 3KB
doc
Python大作业.pdf 175KB
Python大作业格式模板n.docx 148KB
main.py 448B
src
controller
controller.py 9KB
view
view.py 283B
UI
Widget.py 5KB
Widget.ui 5KB
model
model.py 3KB
environment.yml 4KB
README.md 4KB
共 11 条
- 1
资源评论
远哥挺乐
- 粉丝: 1w+
- 资源: 21
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功