Using wave reference waves in multithread statements

threadsafe Function/WAVE MapWaveRefWave(input, row)
    WAVE/WAVE input
    variable row

    return input[row]
End

Function DoStuff()

    Make/FREE/WAVE/N=2 refWave
   
    Make/FREE/N=(128) data1 = 100 + p
    Make/FREE/N=(128) data2 = 200 + p
   
    refWave[0] = data1
    refWave[1] = data2

    Make/FREE/N=(128) output

    Multithread output[][] = MapWaveRefWave(refWave, 0)[p] + MapWaveRefWave(refWave, 1)[p]
    print output
End

 

Forum

Support

Gallery

Igor Pro 9

Learn More

Igor XOP Toolkit

Learn More

Igor NIDAQ Tools MX

Learn More