python弹奏《起风了》
2023-12-31 18:37:13
代码是很大的!
其实就是python用ctypes调用Win API
import ctypes
import threading
import time
winmm = ctypes.windll.winmm
class Scale:
Rest = 0
C8 = 108
B7 = 107
A7s = 106
A7 = 105
G7s = 104
G7 = 103
F7s = 102
F7 = 101
E7 = 100
D7s = 99
D7 = 98
C7s = 97
C7 = 96
B6 = 95
A6s = 94
A6 = 93
G6s = 92
G6 = 91
F6s = 90
F6 = 89
E6 = 88
D6s = 87
D6 = 86
C6s = 85
C6 = 84
B5 = 83
A5s = 82
A5 = 81
G5s = 80
G5 = 79
F5s = 78
F5 = 77
E5 = 76
D5s = 75
D5 = 74
C5s = 73
C5 = 72
B4 = 71
A4s = 70
A4 = 69
G4s = 68
G4 = 67
F4s = 66
F4 = 65
E4 = 64
D4s = 63
D4 =
文章来源:https://blog.csdn.net/aqfcca/article/details/135317000
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。 如若内容造成侵权/违法违规/事实不符,请联系我的编程经验分享网邮箱:veading@qq.com进行投诉反馈,一经查实,立即删除!
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。 如若内容造成侵权/违法违规/事实不符,请联系我的编程经验分享网邮箱:veading@qq.com进行投诉反馈,一经查实,立即删除!