hosc-0.15: Haskell Open Sound Control

Safe HaskellNone
LanguageHaskell98

Sound.OSC.Coding.Encode.Builder

Description

Optimised encode function for OSC packets.

Synopsis

Documentation

build_packet :: Packet -> Builder Source

Builder monoid for an OSC Packet.

encodePacket :: Packet -> ByteString Source

Encode an OSC Packet to a lazy ByteString.

let b = L.pack [47,103,95,102,114,101,101,0,44,105,0,0,0,0,0,0]
in encodeOSC (Message "/g_free" [Int 0]) == b

encodePacket_strict :: Packet -> ByteString Source

Encode an Packet packet to a strict ByteString.