Skip to content

Support for BCSTM files in themes - #60

Merged
coderkei merged 1 commit into
coderkei:mainfrom
tasken:bcstm-theme-music
Sep 23, 2026
Merged

coderkei merged 1 commit into
coderkei:mainfrom
tasken:bcstm-theme-music

Conversation

@tasken

@tasken tasken commented Sep 16, 2026

Copy link
Copy Markdown

Themes can now use bgm.bcstm for menu music: 3DS music files, mono or stereo, up to 48 kHz. Loop points stored in the file are used, so a track repeats past its intro instead of restarting. bgm.wav works exactly as before, and plays when a theme has no usable bgm.bcstm.

WAV handling moved into wavsource.cpp, and thememusic.cpp now just picks the source and keeps the same buffering.

Tested on a DSi using an Ace3DS+ and a DSpico.

@coderkei

coderkei commented Sep 17, 2026 •

Copy link
Copy Markdown
Owner

Whats the performance like?

I did test adding BCSTM support in the past but it would have clipping & slowdown in NTR mode (it also occurred in TWL mode to a lesser extent) since pre-calico DKA doesn't have proper threading like BlocksDS & newer Calico devkitarm does and Pico-Launcher's implementation relies on threading.

@tasken

tasken commented Sep 18, 2026

Copy link
Copy Markdown
Author

Decoding runs on the main loop without extra threads and buffers smoothly. Here's a demo on my DSi via an Ace3DS+ clone:

PXL_20260918_012932116.TS-10mb.mp4

Tested audio across various themes, and all of these work smoothly:

  1. Stereo, 48,000 Hz, 55.90 s, ~439 kbps (attached)
  2. Stereo, 44,100 Hz, 2.31 s, ~405 kbps
  3. Mono, 48,000 Hz, 31.45 s, ~219 kbps
  4. Stereo, 32,728 Hz, 8.65 s, ~299 kbps
  5. Stereo, 24,000 Hz, 120.60 s, ~219 kbps

@coderkei

Copy link
Copy Markdown
Owner

Thanks, tested it out and all looks good to go

@coderkei
coderkei merged commit e000f86 into coderkei:main Sep 23, 2026
1 check passed
@tasken
tasken deleted the bcstm-theme-music branch September 23, 2026 17:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants