Skip to content

pd_protobuf

Contributors

People who contribute to this project.

Objects

  • pb_decode pb_decode decodes length-prefixed Protocol Buffers frames, such as byte lists from comport, and outputs one field <tag> <wire_type> <value> message per field plus an ok <nfields> or error <reason> status.
  • pb_encode pb_encode accumulates field <tag> <wire_type> <value...> messages and encodes them as length-prefixed Protocol Buffers bytes suitable for comport.
  • pb_int64_mod pb_int64_mod parses a decimal-integer symbol, or truncates a float to int64, then computes its mathematical modulus N and outputs a float in the range [0, N).
  • pb_int64_to_float pb_int64_to_float converts a decimal-integer symbol, such as a 64-bit field emitted by pb_decode, to a Pd t_float; float input passes through unchanged.
  • pb_now pb_now reads the host clock once on a bang and emits the same instant as Unix seconds (symbol), UTC seconds since midnight (float), and ISO-8601 UTC (symbol).
  • pb_timestamp pb_timestamp formats a google.protobuf.Timestamp {seconds, nanos} into an ISO-8601 UTC symbol and UTC seconds since midnight.
  • pb_unwrap pb_unwrap decodes a complete Protocol Buffers sub-message from a list of byte-valued floats (0–255), emitting each decoded field from its left outlet and an ok <nfields> or error <reason> status from its right outlet.
  • protobuf protobuf is an informational overview object for the pd_protobuf library, whose externals encode and decode Protocol Buffers in Pure Data with wire-format compatibility for nanopb, Google protobuf, and gRPC.