音轨模块本质上是以编程方式建模、组织和排序的音频样本包。这个概念是在 20 世纪 80 年代引入的(主要与 Amiga 计算机相关),并从游戏开发和演示文化的早期就开始流行。
音轨模块文件在很多方面类似于 MIDI 文件。音轨是包含有关何时播放乐器以及音高和音量的信息的乐谱,并且由此可以重新创建原始乐曲的旋律和节奏。但是,MIDI 的缺点在于声音取决于音频硬件中可用的音库,因此 MIDI 音乐在不同的计算机上听起来可能不同。相比之下,音轨模块包括高质量的 PCM 样本,无论使用何种音频硬件,都能确保获得相似的体验。
Unity 支持四种最常见的模块文件格式,即 Impulse Tracker (.it)、Scream Tracker (.s3m)、扩展模块文件格式 (.xm) 和原始模块文件格式 (.mod)。
音轨模块文件不同于主流 PCM 格式(.aif、.wav、.mp3 和 .ogg)之处在于音轨模块文件可以非常小,但没有相应的音质损失。单个声音样本可以在音高和音量方面进行修改(并可应用其他效果),因此它基本上充当“乐器”,可以播放曲调,但不会产生将整个乐曲录制为样本的开销。因此,音轨模块适用于需要音乐但难以下载大型文件的游戏。
目前,创建和编辑音轨模块的最流行工具是适用于 OSX 的 MilkyTracker 和适用于 Windows 的 OpenMPT。有关更多信息和讨论,请参阅 2010 年 6 月发表的博客文章 Unity 中的 .mod (.mod in Unity)。
Did you find this page useful? Please give it a rating:
Thanks for rating this page!
What kind of problem would you like to report?
Thanks for letting us know! This page has been marked for review based on your feedback.
If you have time, you can provide more information to help us fix the problem faster.
Provide more information
You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:
You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:
You've told us there is information missing from this page. Please tell us more about what's missing:
You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:
You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:
You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:
You've told us this page has a problem. Please tell us more about what's wrong:
Thank you for helping to make the Unity documentation better!
Your feedback has been submitted as a ticket for our documentation team to review.
We are not able to reply to every ticket submitted.