[chuck-users] STK instrument segmentation fault

John Ellinger info at mibac.com
Sun Sep 16 18:29:45 EDT 2012


Hi Ge,

We met at SLEO. I'm using the newest chuck version: 1.3.1.2 (chimera) mac os x : intel : 64-bit.

Re: FM sound 
Yes I recall reading a forum message that FM was an abstract class. Maybe a simple output message could inform users they need to subclass FM.

Re: Brass sound
I recorded and attached a small example of the Brass sound I get (BrassTest.mp3). To my ears it sounds distorted. (chuck code at end of email).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: BrassTest.mp3
Type: audio/mpeg
Size: 33853 bytes
Desc: not available
URL: <http://lists.cs.princeton.edu/pipermail/chuck-users/attachments/20120916/5ce14795/attachment-0001.mp3>
-------------- next part --------------


Re: Mandolin
ChucK plays correctly and seg faults when finished. This happens consistently on my MacPro.  Here's a portion of the crash log.
=============================================================
Process:         chuck [739]
Path:            /usr/local/bin/chuck
Identifier:      chuck
Version:         ??? (???)
Code Type:       X86-64 (Native)
Parent Process:  bash [645]

Date/Time:       2012-09-16 16:41:55.256 -0500
OS Version:      Mac OS X 10.7.4 (11E53)
Report Version:  9

Interval Since Last Report:          103887 sec
Crashes Since Last Report:           29
Per-App Crashes Since Last Report:   4
Anonymous UUID:                      ABA8BB91-CFBC-40A1-BD37-C0F836D908F5

Crashed Thread:  4  com.apple.audio.IOThread.client

Exception Type:  EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: 0x000000000000000d, 0x0000000000000000

VM Regions Near 0:
--> 
   __TEXT                 0000000100000000-00000001001b1000 [ 1732K] r-x/rwx SM=COW  /usr/local/bin/chuck

Application Specific Information:
objc[739]: garbage collection is OFF

Thread 0:: Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib        	0x00007fff85020e42 __semwait_signal + 10
1   libsystem_c.dylib             	0x00007fff86869dea nanosleep + 164
2   libsystem_c.dylib             	0x00007fff86869bb5 usleep + 53
3   chuck                         	0x0000000100045fca Chuck_VM::run() + 426
4   chuck                         	0x00000001000990ac main + 10924
5   chuck                         	0x00000001000017bd _start + 203
6   chuck                         	0x00000001000016f1 start + 33

Thread 1:: Dispatch queue: com.apple.libdispatch-manager
0   libsystem_kernel.dylib        	0x00007fff850217e6 kevent + 10
1   libdispatch.dylib             	0x00007fff8667f78a _dispatch_mgr_invoke + 923
2   libdispatch.dylib             	0x00007fff8667e31a _dispatch_mgr_thread + 54

Thread 2:
0   libsystem_kernel.dylib        	0x00007fff85020e42 __semwait_signal + 10
1   libsystem_c.dylib             	0x00007fff86869dea nanosleep + 164
2   libsystem_c.dylib             	0x00007fff86869bb5 usleep + 53
3   chuck                         	0x0000000100120dc1 _ZL7kb_loopPv + 113
4   libsystem_c.dylib             	0x00007fff868b38bf _pthread_start + 335
5   libsystem_c.dylib             	0x00007fff868b6b75 thread_start + 13

Thread 3:
0   libsystem_kernel.dylib        	0x00007fff8502047a __accept + 10
1   chuck                         	0x0000000100040982 ck_accept + 66
2   chuck                         	0x000000010009b252 otf_cb(void*) + 530
3   libsystem_c.dylib             	0x00007fff868b38bf _pthread_start + 335
4   libsystem_c.dylib             	0x00007fff868b6b75 thread_start + 13

Thread 4 Crashed:: com.apple.audio.IOThread.client
0   chuck                         	0x00000001000f2858 Mandolin::~Mandolin() + 56
1   chuck                         	0x00000001000d8813 Mandolin_dtor + 35
2   chuck                         	0x0000000100082244 Chuck_Object::~Chuck_Object() + 132
3   chuck                         	0x0000000100093be1 Chuck_UGen::~Chuck_UGen() + 33
4   chuck                         	0x00000001000491dd Chuck_VM_Shred::shutdown() + 317
5   chuck                         	0x0000000100048ee3 Chuck_VM_Shred::~Chuck_VM_Shred() + 35
6   chuck                         	0x0000000100048e8f Chuck_VM_Shred::~Chuck_VM_Shred() + 15
7   chuck                         	0x00000001000461be Chuck_VM::compute() + 206
8   chuck                         	0x0000000100046034 Chuck_VM::run(long) + 84
9   chuck                         	0x00000001000ac842 Digitalio::cb2(void*, void*, unsigned int, double, unsigned int, void*) + 434
10  chuck                         	0x00000001000b7316 RtApiCore::callbackEvent(unsigned int, AudioBufferList const*, AudioBufferList const*) + 358
11  chuck                         	0x00000001000b7197 callbackHandler(unsigned int, AudioTimeStamp const*, AudioBufferList const*, AudioTimeStamp const*, AudioBufferList*, AudioTimeStamp const*, void*) + 23
12  com.apple.audio.CoreAudio     	0x00007fff82ca59fa HALC_ProxyIOContext::IOWorkLoop() + 2058
13  com.apple.audio.CoreAudio     	0x00007fff82ca5151 HALC_ProxyIOContext::IOThreadEntry(void*) + 73
14  com.apple.audio.CoreAudio     	0x00007fff82ca500c HALB_IOThread::Entry(void*) + 78
15  libsystem_c.dylib             	0x00007fff868b38bf _pthread_start + 335
16  libsystem_c.dylib             	0x00007fff868b6b75 thread_start + 13
=============================================================

// Twinkle code with record function

Brass inst => dac => Gain g => WvOut w => blackhole;
"BrassTest.wav" => w.wavFilename;
0.5 => g.gain;
// Melody, Number Of Beats
[
[67.0, 1.0],
[67.0, 1.0],
[74.0, 1.0],
[74.0, 1.0],
[76.0, 1.0],
[76.0, 1.0],
[74.0, 2.0],
[72.0, 1.5],
[72.0, 0.5],
[71.0, 1.5],
[71.0, 0.5],
[69.0, 1.5],
[69.0, 0.5],
[67.0, 2.0]
] @=> float tune[][]; 
0 => int transpose; 
120 => int tempo; 
// Play phrase 1 
for( 0 => int i; i < tune.cap(); i++) {     
  Std.mtof( tune[i][0] + transpose ) => inst.freq;     
  inst.noteOn(1.0);     
  60000::ms *  tune[i][1] /  tempo  => now;     
  inst.noteOff(0); 
}    
w.closeFile;

John

John Ellinger                           email: info at mibac.com
MiBAC Music Software                    1019 College St.
Music Instruction By A Computer         Northfield MN 55057
http://www.mibac.com



More information about the chuck-users mailing list