Using Breakpoint Functions

Using Breakpoint functions (BPFs) in NoteAbilityPro

Breakpoint functions can be used to represent continuous control data which can be sent to MaxMSP or PD during score playback. In order to do this, NoteAbilityPro must be connected to MaxMSP through a network connection (either remotely or locally) and the staff on which the BPF is placed must be designated in the Track Setup panel as a network staff with the appropriate IP address specified in the Network Connections pane. Rather than being restricted to sending individual messages, the embedded BPF can send continuous data to the designated receiver.

1. Importing BLPs

  1. The file containing the BFP data must have the extension .bpf
  2. Drag the file onto an open NAPro score. The BFP will be attached to the nearest staff at the drop location. The domain of the BPF is automatically adjusted to the last X value in the BPF data.

2. Data Format of BPF files

  1. The minimum data format is a series of pairs of floating point numbers (or ints) separated by "white space" characters. These are read as the X and Y values of the BPF. A BPF message label of the form "message_#" is automatically generated and included in the BPF.

    0.0 0.5 23.0 0.75 45.0 0.35 100.0 1.0 200.0 0.0

  2. The BPF message label can be included in the first line of the BPF file – it should be a single continuous sequence of non-white-space characters.

    my_message 0.0 0.5 23.0 0.75 45.0 0.35 100.0 1.0 200.0 0.0

  3. The BFP may include multiple break point functions (to a maximum of 4.) In this case, the number of layers must be stated in the line after the message label using the format "numLayers #". In this format, the data should consists of 1 X value followed by # Y values.

    numLayers 3
    0.0 0.5 1.0 0.75
    23.0 0.75 0.88 0.21
    45.0 0.35 0.63 0.45
    100.0 1.0 0.44 0.03
    200.0 0.0 0.22 0.27

  4. Any of the above BPF formats may include markers at the end of BPF data list. The markers are separated by the string "markers". Markers are 2 numerical values (ints or floats) which are the startX and endX values of the marker followed by a marker name. The marker name should be a continuous series of non-white-space characters and may include quotation marks around it – these are ignored. Currently the endX value is not used, but it could be used later to represent a marker range.

    numLayers 3
    0.0 0.5 1.0 0.75
    23.0 0.75 0.88 0.21
    45.0 0.35 0.63 0.45
    100.0 1.0 0.44 0.03
    200.0 0.0 0.22 0.27
    55.0 55.0 marker1
    90.0 90.0 "marker2"
    126.0 126.0 marker_number_3

3. Moving and Adjusting the BPFs in NoteAbilityPro

  1. The BPF can be freely dragged around the score by choosing the Selection Tool from the Tool Palette, clicking in the body of the BPF, and dragging the mouse. The size of the BPF can be altered by clicking in and dragging the blue bar on the right side of the BPF. The starting beat location of the BPF is indicated in the top-left corner of the BPF (each measure starts at 0.0)
  2. BPFs can be selected, copied and pasted like any other NAPro image. In paste operations they are positioned with the left edge of the BPF at the Entry Cursor.
  3. It is also possible to adjust the position of the markers directly on the score. This is done by holding down the Option key while clicking on the red circle at the bottom of the marker and dragging the marker to a new location. The points in the BPF are adjusted as you move the markers.

4. Editing the BPF in NoteAblityPro

  1. BPFs can be selected in NAPro using the Selection tool from the tool palette and drawing a rectangle which includes the bottom-left corner of the BPF image. Once selected, the BPFs can be viewed in the BPF Editor which can be opened by selecting the BPF Editor… item in the Tools menu. Click on Load Next BPF button in the editor to load the selected BPF into the Editor. If you have selected more than 1 BPF, you can click on the Load Next BPF to load the next selected BPF into the editor. Once loaded, the message label, domain, range, y-Offset and all the points of the BPF should be displayed.

  2. The two buttons on the bottom right corner of the Editor compress and enlarge the editor view. The small coloured buttons in the top left corner of the Editor allow you to specify which layer of a multi-layered BPF is editable. The 4 colours refer to the colours of the BPFs (black, green, blue, gray) with the last one indicating that none of the BPFs are editable.
  3. You can alter the message label, domain, range or y-Offset (i.e. value of the bottom line of the graph) of the BPF by entering new values in the fields along the top of the editor window and typing Return. The BPF is re-displayed with the new graph values, but the actual points of the BPF are not altered.
  4. To alter the position of an existing point in the BPF, click the cursor onto the circle around the point and drag it, To remove an existing BPF, hold down the Shift key and click on the circle around the point. To enter new points click the cursor in an empty area of the window and drag the point into position. (N.B. Only 1 BPF of a multi-BPF can be editing at a time.)
  5. To add markers to a BPF, type the desired marker name into the field below the BPF, then hold the Option key down and click in the window. To remove a marker hold the Shift key down and click on the red circle at the bottom of the marker. To move a marker drag the red circle to the right or left. When you drag the markers, all point between the marker and previous and next markers are adjusted linearly. In the BPF below, the markers have been adjusted:

  6. To save the altered BPF, click on the Save Updated Data button and the original BPF in the NAPro score will be updated.
  7. To create a new BPF from scratch, clear the Existing BPF using the Clear BPF button. Then click on the New BPF to create a new empty BPF (with the indicated message label, domain, range and range Offset. Add points and markers to the BPF as described above. In the example below a new BPF has been created with two markers: new1 and new2.

  8. To enter the BPF into the score, click on the Paste BPF button. It will appear at the current location of the Entry Cursor in the score, where it can be moved and stretched.

5. Sending BPF Data to MaxMSP or PD

  • The staff on which the BPF is located must be designated as a network track. This is done through the >B?Track Setup… item in the Audio/MIDI menu. Click on the Network Setup button and enter the IP address and port that Max will be receiving data on. If it the same machine use localhost or the IP address and if you are using the netReceiverBP from the UBC Max/MSP toolbox, set the port to 3000 or 3001. If you are using the Pd netReceiver objects from the UBC Toolbox set the port to 3002 or 3003.

  • If you are not using the UBC Max/MSP Toolbox, then use the netreceive object set to receive UDP messages on the specified port. The UBC Toolbox can be downloaded from: Once you have setup your network connection in the Network setup panel, set each of the staves to connect to one of those channels by typing the network number (1-16) in the last field of the Track Setup panel. On the left side of the panel, set the pop-up menu of the desired staves to Net Message. In the example below, the top staff is an Apple DLS track and the remaining 2 tracks are being sent to Network connection 1 (which was set to localhost 3000).

  • During performance, the BPF data will be sent to a receive that corresponds to the message label in Max/MSP or Pd - in the example above, the data will be received by the Max/MSP or pd object [ receive my_message ] or [ r my_message ]. The markers will be sent as a bang to the receive of the same name [r marker 1] [ r marker2] and [ r maker_number_3 ]. In the case of a multiBPF, only the first BPF is sent out during performance in this version. A Max/MSP patch set to receive this data would look something like:

    See also

    © Keith A. Hamel 1998-2008 - All Rights Reserved