liblo: lo.h Source File

liblo 0.36

lo.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2014 Steve Harris et al. (see AUTHORS)
3 *
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public License
6 * as published by the Free Software Foundation; either version 2.1
7 * of the License, or (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU Lesser General Public License for more details.
13 *
14 * $Id$
15 */
16
17#ifndef LO_H
18#define LO_H
19
20#ifdef __cplusplus
21extern "C" {
22#endif
23
27
28#include "lo/lo_endian.h"
29#include "lo/lo_types.h"
30#include "lo/lo_osc_types.h"
31#include "lo/lo_errors.h"
32#include "lo/lo_lowlevel.h"
33#include "lo/lo_serverthread.h"
34
43
62 lo_address lo_address_new(const char *host, const char *port);
63
79 lo_address lo_address_new_with_proto(int proto, const char *host, const char *port);
80
86 lo_address lo_address_new_from_url(const char *url);
87
91 void lo_address_free(lo_address t);
92
103 void lo_address_set_ttl(lo_address t, int ttl);
104
111 int lo_address_get_ttl(lo_address t);
112
130 int lo_send(lo_address targ, const char *path, const char *type, ...);
131
165 int lo_send_from(lo_address targ, lo_server from, lo_timetag ts,
166 const char *path, const char *type, ...);
167
189 int lo_send_timestamped(lo_address targ, lo_timetag ts, const char *path,
190 const char *type, ...);
191
196 int lo_address_errno(lo_address a);
197
202 const char *lo_address_errstr(lo_address a);
203
211 lo_blob lo_blob_new(int32_t size, const void *data);
212
216 void lo_blob_free(lo_blob b);
217
223uint32_t lo_blob_datasize(lo_blob b);
224
231 void *lo_blob_dataptr(lo_blob b);
232
260 void lo_version(char *verstr, int verstr_size,
261 int *major, int *minor, char *extra, int extra_size,
262 int *lt_major, int *lt_minor, int *lt_bug);
263
265
266#include "lo/lo_macros.h"
267
268#ifdef __cplusplus
269}
270#endif
271
272#endif
lo_address_new_from_url
lo_address lo_address_new_from_url(const char *url)
Create a lo_address object from an OSC URL.
lo_address_get_ttl
int lo_address_get_ttl(lo_address t)
Get the Time-to-Live value for a given target address.
lo_address_errno
int lo_address_errno(lo_address a)
Return the error number from the last failed lo_send() or lo_address_new() call.
lo_send_timestamped
int lo_send_timestamped(lo_address targ, lo_timetag ts, const char *path, const char *type,...)
Send a OSC formatted message to the address specified, scheduled to be dispatch at some time in the f...
lo_address_free
void lo_address_free(lo_address t)
Free the memory used by the lo_address object.
lo_blob_free
void lo_blob_free(lo_blob b)
Free the memory taken by a blob.
lo_send_from
int lo_send_from(lo_address targ, lo_server from, lo_timetag ts, const char *path, const char *type,...)
Send a OSC formatted message to the address specified, from the same socket as the specified server.
lo_blob_datasize
uint32_t lo_blob_datasize(lo_blob b)
Return the amount of valid data in a lo_blob object.
lo_blob_dataptr
void * lo_blob_dataptr(lo_blob b)
Return a pointer to the start of the blob data to allow contents to be changed.
lo_address_set_ttl
void lo_address_set_ttl(lo_address t, int ttl)
Set the Time-to-Live value for a given target address.
lo_address_new_with_proto
lo_address lo_address_new_with_proto(int proto, const char *host, const char *port)
Declare an OSC destination, given IP address and port number, specifying protocol.
lo_version
void lo_version(char *verstr, int verstr_size, int *major, int *minor, char *extra, int extra_size, int *lt_major, int *lt_minor, int *lt_bug)
Get information on the version of liblo current in use.
lo_address_new
lo_address lo_address_new(const char *host, const char *port)
Declare an OSC destination, given IP address and port number. Same as lo_address_new_with_proto(),...
lo_send
int lo_send(lo_address targ, const char *path, const char *type,...)
Send a OSC formatted message to the address specified.
lo_address_errstr
const char * lo_address_errstr(lo_address a)
Return the error string from the last failed lo_send() or lo_address_new() call.
lo_blob_new
lo_blob lo_blob_new(int32_t size, const void *data)
Create a new OSC blob type.
lo_lowlevel.h
lo_osc_types.h
lo_serverthread.h
lo_types.h
lo_server
struct lo_server_ * lo_server
An object representing an instance of an OSC server.
Definition lo_types.h:85
lo_address
struct lo_address_ * lo_address
A reference to an OSC service.
Definition lo_types.h:45
lo_blob
struct lo_blob_ * lo_blob
A object to store an opaque binary data object.
Definition lo_types.h:52
lo_timetag
A structure to store OSC TimeTag values.
Definition lo_osc_types.h:35