承接 bviguier/php-rtmidi 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

bviguier/php-rtmidi

Composer 安装命令:

composer require bviguier/php-rtmidi

包简介

Realtime MIDI input/output, thanks to RtMidi and FFI.

README 文档

README

Php library for realtime MIDI input/output, thanks to RtMidi and FFI.

Requirements

  • Php >=7.4 (for FFI support)
  • RtMidi v6 library compiled on your system.

Installation

composer require bviguier/php-rtmidi

On MacOS, you can install RtMidi globally thanks to brew.

brew install rtmidi

⚠️ In Linux, package registries often provide librtmidi.so.4 which is the version 3! To compile it manualy:

Features

  • Send midi messages (including system exclusive)
  • Receive midi messages (including system exclusive)
  • Create virtual input or output

Usage

If the RtMidi is not globally available on your system, you have to provide its path. By default, PhpRtMidi try to load the library by its standard name, but the name may depend on your OS or your build. You can also use LIB_RTMIDI_PATH environment variable to provide the path to the library.

This library doesn't match exactly original RtMidi interfaces, but try to expose a straightforward developer experience.

$browser = new \bviguier\RtMidi\MidiBrowser();

$input = $browser->openInput('My Input');
$output = $browser->openOutput('My Output');

echo "Midi thru enabled, use Ctr-C to exit…\n";
while (true) {
    if ($msg = $input->pullMessage()) {
        $output->send($msg);
    }
    usleep(100);
}

Check examples directory to have a better overview of its usage.

统计信息

  • 总下载量: 63
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-11-17

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固