toSf2

Converts this SBNK instrument bank to a SoundFont 2 (SF2) file.

The caller must supply the SWAR wave archives in slot order: wars[0] corresponds to bank slot 0, wars[1] to slot 1, etc. Unused slots (originally -1 in SdatSbnkFile.wars) should be null. The list must have exactly 4 elements (one per bank slot), matching the 0-3 wave-archive indices embedded in the SBNK binary's region data.

Return

A byte array containing the complete SF2 file.

Parameters

wars

Wave archives in bank-slot order (4 elements, null for unused slots).