/ simulated_instruments / cymbal2
Sign in
simulated_instruments / cymbal2
cymbal2 / matlab / cymbal2_render.m
14 lines · 412 BBlameHistoryRaw
1function [y, dinfo] = cymbal2_render(P)
2% CYMBAL2_RENDER Full render: precompute -> time integration -> output.
4S = cymbal2_system(P);
5MB = cymbal2_mallet(P);
6[acc, dinfo] = cymbal2_sim(P, S, MB);
7[y, peakAccel] = cymbal2_output(P, acc);
9dinfo.peakAccel = peakAccel;
10dinfo.strikeRadiusM = S.strikeRadiusM;
11dinfo.pickupRadiusM = S.pickupRadiusM;
12dinfo.RsM = S.Rs;
13dinfo.lengthS = length(y) / P.sample_rate;
14end
↑↓ move↵openescclose