pcount Instrument Control:Sensing and Control pcount pcount Returns the number of pfields belonging to a note event. Description pcount returns the number of pfields belonging to a note event. Syntax icount pcount Initialization icount - stores the number of pfields for the current note event. Note that the reported number of pfields is not necessarily what is explicitly written in the score, but the pfields available to the instrument through mechanisms like pfield carry. Examples Here is an example of the pcount opcode. It uses the file pcount.csd. Example of the pcount opcode. See the sections Real-time Audio and Command Line Flags for more information on using command line flags. The example will produce the following output: WARNING: instr 1 uses 3 p-fields but is given 8 B 0.000 .. 2.000 T 2.000 TT 2.000 M: 0.49966 0.49966 WARNING: instr 1 uses 3 p-fields but is given 10 B 2.000 .. 4.000 T 4.000 TT 4.000 M: 0.50000 0.50000 WARNING: instr 1 uses 3 p-fields but is given 10 B 4.000 .. 6.000 T 6.000 TT 6.000 M: 0.49943 0.49943 WARNING: instr 1 uses 3 p-fields but is given 6 B 6.000 .. 8.000 T 8.000 TT 8.000 M: 0.00000 0.00000 WARNING: instr 1 uses 3 p-fields but is given 20 B 8.000 .. 18.000 T 18.000 TT 18.000 M: 0.49994 0.49994 The warnings occur because pfields are not used explicitly by the instrument. See also Sensing and Control: Score control Credits Example by: Anthony Kozar Dec. 2006