Merge branch 'v0.01' of https://code.google.com/p/libremediaserver into v0.01
This commit is contained in:
commit
01e5bf35e7
61 changed files with 15873 additions and 0 deletions
94
CITPDefines.h
Normal file
94
CITPDefines.h
Normal file
|
@ -0,0 +1,94 @@
|
||||||
|
// -*- mode: C++ -*-
|
||||||
|
#ifndef _CITPDEFINES_H_
|
||||||
|
#define _CITPDEFINES_H_
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
//
|
||||||
|
// The CITP data structures and constants
|
||||||
|
//
|
||||||
|
|
||||||
|
//
|
||||||
|
// Datatypes
|
||||||
|
//
|
||||||
|
|
||||||
|
typedef qint8 int8;
|
||||||
|
typedef qint16 int16;
|
||||||
|
typedef qint32 int32;
|
||||||
|
typedef qint64 int64;
|
||||||
|
|
||||||
|
typedef quint8 uint8;
|
||||||
|
typedef quint16 uint16;
|
||||||
|
typedef quint32 uint32;
|
||||||
|
typedef quint64 uint64;
|
||||||
|
|
||||||
|
typedef QByteArray ucs1;
|
||||||
|
typedef QString ucs2;
|
||||||
|
|
||||||
|
//
|
||||||
|
// Content Type cookies
|
||||||
|
//
|
||||||
|
|
||||||
|
#define COOKIE_CITP 0x50544943 // 'CITP'
|
||||||
|
#define COOKIE_PINF 0x464e4950 // 'PINF'
|
||||||
|
#define COOKIE_PINF_PNAM 0x6d614e50 // 'PNam'
|
||||||
|
#define COOKIE_PINF_PLOC 0x636f4c50 // 'PLoc'
|
||||||
|
|
||||||
|
#pragma pack(1)
|
||||||
|
|
||||||
|
//
|
||||||
|
// CITP, Base Layer
|
||||||
|
//
|
||||||
|
struct CITP_Header
|
||||||
|
{
|
||||||
|
uint32 Cookie; // Set to "CITP".
|
||||||
|
uint8 VersionMajor; // Set to 1.
|
||||||
|
uint8 VersionMinor; // Set to 0.
|
||||||
|
uint8 Reserved[2]; // 4-byte alignment
|
||||||
|
uint32 MessageSize; // The size of the entire message, including this header.
|
||||||
|
uint16 MessagePartCount; // Number of message fragments.
|
||||||
|
uint16 MessagePart; // Index of this message fragment (0-based).
|
||||||
|
uint32 ContentType; // Cookie identifying the type of contents (the name of the second layer).
|
||||||
|
};
|
||||||
|
|
||||||
|
//
|
||||||
|
// CITP/PINF, Peer Information Layer
|
||||||
|
//
|
||||||
|
|
||||||
|
#define CITP_PINF_MULTICAST_IP "224.0.0.180"
|
||||||
|
#define CITP_PINF_MULTICAST_PORT 4809
|
||||||
|
#define TRANSMIT_INTERVAL_MS 5000
|
||||||
|
|
||||||
|
struct CITP_PINF_Header
|
||||||
|
{
|
||||||
|
CITP_Header CITPHeader; // The CITP header. CITP ContentType is "PINF".
|
||||||
|
uint32 ContentType; // A cookie defining which PINF message it is.
|
||||||
|
};
|
||||||
|
|
||||||
|
// DEPRECATED, USE PLoc instead
|
||||||
|
// Peer Name message
|
||||||
|
struct CITP_PINF_PNam
|
||||||
|
{
|
||||||
|
CITP_PINF_Header CITPPINFHeader; // The CITP PINF header. PINF ContentType is "PNam".
|
||||||
|
QByteArray Name; // The display name of the peer (null terminated).
|
||||||
|
// This could be anything from a
|
||||||
|
// user defined alias for the peer of the name of the
|
||||||
|
// product, or a combination.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Peer Location message
|
||||||
|
struct CITP_PINF_PLoc
|
||||||
|
{
|
||||||
|
CITP_PINF_Header CITPPINFHeader; // The CITP PINF header. PINF ContentType is "PLoc".
|
||||||
|
uint16 ListeningTCPPort; // The port on which the peer is listening for
|
||||||
|
// incoming TCP connections. 0 if not listening.
|
||||||
|
ucs1 Type[]; // Can be "LightingConsole", "MediaServer",
|
||||||
|
// "Visualizer" or "OperationHub".
|
||||||
|
ucs1 Name[]; // The display name of the peer. Corresponds to the
|
||||||
|
// PINF/PNam/Name field.
|
||||||
|
ucs1 State[]; // The display state of the peer. This can be any
|
||||||
|
// descriptive string presentable to the user such
|
||||||
|
// as "Idle", "Running" etc.
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#endif // _CITPDEFINES_H_
|
474
MSEXDefines.h
Normal file
474
MSEXDefines.h
Normal file
|
@ -0,0 +1,474 @@
|
||||||
|
#ifndef MSEXDEFINES_H
|
||||||
|
#define MSEXDEFINES_H
|
||||||
|
|
||||||
|
#include "CITPDefines.h"
|
||||||
|
#include <QObject>
|
||||||
|
|
||||||
|
///////////////////////////////////////////
|
||||||
|
//
|
||||||
|
// Defines
|
||||||
|
//
|
||||||
|
///////////////////////////////////////////
|
||||||
|
|
||||||
|
#define LISTENTCPPORT 4811
|
||||||
|
#define LAYER_NUMBER 0x08
|
||||||
|
#define TRANSMIT_INTERVAL_LSTA 1000
|
||||||
|
#define NAME "LibreMediaServer"
|
||||||
|
#define STATE "BetaTesting..."
|
||||||
|
#define UUID "aaaaaaaa-eeee-ffff-dddd-bbbbbbbbbbbb"
|
||||||
|
|
||||||
|
// Cookies
|
||||||
|
#define COOKIE_MSEX 0X5845534d // 'MSEX'
|
||||||
|
#define COOKIE_MSEX_CINF 0x666e4943 // 'CInf'
|
||||||
|
#define COOKIE_MSEX_SINF 0x666e4953 // 'SInf'
|
||||||
|
#define COOKIE_MSEX_NACK 0x6b63614e // 'Nack'
|
||||||
|
#define COOKIE_MSEX_LSTA 0x6174534c // 'LSta'
|
||||||
|
#define COOKIE_MSEX_GELI 0x494c4547 // GELI
|
||||||
|
#define COOKIE_MSEX_ELIN 0x6e494c45 // ELIn
|
||||||
|
#define COOKIE_MSEX_ELUP 0x71554c45 // ELUp
|
||||||
|
#define COOKIE_MSEX_GEIN 0x6e494547 // GEIn
|
||||||
|
#define COOKIE_MSEX_MEIN 0x6e49454d // MEIn
|
||||||
|
#define COOKIE_MSEX_EEIN 0x6e494545 // EEIn
|
||||||
|
#define COOKIE_MSEX_GLEI 0x49454c47 // GLEI
|
||||||
|
#define COOKIE_MSEX_GELT 0x544c4547 // GELT
|
||||||
|
#define COOKIE_MSEX_ELTH 0x68544c45 // ELTh
|
||||||
|
#define COOKIE_MSEX_GETH 0x68544547 // GETh
|
||||||
|
#define COOKIE_MSEX_ETHN 0x6e685445 // EThn
|
||||||
|
#define COOKIE_MSEX_GVSR 0x72535647 // GVsr
|
||||||
|
#define COOKIE_MSEX_VSRC 0x63725356 // VSrc
|
||||||
|
#define COOKIE_MSEX_RQST 0x74537152 // RqSt
|
||||||
|
#define COOKIE_MSEX_STFR 0x72467453 // StFr
|
||||||
|
|
||||||
|
//////////////////////////////////////////////
|
||||||
|
// //
|
||||||
|
// Estructuras auxiliares //
|
||||||
|
// //
|
||||||
|
//////////////////////////////////////////////
|
||||||
|
// Estructura Layer Status V1.0
|
||||||
|
struct LayerStatus {
|
||||||
|
|
||||||
|
quint8 LayerNumber;
|
||||||
|
quint8 PhysicalOutput;
|
||||||
|
quint8 MediaLibraryNumber;
|
||||||
|
quint8 MediaNumber;
|
||||||
|
QString Name;
|
||||||
|
quint32 MediaPosition;
|
||||||
|
quint32 MediaLength;
|
||||||
|
quint8 MediaFPS;
|
||||||
|
quint32 LayerStatusFlags;
|
||||||
|
};
|
||||||
|
|
||||||
|
// Estructura Media Library ID. MSex 1.1
|
||||||
|
struct MSEXLibraryId {
|
||||||
|
quint8 Level; // 0 - 3
|
||||||
|
quint8 Level1; // Sublevel 1 specifier, when Depth >= 1.
|
||||||
|
quint8 Level2; // Sublevel 2 specifier, when Depth >= 2.
|
||||||
|
quint8 Level3; // Sublevel 3 specifier, when Depth == 3.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Media Information for MELIn packages. v1.0
|
||||||
|
struct MediaInformation {
|
||||||
|
uint8 Number; // 0-based contiguous index of the media.
|
||||||
|
// uint32 SerialNumber; //MSEX 1.2
|
||||||
|
uint8 DMXRangeMin;// DMX range start value.
|
||||||
|
uint8 DMXRangeMax;// DMX range end value.
|
||||||
|
QString MediaName;// Media name.
|
||||||
|
uint64 MediaVersionTimestamp;// Media version in seconds since 1st January 1970.
|
||||||
|
uint16 MediaWidth; // Media width.
|
||||||
|
uint16 MediaHeight;// Media height.
|
||||||
|
uint32 MediaLength;// Media length (in frames).
|
||||||
|
uint8 MediaFPS;// Media resolution (in frames per second).
|
||||||
|
};
|
||||||
|
|
||||||
|
// Media Library for ELin packages v1.0
|
||||||
|
struct MediaLibrary {
|
||||||
|
quint8 m_Id; // Library id.
|
||||||
|
quint8 m_DMXRangeMin;// DMX range start value.
|
||||||
|
quint8 m_DMXRangeMax;// DMX range end value.
|
||||||
|
QString m_Name;// Library name.
|
||||||
|
// quint8 m_LibraryCount;// Number of sub libraries in the library. MSEX 1.2
|
||||||
|
quint8 m_ElementCount;// Number of elements in the library.
|
||||||
|
QList<MediaInformation> m_MediaInformation; // Pointer to the Medias Information List of this Library
|
||||||
|
};
|
||||||
|
|
||||||
|
// for ELUP
|
||||||
|
struct AffectedItems
|
||||||
|
{
|
||||||
|
uint8 ItemSet[32]; // A set of 256 bits used to indicate which item numbers have been changed
|
||||||
|
};
|
||||||
|
|
||||||
|
//////////////////////////////////////////////
|
||||||
|
// //
|
||||||
|
// Estructuras de paquetes //
|
||||||
|
// //
|
||||||
|
//////////////////////////////////////////////
|
||||||
|
|
||||||
|
// MSEX Header
|
||||||
|
struct CITP_MSEX_Header
|
||||||
|
{
|
||||||
|
CITP_Header CITPHeader; // The CITP header. CITP ContentType is "MSEX".
|
||||||
|
uint8 VersionMajor;
|
||||||
|
uint8 VersionMinor;
|
||||||
|
uint32 ContentType; // A cookie defining which MSEX message it is.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Mensaje para solicitar una conexión
|
||||||
|
struct CITP_MSEX_CInf
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "CInf". Version is 1.2.
|
||||||
|
uint8 SupportedMSEXVersionsCount; // Number of following MSEX version pairs.
|
||||||
|
uint16 SupportedMSEXVersions[]; // Each 2 byte value is MSB = major MSEX version, LSB = minor MSEX version.
|
||||||
|
uint FutureMessageData[]; // A hint that future versions of this message may contain trailing data.
|
||||||
|
};
|
||||||
|
|
||||||
|
// SInf Versiones 1.0 y 1.1. Send after connection established
|
||||||
|
struct CITP_MSEX_10_SINF
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "SInf". Version is set to 1.0.
|
||||||
|
// ucs2 ProductName;// Display name of the product.
|
||||||
|
uint8 ProductVersionMajor;// Major version number of the product.
|
||||||
|
uint8 ProductVersionMinor;// Minor version number of the product.
|
||||||
|
uint8 LayerCount;// Number of following layer information blocks.
|
||||||
|
/* struct LayerInformation
|
||||||
|
{
|
||||||
|
ucs1 DMXSource[];// DMX-source connection string. See DMX Connection Strings in Definitions.
|
||||||
|
};*/
|
||||||
|
};
|
||||||
|
|
||||||
|
// SInf V1.2 Send after CINf received
|
||||||
|
struct CITP_MSEX_12_SINF
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "SInf". Version is at least 1.2
|
||||||
|
//and is the highest common version supported by both server and client.
|
||||||
|
QByteArray uuid; // A standard 36 character UUID that uniquely identifies this media server
|
||||||
|
QString ProductName; // Display name of the product.
|
||||||
|
uint8 ProductVersionMajor; // Major version number of the product.
|
||||||
|
uint8 ProductVersionMinor; // Minor version number of the product.
|
||||||
|
uint8 ProductVersionBugfix; // Bugfix version number of the product.
|
||||||
|
uint8 SupportedMSEXVersionsCount; // Number of following MSEX version pairs.
|
||||||
|
uint16 SupportedMSEXVersions; // Each 2 byte value is MSB = major MSEX version, LSB = minor MSEX version
|
||||||
|
uint16 SupportedLibraryTypes; // Bit-encoded flagword that identifies which library types are provided by
|
||||||
|
//the media server.
|
||||||
|
uint8 ThumbnailFormatsCount; // Number of following thumbnail format cookies
|
||||||
|
QByteArray ThumbnailFormats; // Must include "RGB8", but can also include "JPEG" and "PNG "
|
||||||
|
uint8 StreamFormatsCount; // Number of following stream format cookies
|
||||||
|
QByteArray StreamFormats; // Must include "RGB8", but can also include "JPEG" and "PNG "
|
||||||
|
uint8 LayerCount; // Number of following layer information blocks.
|
||||||
|
QString LayerInf;
|
||||||
|
};
|
||||||
|
|
||||||
|
// Nack Negative Acknowledge Message
|
||||||
|
struct CITP_MSEX_Nack
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "Nack" and version is 1.2.
|
||||||
|
uint32 ReceivedContentType; // MSEX message type of the message being NACKed (e.g. "GELT" if the Media
|
||||||
|
//Server does not support library thumbnails)
|
||||||
|
};
|
||||||
|
|
||||||
|
// Layer Status Message 1.0
|
||||||
|
struct CITP_MSEX_10_LSta
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "LSta" and version is 1.0.
|
||||||
|
uint8 LayerCount; // Number of following layer information blocks.
|
||||||
|
struct LayerStatus
|
||||||
|
{
|
||||||
|
uint8 LayerNumber; // 0-based layer number, corresponding to the layers reported in the SInf message.
|
||||||
|
uint8 PhysicalOutput; // Current physical video output index,0-based.
|
||||||
|
uint8 MediaLibraryNumber; // Current media library number.
|
||||||
|
uint8 MediaNumber; // Current media number.
|
||||||
|
ucs2 MediaName[]; // Current media name.
|
||||||
|
uint32 MediaPosition; // Current media position (in frames).
|
||||||
|
uint32 MediaLength; // Current media length (in frames).
|
||||||
|
uint8 MediaFPS; // Current media resolution in frames per second.
|
||||||
|
uint32 LayerStatusFlags; // Current layer status flags
|
||||||
|
// 0x0001 MediaPlaying
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
// Layer Status Message version 1.2
|
||||||
|
struct CITP_MSEX_12_LSta
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "LSta" and version is 1.2.
|
||||||
|
uint8 LayerCount; // Number of following layer information blocks.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Library v 1.0
|
||||||
|
struct CITP_MSEX_10_GELI
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "GELI" and version is 1.0.
|
||||||
|
uint8 LibraryType; // Content type requested.
|
||||||
|
uint8 LibraryCount; // Number of libraries requested, set to 0 when requesting all available.
|
||||||
|
uint8 LibraryNumbers[]; // Requested library numbers, none if LibraryCount is 0.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Library v1.1
|
||||||
|
struct CITP_MSEX_11_GELI
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "GELI" and version is 1.1.
|
||||||
|
uint8 LibraryType; // Content type requested.
|
||||||
|
MSEXLibraryId LibraryParentId; // Parent library id.
|
||||||
|
uint8 LibraryCount; // Number of libraries requested, set to 0 when requesting all available.
|
||||||
|
uint8 LibraryNumbers[]; // Requested library numbers, none if LibraryCount is 0.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Library v1.2
|
||||||
|
struct CITP_MSEX_12_GELI
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "GELI" and version is 1.2.
|
||||||
|
uint8 LibraryType; // Content type requested.
|
||||||
|
MSEXLibraryId LibraryParentId; // Parent library id.
|
||||||
|
uint16 LibraryCount; // Number of libraries requested, set to 0 when requesting all available.
|
||||||
|
uint8 LibraryNumbers[]; // Requested library numbers, none if LibraryCount is 0.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Elemnt Library Information v1.0
|
||||||
|
struct CITP_MSEX_ELIn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "ELIn" and version is 1.1.
|
||||||
|
uint8 LibraryType; // Content type requested.
|
||||||
|
uint8 LibraryCount;// Number of following element library information blocks.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Element Library Updated v1.2
|
||||||
|
struct CITP_MSEX_12_ELUp
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "ELUp" and version is 1.2.
|
||||||
|
uint8 LibraryType; // Content type of updated library.
|
||||||
|
MSEXLibraryId LibraryId; // Library that has been updated.
|
||||||
|
uint8 UpdateFlags; // Additional information flags.
|
||||||
|
// 0x01 Existing elements have been updated
|
||||||
|
// 0x02 Elements have been added or removed
|
||||||
|
// 0x04 Sub libraries have been updated
|
||||||
|
// 0x08 Sub libraries have been added or removed
|
||||||
|
// 0x10 All elements have been affected (ignore AffectedElements)
|
||||||
|
// 0x20 All sub libraries have been affected (ignore AffectedLibraris)
|
||||||
|
AffectedItems AffectedElements; // Which elements have been affected
|
||||||
|
AffectedItems AffectedLibraries; // Which sub-libraries have been affected
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Information v1.1
|
||||||
|
struct CITP_MSEX_11_GEIn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "GEIn" and version is 1.1.
|
||||||
|
uint8 LibraryType; // Content type requested.
|
||||||
|
MSEXLibraryId LibraryId; // Library for which to retrieve elements
|
||||||
|
uint8 ElementCount; // Number of elements for which information is requested, set to 0 when requesting all available.
|
||||||
|
uint8 ElementNumbers[]; // Numbers of the elements for which information is requested.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Information v1.0
|
||||||
|
struct CITP_MSEX_10_GEIn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "GEIn" and version is 1.1.
|
||||||
|
quint8 LibraryType; // Content type requested.
|
||||||
|
quint8 LibraryId; // Library for which to retrieve elements
|
||||||
|
quint8 ElementCount; // Number of elements for which information is requested, set to 0 when requesting all available.
|
||||||
|
quint8 ElementNumbers; // Numbers of the elements for which information is requested.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Media Element Information v1.0
|
||||||
|
struct CITP_MSEX_10_MEIn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "MEIn" and version is 1.0
|
||||||
|
quint8 LibraryId; // Library containing the media elements.
|
||||||
|
qint8 ElementCount; // Number of following Media Information structs.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Media Element Information v1.1
|
||||||
|
struct CITP_MSEX_11_MEIn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "MEIn" and version is 1.1.
|
||||||
|
MSEXLibraryId LibraryId; // Library containing the media elements.
|
||||||
|
qint8 ElementCount; // Number of following Media Information blocks.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Media Element Information v1.2
|
||||||
|
struct CITP_MSEX_12_MEIn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "MEIn" and version is 1.1.
|
||||||
|
MSEXLibraryId LibraryId; // Library containing the media elements.
|
||||||
|
uint16 ElementCount; // Number of following Media Information blocks.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Effect Element Information v1.2
|
||||||
|
struct CITP_MSEX_12_EEIn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "EEIn" and version is 1.1.
|
||||||
|
MSEXLibraryId LibraryId;// Library containing the effect elements.
|
||||||
|
uint16 ElementCount;// Number of following (effect) information blocks.
|
||||||
|
struct EffectInformation
|
||||||
|
{
|
||||||
|
uint8 ElementNumber;
|
||||||
|
uint32 SerialNumber;
|
||||||
|
uint8 DMXRangeMin;
|
||||||
|
uint8 DMXRangeMax;
|
||||||
|
ucs2 EffectName[];
|
||||||
|
uint8 EffectParameterCount;
|
||||||
|
ucs2 EffectParameterNames[]; // List of effect parameter names.
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
// Generic Element Informatio v1.2
|
||||||
|
struct CITP_MSEX_12_GLEI
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "GLEI" and version is 1.1.
|
||||||
|
MSEXLibraryId LibraryId;
|
||||||
|
uint8 ElementCount;
|
||||||
|
uint16 LibraryType;
|
||||||
|
struct GenericInformation
|
||||||
|
{
|
||||||
|
uint8 ElementNumber;
|
||||||
|
uint32 SerialNumber;
|
||||||
|
uint8 DMXRangeMin;
|
||||||
|
uint8 DMXRangeMax;
|
||||||
|
ucs2 Name[];
|
||||||
|
uint64 VersionTimestamp;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Libary Thumbnail
|
||||||
|
struct CITP_MSEX_12_GELT
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "GELT" and version is 1.2.
|
||||||
|
uint32 ThumbnailFormat;// Format of the thumbnail. Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 ThumbnailWidth;// Preferred thumbnail image width.
|
||||||
|
uint16 ThumbnailHeight;// Preferred thumbnail image height.
|
||||||
|
uint8 ThumbnailFlags;// Additional information flags.
|
||||||
|
// 0x01 Preserve aspect ratio of image (use width and height as maximum)
|
||||||
|
uint8 LibraryType;// 1 for Media, 2 for Effects.
|
||||||
|
uint16 LibraryCount;// Number of libraries requested, set to 0 when requesting all available.
|
||||||
|
MSEXLibraryId LibraryIds[];// Ids of the libraries requested, not present if LibraryCount is 0.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Element Library Thumbnail
|
||||||
|
struct CITP_MSEX_11_ELTh
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "ELTh" and version is 1.1.
|
||||||
|
uint8 LibraryType;// 1 for Media, 2 for Effects.
|
||||||
|
MSEXLibraryId LibraryId;// Id of the library that the thumbnail belongs to.
|
||||||
|
uint32 ThumbnailFormat;// Format of the thumbnail. Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 ThumbnailWidth;// Thumbnail width.
|
||||||
|
uint16 ThumbnailHeight;// Thumbnail height.
|
||||||
|
uint16 ThumbnailBufferSize;// Size of the thumbnail buffer.
|
||||||
|
uint8 ThumbnailBuffer;// Thumbnail image buffer.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Thumbnail v1.0
|
||||||
|
struct CITP_MSEX_10_GETh
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;
|
||||||
|
uint32 ThumbnailFormat; // Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 ThumbnailWidth;
|
||||||
|
uint16 ThumbnailHeight;
|
||||||
|
uint8 ThumbnailFlags; // Additional information flags. 0x01 Preserve aspect ratio of image (use width and height as maximum)
|
||||||
|
uint8 LibraryType; // 1 for Media, 2 for Effects.
|
||||||
|
uint8 LibraryNumber; // Number of the media's library.
|
||||||
|
uint8 ElementCount; // Number of medias for which information is requested, set to 0 when requesting all available.
|
||||||
|
uint8 ElementNumber; // The numbers of the requested elements.Not present if ElementCount is 0.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Element Thumbnail v1.2
|
||||||
|
struct CITP_MSEX_12_GETh
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "GETh" and version is 1.2.
|
||||||
|
uint32 ThumbnailFormat;// Format of the thumbnail.Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 ThumbnailWidth; //Preferred thumbnail image width.
|
||||||
|
uint16 ThumbnailHeight; // Preferred thumbnail image height.
|
||||||
|
uint8 ThumbnailFlags; // Additional information flags.
|
||||||
|
//0x01 Preserve aspect ratio of image (use width and height as maximum)
|
||||||
|
uint8 LibraryType; //1 for Media, 2 for Effects.
|
||||||
|
MSEXLibraryId LibraryId; //Id of the media's library.
|
||||||
|
uint16 ElementCount; // Number of medias for which information is requested, set to 0 when requesting all available.
|
||||||
|
uint8 ElementNumbers[]; //The numbers of the requested elements. Not present if ElementCount = 0. For MSEX 1.2 these are 0-based contiguous index values.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Element Thumbnail v1.0
|
||||||
|
struct CITP_MSEX_10_ETHN
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "EThn" and version is 1.1.
|
||||||
|
uint8 LibraryType;// 1 for Media, 2 for Effects.
|
||||||
|
uint8 LibraryId;// Id of the element's library.
|
||||||
|
uint8 ElementNumber;// Number of the element (For MSEX 1.2 this is a 0-based contiguous index value).
|
||||||
|
uint32 ThumbnailFormat;// Format of the thumbnail. Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 ThumbnailWidth;// Thumbnail width.
|
||||||
|
uint16 ThumbnailHeight;// Thumbnail height.
|
||||||
|
uint16 ThumbnailBufferSize;// Size of the thumbnail buffer.
|
||||||
|
// uint8 ThumbnailBuffer[];// Thumbnail image buffer.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Element Thumbnail v1.1
|
||||||
|
struct CITP_MSEX_11_EThn
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "EThn" and version is 1.1.
|
||||||
|
uint8 LibraryType;// 1 for Media, 2 for Effects.
|
||||||
|
MSEXLibraryId LibraryId;// Id of the element's library.
|
||||||
|
uint8 ElementNumber;// Number of the element (For MSEX 1.2 this is a 0-based contiguous index value).
|
||||||
|
uint32 ThumbnailFormat;// Format of the thumbnail. Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 ThumbnailWidth;// Thumbnail width.
|
||||||
|
uint16 ThumbnailHeight;// Thumbnail height.
|
||||||
|
uint16 ThumbnailBufferSize;// Size of the thumbnail buffer.
|
||||||
|
uint8 ThumbnailBuffer;// Thumbnail image buffer.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Get Video Sources
|
||||||
|
struct CITP_MSEX_GVSr
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader; // CITP MSEX header. MSEX ContentType is "GVSr".
|
||||||
|
};
|
||||||
|
|
||||||
|
// Video Sources
|
||||||
|
struct CITP_MSEX_VSRC
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "VSrc".
|
||||||
|
uint16 SourceCount;// Number of following source information blocks.
|
||||||
|
uint16 SourceIdentifier; // Source identifier.
|
||||||
|
};
|
||||||
|
struct SourceInformation
|
||||||
|
{
|
||||||
|
signed char SourceName[];// Display name of the source (ie "Output 1", "Layer 2", "Camera 1" etc).
|
||||||
|
uint8 PhysicalOutput;// If applicable, 0-based index designating the physical video output index. Otherwise 0xFF.
|
||||||
|
uint8 LayerNumber;// If applicable, 0-based layer number, corresponding to the layers reported in the SInf message. Otherwise 0xFF.
|
||||||
|
uint16 Flags;// Information flags.
|
||||||
|
// 0x0001 Without effects
|
||||||
|
uint16 Width;// Full width.
|
||||||
|
uint16 Height;// Full height.
|
||||||
|
};
|
||||||
|
|
||||||
|
// Request Stream
|
||||||
|
struct CITP_MSEX_RqSt
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// CITP MSEX header. MSEX ContentType is "RqSt".
|
||||||
|
uint16 SourceIdentifier;// Identifier of the source requested.
|
||||||
|
uint32 FrameFormat;// Requested frame format. Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 FrameWidth;// Preferred minimum frame width.
|
||||||
|
uint16 FrameHeight;// Preferred minimum frame height.
|
||||||
|
uint8 fps;// Preferred minimum frames per second.
|
||||||
|
uint8 Timeout;// Timeout in seconds (for instance 5 seconds, 0 to ask for only one frame).
|
||||||
|
};
|
||||||
|
|
||||||
|
// Stream Frame 1.0
|
||||||
|
struct CITP_MSEX_10_StFr
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// The CITP MSEX header. MSEX ContentType is "StFr".
|
||||||
|
uint16 SourceIdentifier;// Identifier of the frame's source.
|
||||||
|
uint32 FrameFormat;// Requested frame format. Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 FrameWidth;// Preferred minimum frame width.
|
||||||
|
uint16 FrameHeight;// Preferred minimum frame height.
|
||||||
|
uint16 FrameBufferSize;// Size of the frame image buffer.
|
||||||
|
// uint8 FrameBuffer[];// Frame image buffer.
|
||||||
|
};
|
||||||
|
// Stream Frame 1.2
|
||||||
|
struct CITP_MSEX_12_StFr
|
||||||
|
{
|
||||||
|
CITP_MSEX_Header CITPMSEXHeader;// The CITP MSEX header. MSEX ContentType is "StFr".
|
||||||
|
ucs1 MediaServerUUID[36];// Source media server UUID.
|
||||||
|
uint16 SourceIdentifier;// Identifier of the frame's source.
|
||||||
|
uint32 FrameFormat;// Requested frame format. Can be "RGB8" or "JPEG" (or "PNG " for MSEX 1.2 and up).
|
||||||
|
uint16 FrameWidth;// Preferred minimum frame width.
|
||||||
|
uint16 FrameHeight;// Preferred minimum frame height.
|
||||||
|
uint16 FrameBufferSize;// Size of the frame image buffer.
|
||||||
|
uint8 FrameBuffer[];// Frame image buffer.
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // MSEXDEFINES_H
|
||||||
|
|
486
PacketCreator.cpp
Normal file
486
PacketCreator.cpp
Normal file
|
@ -0,0 +1,486 @@
|
||||||
|
/*
|
||||||
|
Libre Media Server - A Media Server Sotfware for stage and performing
|
||||||
|
|
||||||
|
Copyright (C) 2012-2013 Santiago Noreña puremediaserver@gmail.com
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "PacketCreator.h"
|
||||||
|
//#include "PureMediaServer.h"
|
||||||
|
//#include "MediaServer.h"
|
||||||
|
#include "CITPDefines.h"
|
||||||
|
#include "MSEXDefines.h"
|
||||||
|
|
||||||
|
#include <QtDebug>
|
||||||
|
#include <QFileInfo>
|
||||||
|
#include <QFile>
|
||||||
|
#include <QDir>
|
||||||
|
|
||||||
|
PacketCreator::PacketCreator(QObject *parent)
|
||||||
|
: QObject(parent)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
PacketCreator::~PacketCreator()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
unsigned char * PacketCreator::createPLocPacket(
|
||||||
|
const QString &name,
|
||||||
|
const QString &state,
|
||||||
|
int &bufferLen)
|
||||||
|
{
|
||||||
|
qDebug() << "createPLOC" << name << state;
|
||||||
|
QString plocType = "MediaServer";
|
||||||
|
// figure out the packet size, all strings need to be NULL terminated
|
||||||
|
bufferLen = sizeof(struct CITP_PINF_PLoc) + plocType.size() + 1 + name.size() + 1 + state.size() + 1;
|
||||||
|
unsigned char *buffer = new unsigned char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_PINF_PLoc *packet = (CITP_PINF_PLoc*)buffer;
|
||||||
|
|
||||||
|
// CITP header
|
||||||
|
packet->CITPPINFHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPPINFHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPPINFHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPPINFHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPPINFHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPPINFHeader.CITPHeader.MessageSize = bufferLen;
|
||||||
|
packet->CITPPINFHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPPINFHeader.CITPHeader.MessagePart = 0x00; // XXX - doc says 0-based?
|
||||||
|
packet->CITPPINFHeader.CITPHeader.ContentType = COOKIE_PINF;
|
||||||
|
|
||||||
|
// PINF header
|
||||||
|
packet->CITPPINFHeader.ContentType = COOKIE_PINF_PLOC;
|
||||||
|
|
||||||
|
// PLoc data
|
||||||
|
packet->ListeningTCPPort = LISTENTCPPORT;
|
||||||
|
// type
|
||||||
|
int offset = sizeof(struct CITP_PINF_PLoc);
|
||||||
|
memcpy(buffer + offset, plocType.toAscii().constData(), plocType.size());
|
||||||
|
|
||||||
|
// name
|
||||||
|
offset += plocType.size() + 1;
|
||||||
|
memcpy(buffer + offset, name.toAscii().constData(), name.size());
|
||||||
|
|
||||||
|
// state
|
||||||
|
offset += name.size() + 1;
|
||||||
|
memcpy(buffer + offset, state.toAscii().constData(), state.size());
|
||||||
|
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Paquetes MSEX
|
||||||
|
|
||||||
|
unsigned char * PacketCreator::createSINFPacket(int &bufferLen)
|
||||||
|
{
|
||||||
|
// figure out the packet size
|
||||||
|
QString name = NAME;
|
||||||
|
bufferLen = 2*name.size() + 3 + sizeof(struct CITP_MSEX_10_SINF);
|
||||||
|
// create the buffer
|
||||||
|
unsigned char *buffer = new unsigned char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_10_SINF *packet = (CITP_MSEX_10_SINF *)buffer;
|
||||||
|
|
||||||
|
// CITP header
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessageSize = bufferLen;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePart = 0x00; // XXX - doc says 0-based?
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.ContentType = COOKIE_MSEX;
|
||||||
|
|
||||||
|
// MSEX header
|
||||||
|
packet->CITPMSEXHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.ContentType = COOKIE_MSEX_SINF;
|
||||||
|
|
||||||
|
// SInf content
|
||||||
|
int offset = sizeof(struct CITP_MSEX_Header);
|
||||||
|
const ushort * namei = name.utf16();
|
||||||
|
memcpy((buffer+offset), namei, 2*(name.size()));
|
||||||
|
offset = offset + 2*name.size() +2;
|
||||||
|
memset ((buffer+offset), 0x01,1);
|
||||||
|
offset++;
|
||||||
|
memset((buffer+offset), 0x00, 3);
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
unsigned char * PacketCreator::createLSTAPacket(layerList layerp,int &bufferLen)
|
||||||
|
{
|
||||||
|
// figure out the packet size
|
||||||
|
const quint8 layerCount = layerp.size();
|
||||||
|
int layerslen = 0;
|
||||||
|
LayerStatus layeri;
|
||||||
|
for (int i=0; i<layerCount; i++) {
|
||||||
|
layeri = layerp.at(i);
|
||||||
|
layerslen = layerslen + 2*layeri.Name.size() -4 + sizeof(struct LayerStatus);
|
||||||
|
}
|
||||||
|
int offset = sizeof(struct CITP_MSEX_10_LSta);
|
||||||
|
bufferLen = offset + layerslen;
|
||||||
|
unsigned char *buffer = new unsigned char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_10_LSta *packet;
|
||||||
|
packet = (CITP_MSEX_10_LSta *)buffer;
|
||||||
|
// CITP header
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessageSize = bufferLen;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePart = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.ContentType = COOKIE_MSEX;
|
||||||
|
|
||||||
|
// MSEX header
|
||||||
|
packet->CITPMSEXHeader.ContentType = COOKIE_MSEX_LSTA;
|
||||||
|
packet->CITPMSEXHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.VersionMinor = 0x00;
|
||||||
|
|
||||||
|
//LSTA
|
||||||
|
packet->LayerCount = layerCount;
|
||||||
|
|
||||||
|
// Convertimos las estructuras a unsigned char
|
||||||
|
unsigned char * buffer2 = new unsigned char[layerslen];
|
||||||
|
LayerStatus packet2;
|
||||||
|
for (int i=0; i<layerCount;i++)
|
||||||
|
{
|
||||||
|
int offset2 =0;
|
||||||
|
memset(buffer2, 0x00, layerslen);
|
||||||
|
packet2 = layerp.at(i);
|
||||||
|
memcpy(buffer2, &packet2.LayerNumber,1);
|
||||||
|
offset2++;
|
||||||
|
memcpy((buffer2+offset2), &packet2.PhysicalOutput,1);
|
||||||
|
offset2++;
|
||||||
|
memcpy((buffer2+offset2), &packet2.MediaLibraryNumber,1);
|
||||||
|
offset2++;
|
||||||
|
memcpy((buffer2+offset2), &packet2.MediaNumber,1);
|
||||||
|
offset2++;
|
||||||
|
const ushort * name = packet2.Name.utf16();
|
||||||
|
memcpy((buffer2+offset2), name, 2*packet2.Name.size());
|
||||||
|
offset2 = offset2 + 2*packet2.Name.size() +2;
|
||||||
|
memcpy((buffer2+offset2), &packet2.MediaPosition,4);
|
||||||
|
offset2 = offset2 + 4;
|
||||||
|
memcpy((buffer2+offset2), &packet2.MediaLength,4);
|
||||||
|
offset2 = offset2 + 4;
|
||||||
|
memcpy((buffer2+offset2), &packet2.MediaFPS,1);
|
||||||
|
offset2 = offset2 + 1;
|
||||||
|
memcpy((buffer2+offset2), &packet2.LayerStatusFlags,4);
|
||||||
|
offset2 = offset2 + 4;
|
||||||
|
memcpy((buffer+offset), buffer2, offset2);
|
||||||
|
offset = offset + offset2;
|
||||||
|
}
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
unsigned char * PacketCreator::createELINPacket(QList <MediaLibrary> medialib, int&bufferLen)
|
||||||
|
{
|
||||||
|
// Vemos el tamaño total de la estructurta
|
||||||
|
MediaLibrary mediai;
|
||||||
|
int medialen = 0;
|
||||||
|
int size = 0;
|
||||||
|
int i;
|
||||||
|
for (i=0; i<medialib.size(); i++)
|
||||||
|
{
|
||||||
|
mediai = medialib.at(i);
|
||||||
|
size = sizeof(mediai) + 2*mediai.m_Name.size() +2 -sizeof(mediai.m_Name) -sizeof(mediai.m_MediaInformation);
|
||||||
|
medialen = medialen + size;
|
||||||
|
}
|
||||||
|
int offset = sizeof(struct CITP_MSEX_ELIn);
|
||||||
|
bufferLen = offset + medialen;
|
||||||
|
unsigned char *buffer = new unsigned char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_ELIn *packet = (CITP_MSEX_ELIn *)buffer;
|
||||||
|
|
||||||
|
// CITP header
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessageSize = bufferLen;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePart = 0x00; // XXX - doc says 0-based?
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.ContentType = COOKIE_MSEX;
|
||||||
|
|
||||||
|
// MSEX header
|
||||||
|
packet->CITPMSEXHeader.ContentType = COOKIE_MSEX_ELIN;
|
||||||
|
packet->CITPMSEXHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.VersionMinor = 0x00;
|
||||||
|
|
||||||
|
// ELin Content
|
||||||
|
packet->LibraryType = 0x01;
|
||||||
|
packet->LibraryCount = medialib.size();
|
||||||
|
// Element Library Information
|
||||||
|
unsigned char *buffer2 = new unsigned char[medialen];
|
||||||
|
for (i=0; i<medialib.size(); i++)
|
||||||
|
{
|
||||||
|
memset(buffer2, 0, medialen);
|
||||||
|
int offset2 = 0;
|
||||||
|
mediai = medialib.at(i);
|
||||||
|
memcpy (buffer2, &mediai.m_Id, 1);
|
||||||
|
offset2++;
|
||||||
|
memcpy ((buffer2+offset2), &mediai.m_DMXRangeMin,1);
|
||||||
|
offset2++;
|
||||||
|
memcpy((buffer2 +offset2), &mediai.m_DMXRangeMax,1);
|
||||||
|
offset2++;
|
||||||
|
const ushort * name = mediai.m_Name.utf16();
|
||||||
|
memcpy((buffer2+offset2), name, (2*mediai.m_Name.size()));
|
||||||
|
offset2 = 2+ offset2 + 2*mediai.m_Name.size();
|
||||||
|
memcpy((buffer2+offset2), &mediai.m_ElementCount, 1);
|
||||||
|
offset2++;
|
||||||
|
memcpy((buffer+offset), buffer2, offset2);
|
||||||
|
offset = offset + offset2;
|
||||||
|
}
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
unsigned char * PacketCreator::createMEINPacket(MediaLibrary medialib, int &bufferLen)
|
||||||
|
{
|
||||||
|
// Vemos el tamaño total de la estructurta
|
||||||
|
MediaLibrary mediai = medialib;
|
||||||
|
QList<MediaInformation> mediainflist = mediai.m_MediaInformation;
|
||||||
|
MediaInformation mediainf;
|
||||||
|
int medialen = 0;
|
||||||
|
int size = 0;
|
||||||
|
int i;
|
||||||
|
for (i=0; i<mediainflist.size(); i++)
|
||||||
|
{
|
||||||
|
mediainf = mediainflist.at(i);
|
||||||
|
size = 2 + sizeof(mediainf) +2*mediainf.MediaName.size() - sizeof(mediainf.MediaName);
|
||||||
|
medialen = medialen + size;
|
||||||
|
}
|
||||||
|
|
||||||
|
int offset = sizeof(struct CITP_MSEX_10_MEIn);
|
||||||
|
bufferLen = offset + medialen;
|
||||||
|
unsigned char *buffer = new unsigned char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_10_MEIn *packet = (CITP_MSEX_10_MEIn *)buffer;
|
||||||
|
|
||||||
|
// CITP header
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessageSize = bufferLen;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePart = 0x00; // XXX - doc says 0-based?
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.ContentType = COOKIE_MSEX;
|
||||||
|
|
||||||
|
// MSEX header
|
||||||
|
packet->CITPMSEXHeader.ContentType = COOKIE_MSEX_MEIN;
|
||||||
|
packet->CITPMSEXHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.VersionMinor = 0x00;
|
||||||
|
|
||||||
|
// MEIn Header
|
||||||
|
packet->LibraryId = mediai.m_Id;
|
||||||
|
packet->ElementCount = mediainflist.size();
|
||||||
|
// MEIn Data
|
||||||
|
unsigned char * buffer2 = new unsigned char[medialen];
|
||||||
|
for (i=0; i<mediainflist.size();i++){
|
||||||
|
memset(buffer2, 0,medialen);
|
||||||
|
int offset2 = 0;
|
||||||
|
mediainf = mediainflist.at(i);
|
||||||
|
memcpy(buffer2, &mediainf.Number, 1);
|
||||||
|
offset2= offset2 + 1;
|
||||||
|
memcpy((buffer2 + offset2),&mediainf.DMXRangeMin,1);
|
||||||
|
offset2= offset2 + 1;
|
||||||
|
memcpy((buffer2+offset2), &mediainf.DMXRangeMax ,1 );
|
||||||
|
offset2= offset2 + 1;
|
||||||
|
const ushort * name = mediainf.MediaName.utf16();
|
||||||
|
memcpy((buffer2+offset2), name, 2*mediainf.MediaName.size());
|
||||||
|
offset2 = 2 + offset2 + 2*mediainf.MediaName.size();
|
||||||
|
memcpy ((buffer2 + offset2), &mediainf.MediaVersionTimestamp, 8);
|
||||||
|
offset2= offset2 + 8;
|
||||||
|
memcpy((buffer2+offset2), &mediainf.MediaWidth,2);
|
||||||
|
offset2= offset2 + 2;
|
||||||
|
memcpy((buffer2+offset2), &mediainf.MediaHeight,2);
|
||||||
|
offset2= offset2 + 2;
|
||||||
|
memcpy((buffer2+offset2), &mediainf.MediaLength,4);
|
||||||
|
offset2= offset2 + 4;
|
||||||
|
memcpy((buffer2+offset2), &mediainf.MediaFPS,1);
|
||||||
|
offset2= offset2 + 1;
|
||||||
|
memcpy((buffer+offset), buffer2, offset2);
|
||||||
|
offset = offset + offset2;
|
||||||
|
}
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
unsigned char * PacketCreator::createETHNPacket(QString path,MediaLibrary medialib, int elementnumber, int &bufferLen)
|
||||||
|
{
|
||||||
|
QDir dir(path);
|
||||||
|
QFileInfo fileInfo;
|
||||||
|
QFileInfoList filelist;
|
||||||
|
if (medialib.m_Name == "image"){
|
||||||
|
dir.setFilter(QDir::Files);
|
||||||
|
dir.cd("image");
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
dir.cd("video");
|
||||||
|
dir.setFilter(QDir::Dirs | QDir::NoSymLinks | QDir::NoDotAndDotDot);
|
||||||
|
filelist = dir.entryInfoList();
|
||||||
|
fileInfo = filelist.at(medialib.m_Id);
|
||||||
|
dir.cd(fileInfo.baseName());
|
||||||
|
dir.setFilter(QDir::Files);
|
||||||
|
}
|
||||||
|
dir.cd("thumbs");
|
||||||
|
filelist = dir.entryInfoList();
|
||||||
|
if (filelist.size() > elementnumber){
|
||||||
|
fileInfo = filelist.at(elementnumber);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
QFile file(fileInfo.filePath());
|
||||||
|
if (!file.open(QIODevice::ReadOnly)){
|
||||||
|
qDebug() << "Cannot open the file"<<fileInfo.filePath();
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
unsigned char * bufferthumb = new unsigned char[file.size()];
|
||||||
|
memset(bufferthumb, 0, file.size());
|
||||||
|
bufferthumb = file.map(0x00, file.size());
|
||||||
|
if (bufferthumb == 0){
|
||||||
|
qDebug() << "Cannot map the file";
|
||||||
|
}
|
||||||
|
bufferLen = sizeof(struct CITP_MSEX_10_ETHN) + file.size();
|
||||||
|
unsigned char * buffer = new unsigned char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_10_ETHN *packet = (CITP_MSEX_10_ETHN *)buffer;
|
||||||
|
// CITP header
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessageSize = bufferLen;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePart = 0x00; // XXX - doc says 0-based?
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.ContentType = COOKIE_MSEX;
|
||||||
|
// Mandamos el paquete
|
||||||
|
|
||||||
|
// MSEX header
|
||||||
|
packet->CITPMSEXHeader.ContentType = COOKIE_MSEX_ETHN;
|
||||||
|
packet->CITPMSEXHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.VersionMinor = 0x00;
|
||||||
|
|
||||||
|
//ETHN Content
|
||||||
|
packet->LibraryType = 0x01;
|
||||||
|
packet->LibraryId = medialib.m_Id;
|
||||||
|
packet->ElementNumber = elementnumber;
|
||||||
|
packet->ThumbnailFormat = 0x4745504A; // JPEG
|
||||||
|
packet->ThumbnailWidth = 60;
|
||||||
|
packet->ThumbnailHeight = 46;
|
||||||
|
packet->ThumbnailBufferSize = file.size();
|
||||||
|
|
||||||
|
// Thumbnail
|
||||||
|
int offset = sizeof(struct CITP_MSEX_10_ETHN);
|
||||||
|
memcpy((buffer+offset), bufferthumb, file.size());
|
||||||
|
file.close();
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
unsigned char * PacketCreator::createNACKPacket(quint32 cookie, int &bufferLen)
|
||||||
|
{
|
||||||
|
bufferLen = sizeof(struct CITP_MSEX_Nack);
|
||||||
|
unsigned char *buffer = new unsigned char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_Nack *packet;
|
||||||
|
packet = (CITP_MSEX_Nack *)buffer;
|
||||||
|
packet->ReceivedContentType = cookie;
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Video Stream
|
||||||
|
|
||||||
|
const char * PacketCreator::createVSRCPacket(int &bufferLen)
|
||||||
|
{
|
||||||
|
QString name("Output 1");
|
||||||
|
bufferLen = sizeof(struct CITP_MSEX_VSRC) + 2*name.size() + 10;
|
||||||
|
// create the buffer
|
||||||
|
char *buffer = new char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_VSRC *packet = (CITP_MSEX_VSRC *)buffer;
|
||||||
|
|
||||||
|
// CITP header
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessageSize = bufferLen;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePart = 0x00; // XXX - doc says 0-based?
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.ContentType = COOKIE_MSEX;
|
||||||
|
// MSEX header
|
||||||
|
packet->CITPMSEXHeader.ContentType = COOKIE_MSEX_VSRC;
|
||||||
|
packet->CITPMSEXHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.VersionMinor = 0x00;
|
||||||
|
packet->SourceCount = 0x01;
|
||||||
|
// VSRC Information
|
||||||
|
packet->SourceIdentifier = 0x01;
|
||||||
|
int offset = sizeof(struct CITP_MSEX_VSRC);
|
||||||
|
const ushort * namei = name.utf16();
|
||||||
|
memcpy((buffer+offset), namei, 2*(name.size()));
|
||||||
|
offset = offset + 2*name.size() +2;
|
||||||
|
QByteArray post;
|
||||||
|
post[0] = 0xFF; // Physical Ouput uint8
|
||||||
|
post[1] = 0xFF; // Layer Number uint8
|
||||||
|
post[2] = 0x00; // Flags uint16
|
||||||
|
post[3] = 0x00;
|
||||||
|
post[4] = 0x00; // Width uint16
|
||||||
|
post[5] = 0x40;
|
||||||
|
post[6] = 0x00; // Height uint16
|
||||||
|
post[7] = 0x2E;
|
||||||
|
memcpy((buffer+offset), post, post.size());
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
/* This will be the send frme for CITP/MSEx 1.1 in the CITP Socket. 1.0 uses the TCP Socket in msex class
|
||||||
|
const char * PacketCreator::createFrame(uchar *frame, int &bufferLen)
|
||||||
|
{
|
||||||
|
int bufferLenTot = sizeof(struct CITP_MSEX_10_StFr ) + bufferLen;
|
||||||
|
char * buffer = new char[bufferLen];
|
||||||
|
memset(buffer, 0, bufferLen);
|
||||||
|
CITP_MSEX_10_StFr *packet = (CITP_MSEX_10_StFr *)buffer;
|
||||||
|
// CITP header
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Cookie = COOKIE_CITP;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.VersionMinor = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[0] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.Reserved[1] = 0x00;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessageSize = bufferLenTot;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePartCount = 0x01;
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.MessagePart = 0x00; // XXX - doc says 0-based?
|
||||||
|
packet->CITPMSEXHeader.CITPHeader.ContentType = COOKIE_MSEX;
|
||||||
|
// MSEX header
|
||||||
|
packet->CITPMSEXHeader.ContentType = COOKIE_MSEX_STFR;
|
||||||
|
packet->CITPMSEXHeader.VersionMajor = 0x01;
|
||||||
|
packet->CITPMSEXHeader.VersionMinor = 0x00;
|
||||||
|
//STFR Content
|
||||||
|
packet->FrameBufferSize = bufferLen;
|
||||||
|
packet->FrameFormat = 943867730;
|
||||||
|
packet->FrameHeight = 64;
|
||||||
|
packet->FrameWidth = 88;
|
||||||
|
packet->SourceIdentifier = 0x0001;
|
||||||
|
// Copiamos los datos del thumbnail
|
||||||
|
int offset = sizeof(struct CITP_MSEX_10_StFr);
|
||||||
|
memcpy((buffer+offset), frame, bufferLen);
|
||||||
|
bufferLen = bufferLenTot;
|
||||||
|
return buffer;
|
||||||
|
}
|
||||||
|
*/
|
62
PacketCreator.h
Normal file
62
PacketCreator.h
Normal file
|
@ -0,0 +1,62 @@
|
||||||
|
// -*- mode: C++ -*-
|
||||||
|
/*
|
||||||
|
Libre Media Server - A Media Server Sotfware for stage and performing
|
||||||
|
Copyright (C) 2012 -2013 Santiago Noreña
|
||||||
|
belfegor <AT> gmail <DOT> com
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* Makes all CITP/MSEx packets */
|
||||||
|
|
||||||
|
#ifndef _PACKETCREATOR_H_
|
||||||
|
#define _PACKETCREATOR_H_
|
||||||
|
|
||||||
|
#include "MSEXDefines.h"
|
||||||
|
#include <QObject>
|
||||||
|
|
||||||
|
typedef QList<LayerStatus> layerList;
|
||||||
|
class PacketCreator : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
PacketCreator(QObject *parent=0);
|
||||||
|
virtual ~PacketCreator();
|
||||||
|
|
||||||
|
// CITP
|
||||||
|
|
||||||
|
// returns NULL on error. bufferLen is the length of the returned buffer.
|
||||||
|
static unsigned char * createPLocPacket(const QString &name, const QString &state,
|
||||||
|
int &bufferLen);
|
||||||
|
|
||||||
|
// returns NULL on error. bufferLen is the length of the returned buffer.
|
||||||
|
static unsigned char * createUNamPacket(quint8 universeIndex, const QString &name,
|
||||||
|
int &bufferLen);
|
||||||
|
|
||||||
|
// MSEX
|
||||||
|
|
||||||
|
static unsigned char * createSINFPacket(int &bufferLen);
|
||||||
|
static unsigned char * createLSTAPacket(layerList layerp, int &bufferLen);
|
||||||
|
static unsigned char * createNACKPacket(quint32 cookie, int &bufferLen);
|
||||||
|
static unsigned char * createELINPacket(QList<MediaLibrary> medialib, int &bufferLen);
|
||||||
|
static unsigned char * createMEINPacket(MediaLibrary medialib, int &bufferLen);
|
||||||
|
static unsigned char * createETHNPacket(QString path, MediaLibrary medialib, int elementnumber, int &bufferLen);
|
||||||
|
static const char * createVSRCPacket(int &bufferLen);
|
||||||
|
// static const char * createFrame(uchar *frame, int &bufferLen);
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // _PACKETCREATOR_H_
|
182
PeerInformationSocket.cpp
Normal file
182
PeerInformationSocket.cpp
Normal file
|
@ -0,0 +1,182 @@
|
||||||
|
/*
|
||||||
|
The MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2012-2013 Santi Noreña
|
||||||
|
|
||||||
|
Copyright (c) 2009 John Warwick
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in
|
||||||
|
all copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
THE SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
#include "PeerInformationSocket.h"
|
||||||
|
#include "citp-lib.h"
|
||||||
|
#include "CITPDefines.h"
|
||||||
|
#include "PacketCreator.h"
|
||||||
|
//#include "MediaServer.h"
|
||||||
|
|
||||||
|
#include <QTimer>
|
||||||
|
#include <QtDebug>
|
||||||
|
#include <QNetworkInterface>
|
||||||
|
#ifdef Q_OS_WIN
|
||||||
|
#include <winsock2.h>
|
||||||
|
#include <ws2tcpip.h>
|
||||||
|
#else
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/socket.h>
|
||||||
|
#include <netinet/in.h>
|
||||||
|
#include <arpa/inet.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
PeerInformationSocket::PeerInformationSocket(QObject *parent)
|
||||||
|
: QUdpSocket(parent),
|
||||||
|
m_name(tr("Unknown name")),
|
||||||
|
m_state(tr("Unknown state")),
|
||||||
|
m_packetBuffer(NULL),
|
||||||
|
m_packetBufferLen(0)
|
||||||
|
{
|
||||||
|
m_timer = new QTimer(this);
|
||||||
|
Q_CHECK_PTR(m_timer);
|
||||||
|
connect(m_timer, SIGNAL(timeout()),
|
||||||
|
this, SLOT(transmitPLoc()));
|
||||||
|
m_timer->setInterval(TRANSMIT_INTERVAL_MS);
|
||||||
|
setSocketState(QUdpSocket::BoundState);
|
||||||
|
}
|
||||||
|
|
||||||
|
PeerInformationSocket::~PeerInformationSocket()
|
||||||
|
{
|
||||||
|
if (m_timer)
|
||||||
|
{
|
||||||
|
m_timer->stop();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool PeerInformationSocket::init(const QString &name, const QString &state, quint32 ipadd)
|
||||||
|
{
|
||||||
|
if (m_timer)
|
||||||
|
{
|
||||||
|
m_timer->stop();
|
||||||
|
}
|
||||||
|
m_name = name;
|
||||||
|
m_state = state;
|
||||||
|
// create multicast socket, bind to port
|
||||||
|
QHostAddress address;
|
||||||
|
address.setAddress(ipadd);
|
||||||
|
if (!bind(address, CITP_PINF_MULTICAST_PORT, ShareAddress | ReuseAddressHint))
|
||||||
|
{
|
||||||
|
qDebug() << "Multicast bind failed";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
struct ip_mreq mreq;
|
||||||
|
mreq.imr_multiaddr.s_addr = inet_addr(CITP_PINF_MULTICAST_IP);
|
||||||
|
mreq.imr_interface.s_addr = ipadd;
|
||||||
|
int r = ::setsockopt(socketDescriptor(), IPPROTO_IP, IP_ADD_MEMBERSHIP,
|
||||||
|
(const char *)&mreq, sizeof(struct ip_mreq));
|
||||||
|
if (0 != r)
|
||||||
|
{
|
||||||
|
qDebug() << "setsockopt failed, r:" << r;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
delete m_packetBuffer;
|
||||||
|
m_packetBuffer = PacketCreator::createPLocPacket(name, state, m_packetBufferLen);
|
||||||
|
if (!m_packetBuffer)
|
||||||
|
{
|
||||||
|
m_packetBufferLen = 0;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// transmitPLoc();
|
||||||
|
|
||||||
|
// XXX - don't connect this more than once..
|
||||||
|
connect(this, SIGNAL(readyRead()),
|
||||||
|
this, SLOT(handleReadReady()));
|
||||||
|
|
||||||
|
if (m_timer)
|
||||||
|
{
|
||||||
|
m_timer->start();
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
void PeerInformationSocket::transmitPLoc()
|
||||||
|
{
|
||||||
|
if (m_packetBuffer && m_packetBufferLen > 0)
|
||||||
|
{
|
||||||
|
QHostAddress addr(CITP_PINF_MULTICAST_IP);
|
||||||
|
writeDatagram((const char*)m_packetBuffer, m_packetBufferLen, addr, CITP_PINF_MULTICAST_PORT);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void PeerInformationSocket::handleReadReady()
|
||||||
|
{
|
||||||
|
while (hasPendingDatagrams())
|
||||||
|
{
|
||||||
|
QByteArray datagram;
|
||||||
|
datagram.resize(pendingDatagramSize());
|
||||||
|
QHostAddress sender;
|
||||||
|
quint16 senderPort;
|
||||||
|
if (-1 != readDatagram(datagram.data(), datagram.size(),
|
||||||
|
&sender, &senderPort))
|
||||||
|
{
|
||||||
|
processPacket(sender, datagram);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void PeerInformationSocket::processPacket(const QHostAddress &address, const QByteArray &packetArray)
|
||||||
|
{
|
||||||
|
const char *data = packetArray.constData();
|
||||||
|
CITP_PINF_PLoc *packet = (CITP_PINF_PLoc*)data;
|
||||||
|
|
||||||
|
// CITP header
|
||||||
|
if (packet->CITPPINFHeader.CITPHeader.Cookie != COOKIE_CITP)
|
||||||
|
{
|
||||||
|
qDebug() << "No CITP";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
if (packet->CITPPINFHeader.CITPHeader.VersionMajor != 0x01)
|
||||||
|
{
|
||||||
|
qDebug() << "Invalid VersionMajor value:" << packet->CITPPINFHeader.CITPHeader.VersionMajor;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (packet->CITPPINFHeader.CITPHeader.VersionMinor != 0x00)
|
||||||
|
{
|
||||||
|
qDebug() << "Invalid VersionMinor value:" << packet->CITPPINFHeader.CITPHeader.VersionMinor;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
if (packet->CITPPINFHeader.CITPHeader.ContentType != COOKIE_PINF)
|
||||||
|
{
|
||||||
|
qDebug() << "NO PINF";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// PINF header
|
||||||
|
// if (packet->CITPPINFHeader.ContentType = COOKIE_PINF_PLOC)
|
||||||
|
// {
|
||||||
|
// qDebug() << "PLOC found" << packet->Name;
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
|
||||||
|
// PLoc data
|
||||||
|
// quint16 listeningPort = packet->ListeningTCPPort;
|
||||||
|
}
|
68
PeerInformationSocket.h
Normal file
68
PeerInformationSocket.h
Normal file
|
@ -0,0 +1,68 @@
|
||||||
|
// -*- mode: C++ -*-
|
||||||
|
/*
|
||||||
|
The MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2012-2013 Santi Noreña libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Copyright (c) 2009 John Warwick
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in
|
||||||
|
all copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
THE SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* This class makes the socket for the PLoc packets and process answers on that socket */
|
||||||
|
|
||||||
|
#ifndef _PEERINFORMATIONSOCKET_H_
|
||||||
|
#define _PEERINFORMATIONSOCKET_H_
|
||||||
|
|
||||||
|
#include <QUdpSocket>
|
||||||
|
|
||||||
|
class QTimer;
|
||||||
|
//class MediaServer;
|
||||||
|
|
||||||
|
struct PeerDescripton;
|
||||||
|
|
||||||
|
class PeerInformationSocket : public QUdpSocket
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
PeerInformationSocket(QObject *parent=0);
|
||||||
|
virtual ~PeerInformationSocket();
|
||||||
|
|
||||||
|
bool init(const QString &name, const QString &state, quint32 ipadd);
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
|
||||||
|
void transmitPLoc();
|
||||||
|
void handleReadReady();
|
||||||
|
|
||||||
|
private:
|
||||||
|
QString m_name;
|
||||||
|
QString m_state;
|
||||||
|
QTimer *m_timer;
|
||||||
|
unsigned char *m_packetBuffer;
|
||||||
|
int m_packetBufferLen;
|
||||||
|
|
||||||
|
void processPacket(const QHostAddress &sender, const QByteArray &packet);
|
||||||
|
|
||||||
|
signals:
|
||||||
|
|
||||||
|
// void peersUpdated();
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // _PEERINFORMATIONSOCKET_H_
|
52
citp-lib.cpp
Normal file
52
citp-lib.cpp
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
/*
|
||||||
|
The MIT License
|
||||||
|
|
||||||
|
Copyright c() 2012-2013 Santi Noreña
|
||||||
|
|
||||||
|
Copyright (c) 2009 John Warwick
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in
|
||||||
|
all copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
THE SOFTWARE.
|
||||||
|
*/
|
||||||
|
#include "citp-lib.h"
|
||||||
|
|
||||||
|
#include <QtDebug>
|
||||||
|
|
||||||
|
#include "CITPDefines.h"
|
||||||
|
#include "PeerInformationSocket.h"
|
||||||
|
|
||||||
|
CITPLib::CITPLib(QObject *parent)
|
||||||
|
: QObject(parent),
|
||||||
|
m_peerSocket(NULL)
|
||||||
|
{
|
||||||
|
m_peerSocket = new PeerInformationSocket(this);
|
||||||
|
Q_CHECK_PTR(m_peerSocket);
|
||||||
|
}
|
||||||
|
|
||||||
|
CITPLib::~CITPLib()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
bool CITPLib::createPeerInformationSocket(const QString &name, const QString &state, quint32 ipadd)
|
||||||
|
{
|
||||||
|
if (!m_peerSocket)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return m_peerSocket->init(name, state, ipadd);
|
||||||
|
}
|
68
citp-lib.h
Normal file
68
citp-lib.h
Normal file
|
@ -0,0 +1,68 @@
|
||||||
|
// -*- mode: C++ -*-
|
||||||
|
/*
|
||||||
|
The MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2012-2013 Santi Noreña libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Copyright (c) 2009 John Warwick
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in
|
||||||
|
all copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
THE SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef _CITPLIB_H_
|
||||||
|
#define _CITPLIB_H_
|
||||||
|
|
||||||
|
#include <qglobal.h>
|
||||||
|
|
||||||
|
#ifdef CITPLIB_LIB
|
||||||
|
# define CITPLIB_EXPORT Q_DECL_EXPORT
|
||||||
|
#else
|
||||||
|
# define CITPLIB_EXPORT Q_DECL_IMPORT
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QScriptable>
|
||||||
|
#include <QHostAddress>
|
||||||
|
#include <QNetworkInterface>
|
||||||
|
|
||||||
|
class PeerInformationSocket;
|
||||||
|
class MediaServer;
|
||||||
|
|
||||||
|
class CITPLIB_EXPORT CITPLib : public QObject, public QScriptable
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
|
||||||
|
CITPLib(QObject *parent = 0);
|
||||||
|
virtual ~CITPLib();
|
||||||
|
|
||||||
|
bool createPeerInformationSocket(const QString &name, const QString &state, quint32 ipadd);
|
||||||
|
|
||||||
|
PeerInformationSocket *m_peerSocket;
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
signals:
|
||||||
|
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // _CITPLIB_H_
|
676
doc/LICENSE.txt
Executable file
676
doc/LICENSE.txt
Executable file
|
@ -0,0 +1,676 @@
|
||||||
|
|
||||||
|
GNU GENERAL PUBLIC LICENSE
|
||||||
|
Version 3, 29 June 2007
|
||||||
|
|
||||||
|
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||||
|
Everyone is permitted to copy and distribute verbatim copies
|
||||||
|
of this license document, but changing it is not allowed.
|
||||||
|
|
||||||
|
Preamble
|
||||||
|
|
||||||
|
The GNU General Public License is a free, copyleft license for
|
||||||
|
software and other kinds of works.
|
||||||
|
|
||||||
|
The licenses for most software and other practical works are designed
|
||||||
|
to take away your freedom to share and change the works. By contrast,
|
||||||
|
the GNU General Public License is intended to guarantee your freedom to
|
||||||
|
share and change all versions of a program--to make sure it remains free
|
||||||
|
software for all its users. We, the Free Software Foundation, use the
|
||||||
|
GNU General Public License for most of our software; it applies also to
|
||||||
|
any other work released this way by its authors. You can apply it to
|
||||||
|
your programs, too.
|
||||||
|
|
||||||
|
When we speak of free software, we are referring to freedom, not
|
||||||
|
price. Our General Public Licenses are designed to make sure that you
|
||||||
|
have the freedom to distribute copies of free software (and charge for
|
||||||
|
them if you wish), that you receive source code or can get it if you
|
||||||
|
want it, that you can change the software or use pieces of it in new
|
||||||
|
free programs, and that you know you can do these things.
|
||||||
|
|
||||||
|
To protect your rights, we need to prevent others from denying you
|
||||||
|
these rights or asking you to surrender the rights. Therefore, you have
|
||||||
|
certain responsibilities if you distribute copies of the software, or if
|
||||||
|
you modify it: responsibilities to respect the freedom of others.
|
||||||
|
|
||||||
|
For example, if you distribute copies of such a program, whether
|
||||||
|
gratis or for a fee, you must pass on to the recipients the same
|
||||||
|
freedoms that you received. You must make sure that they, too, receive
|
||||||
|
or can get the source code. And you must show them these terms so they
|
||||||
|
know their rights.
|
||||||
|
|
||||||
|
Developers that use the GNU GPL protect your rights with two steps:
|
||||||
|
(1) assert copyright on the software, and (2) offer you this License
|
||||||
|
giving you legal permission to copy, distribute and/or modify it.
|
||||||
|
|
||||||
|
For the developers' and authors' protection, the GPL clearly explains
|
||||||
|
that there is no warranty for this free software. For both users' and
|
||||||
|
authors' sake, the GPL requires that modified versions be marked as
|
||||||
|
changed, so that their problems will not be attributed erroneously to
|
||||||
|
authors of previous versions.
|
||||||
|
|
||||||
|
Some devices are designed to deny users access to install or run
|
||||||
|
modified versions of the software inside them, although the manufacturer
|
||||||
|
can do so. This is fundamentally incompatible with the aim of
|
||||||
|
protecting users' freedom to change the software. The systematic
|
||||||
|
pattern of such abuse occurs in the area of products for individuals to
|
||||||
|
use, which is precisely where it is most unacceptable. Therefore, we
|
||||||
|
have designed this version of the GPL to prohibit the practice for those
|
||||||
|
products. If such problems arise substantially in other domains, we
|
||||||
|
stand ready to extend this provision to those domains in future versions
|
||||||
|
of the GPL, as needed to protect the freedom of users.
|
||||||
|
|
||||||
|
Finally, every program is threatened constantly by software patents.
|
||||||
|
States should not allow patents to restrict development and use of
|
||||||
|
software on general-purpose computers, but in those that do, we wish to
|
||||||
|
avoid the special danger that patents applied to a free program could
|
||||||
|
make it effectively proprietary. To prevent this, the GPL assures that
|
||||||
|
patents cannot be used to render the program non-free.
|
||||||
|
|
||||||
|
The precise terms and conditions for copying, distribution and
|
||||||
|
modification follow.
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
0. Definitions.
|
||||||
|
|
||||||
|
"This License" refers to version 3 of the GNU General Public License.
|
||||||
|
|
||||||
|
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||||
|
works, such as semiconductor masks.
|
||||||
|
|
||||||
|
"The Program" refers to any copyrightable work licensed under this
|
||||||
|
License. Each licensee is addressed as "you". "Licensees" and
|
||||||
|
"recipients" may be individuals or organizations.
|
||||||
|
|
||||||
|
To "modify" a work means to copy from or adapt all or part of the work
|
||||||
|
in a fashion requiring copyright permission, other than the making of an
|
||||||
|
exact copy. The resulting work is called a "modified version" of the
|
||||||
|
earlier work or a work "based on" the earlier work.
|
||||||
|
|
||||||
|
A "covered work" means either the unmodified Program or a work based
|
||||||
|
on the Program.
|
||||||
|
|
||||||
|
To "propagate" a work means to do anything with it that, without
|
||||||
|
permission, would make you directly or secondarily liable for
|
||||||
|
infringement under applicable copyright law, except executing it on a
|
||||||
|
computer or modifying a private copy. Propagation includes copying,
|
||||||
|
distribution (with or without modification), making available to the
|
||||||
|
public, and in some countries other activities as well.
|
||||||
|
|
||||||
|
To "convey" a work means any kind of propagation that enables other
|
||||||
|
parties to make or receive copies. Mere interaction with a user through
|
||||||
|
a computer network, with no transfer of a copy, is not conveying.
|
||||||
|
|
||||||
|
An interactive user interface displays "Appropriate Legal Notices"
|
||||||
|
to the extent that it includes a convenient and prominently visible
|
||||||
|
feature that (1) displays an appropriate copyright notice, and (2)
|
||||||
|
tells the user that there is no warranty for the work (except to the
|
||||||
|
extent that warranties are provided), that licensees may convey the
|
||||||
|
work under this License, and how to view a copy of this License. If
|
||||||
|
the interface presents a list of user commands or options, such as a
|
||||||
|
menu, a prominent item in the list meets this criterion.
|
||||||
|
|
||||||
|
1. Source Code.
|
||||||
|
|
||||||
|
The "source code" for a work means the preferred form of the work
|
||||||
|
for making modifications to it. "Object code" means any non-source
|
||||||
|
form of a work.
|
||||||
|
|
||||||
|
A "Standard Interface" means an interface that either is an official
|
||||||
|
standard defined by a recognized standards body, or, in the case of
|
||||||
|
interfaces specified for a particular programming language, one that
|
||||||
|
is widely used among developers working in that language.
|
||||||
|
|
||||||
|
The "System Libraries" of an executable work include anything, other
|
||||||
|
than the work as a whole, that (a) is included in the normal form of
|
||||||
|
packaging a Major Component, but which is not part of that Major
|
||||||
|
Component, and (b) serves only to enable use of the work with that
|
||||||
|
Major Component, or to implement a Standard Interface for which an
|
||||||
|
implementation is available to the public in source code form. A
|
||||||
|
"Major Component", in this context, means a major essential component
|
||||||
|
(kernel, window system, and so on) of the specific operating system
|
||||||
|
(if any) on which the executable work runs, or a compiler used to
|
||||||
|
produce the work, or an object code interpreter used to run it.
|
||||||
|
|
||||||
|
The "Corresponding Source" for a work in object code form means all
|
||||||
|
the source code needed to generate, install, and (for an executable
|
||||||
|
work) run the object code and to modify the work, including scripts to
|
||||||
|
control those activities. However, it does not include the work's
|
||||||
|
System Libraries, or general-purpose tools or generally available free
|
||||||
|
programs which are used unmodified in performing those activities but
|
||||||
|
which are not part of the work. For example, Corresponding Source
|
||||||
|
includes interface definition files associated with source files for
|
||||||
|
the work, and the source code for shared libraries and dynamically
|
||||||
|
linked subprograms that the work is specifically designed to require,
|
||||||
|
such as by intimate data communication or control flow between those
|
||||||
|
subprograms and other parts of the work.
|
||||||
|
|
||||||
|
The Corresponding Source need not include anything that users
|
||||||
|
can regenerate automatically from other parts of the Corresponding
|
||||||
|
Source.
|
||||||
|
|
||||||
|
The Corresponding Source for a work in source code form is that
|
||||||
|
same work.
|
||||||
|
|
||||||
|
2. Basic Permissions.
|
||||||
|
|
||||||
|
All rights granted under this License are granted for the term of
|
||||||
|
copyright on the Program, and are irrevocable provided the stated
|
||||||
|
conditions are met. This License explicitly affirms your unlimited
|
||||||
|
permission to run the unmodified Program. The output from running a
|
||||||
|
covered work is covered by this License only if the output, given its
|
||||||
|
content, constitutes a covered work. This License acknowledges your
|
||||||
|
rights of fair use or other equivalent, as provided by copyright law.
|
||||||
|
|
||||||
|
You may make, run and propagate covered works that you do not
|
||||||
|
convey, without conditions so long as your license otherwise remains
|
||||||
|
in force. You may convey covered works to others for the sole purpose
|
||||||
|
of having them make modifications exclusively for you, or provide you
|
||||||
|
with facilities for running those works, provided that you comply with
|
||||||
|
the terms of this License in conveying all material for which you do
|
||||||
|
not control copyright. Those thus making or running the covered works
|
||||||
|
for you must do so exclusively on your behalf, under your direction
|
||||||
|
and control, on terms that prohibit them from making any copies of
|
||||||
|
your copyrighted material outside their relationship with you.
|
||||||
|
|
||||||
|
Conveying under any other circumstances is permitted solely under
|
||||||
|
the conditions stated below. Sublicensing is not allowed; section 10
|
||||||
|
makes it unnecessary.
|
||||||
|
|
||||||
|
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||||
|
|
||||||
|
No covered work shall be deemed part of an effective technological
|
||||||
|
measure under any applicable law fulfilling obligations under article
|
||||||
|
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||||
|
similar laws prohibiting or restricting circumvention of such
|
||||||
|
measures.
|
||||||
|
|
||||||
|
When you convey a covered work, you waive any legal power to forbid
|
||||||
|
circumvention of technological measures to the extent such circumvention
|
||||||
|
is effected by exercising rights under this License with respect to
|
||||||
|
the covered work, and you disclaim any intention to limit operation or
|
||||||
|
modification of the work as a means of enforcing, against the work's
|
||||||
|
users, your or third parties' legal rights to forbid circumvention of
|
||||||
|
technological measures.
|
||||||
|
|
||||||
|
4. Conveying Verbatim Copies.
|
||||||
|
|
||||||
|
You may convey verbatim copies of the Program's source code as you
|
||||||
|
receive it, in any medium, provided that you conspicuously and
|
||||||
|
appropriately publish on each copy an appropriate copyright notice;
|
||||||
|
keep intact all notices stating that this License and any
|
||||||
|
non-permissive terms added in accord with section 7 apply to the code;
|
||||||
|
keep intact all notices of the absence of any warranty; and give all
|
||||||
|
recipients a copy of this License along with the Program.
|
||||||
|
|
||||||
|
You may charge any price or no price for each copy that you convey,
|
||||||
|
and you may offer support or warranty protection for a fee.
|
||||||
|
|
||||||
|
5. Conveying Modified Source Versions.
|
||||||
|
|
||||||
|
You may convey a work based on the Program, or the modifications to
|
||||||
|
produce it from the Program, in the form of source code under the
|
||||||
|
terms of section 4, provided that you also meet all of these conditions:
|
||||||
|
|
||||||
|
a) The work must carry prominent notices stating that you modified
|
||||||
|
it, and giving a relevant date.
|
||||||
|
|
||||||
|
b) The work must carry prominent notices stating that it is
|
||||||
|
released under this License and any conditions added under section
|
||||||
|
7. This requirement modifies the requirement in section 4 to
|
||||||
|
"keep intact all notices".
|
||||||
|
|
||||||
|
c) You must license the entire work, as a whole, under this
|
||||||
|
License to anyone who comes into possession of a copy. This
|
||||||
|
License will therefore apply, along with any applicable section 7
|
||||||
|
additional terms, to the whole of the work, and all its parts,
|
||||||
|
regardless of how they are packaged. This License gives no
|
||||||
|
permission to license the work in any other way, but it does not
|
||||||
|
invalidate such permission if you have separately received it.
|
||||||
|
|
||||||
|
d) If the work has interactive user interfaces, each must display
|
||||||
|
Appropriate Legal Notices; however, if the Program has interactive
|
||||||
|
interfaces that do not display Appropriate Legal Notices, your
|
||||||
|
work need not make them do so.
|
||||||
|
|
||||||
|
A compilation of a covered work with other separate and independent
|
||||||
|
works, which are not by their nature extensions of the covered work,
|
||||||
|
and which are not combined with it such as to form a larger program,
|
||||||
|
in or on a volume of a storage or distribution medium, is called an
|
||||||
|
"aggregate" if the compilation and its resulting copyright are not
|
||||||
|
used to limit the access or legal rights of the compilation's users
|
||||||
|
beyond what the individual works permit. Inclusion of a covered work
|
||||||
|
in an aggregate does not cause this License to apply to the other
|
||||||
|
parts of the aggregate.
|
||||||
|
|
||||||
|
6. Conveying Non-Source Forms.
|
||||||
|
|
||||||
|
You may convey a covered work in object code form under the terms
|
||||||
|
of sections 4 and 5, provided that you also convey the
|
||||||
|
machine-readable Corresponding Source under the terms of this License,
|
||||||
|
in one of these ways:
|
||||||
|
|
||||||
|
a) Convey the object code in, or embodied in, a physical product
|
||||||
|
(including a physical distribution medium), accompanied by the
|
||||||
|
Corresponding Source fixed on a durable physical medium
|
||||||
|
customarily used for software interchange.
|
||||||
|
|
||||||
|
b) Convey the object code in, or embodied in, a physical product
|
||||||
|
(including a physical distribution medium), accompanied by a
|
||||||
|
written offer, valid for at least three years and valid for as
|
||||||
|
long as you offer spare parts or customer support for that product
|
||||||
|
model, to give anyone who possesses the object code either (1) a
|
||||||
|
copy of the Corresponding Source for all the software in the
|
||||||
|
product that is covered by this License, on a durable physical
|
||||||
|
medium customarily used for software interchange, for a price no
|
||||||
|
more than your reasonable cost of physically performing this
|
||||||
|
conveying of source, or (2) access to copy the
|
||||||
|
Corresponding Source from a network server at no charge.
|
||||||
|
|
||||||
|
c) Convey individual copies of the object code with a copy of the
|
||||||
|
written offer to provide the Corresponding Source. This
|
||||||
|
alternative is allowed only occasionally and noncommercially, and
|
||||||
|
only if you received the object code with such an offer, in accord
|
||||||
|
with subsection 6b.
|
||||||
|
|
||||||
|
d) Convey the object code by offering access from a designated
|
||||||
|
place (gratis or for a charge), and offer equivalent access to the
|
||||||
|
Corresponding Source in the same way through the same place at no
|
||||||
|
further charge. You need not require recipients to copy the
|
||||||
|
Corresponding Source along with the object code. If the place to
|
||||||
|
copy the object code is a network server, the Corresponding Source
|
||||||
|
may be on a different server (operated by you or a third party)
|
||||||
|
that supports equivalent copying facilities, provided you maintain
|
||||||
|
clear directions next to the object code saying where to find the
|
||||||
|
Corresponding Source. Regardless of what server hosts the
|
||||||
|
Corresponding Source, you remain obligated to ensure that it is
|
||||||
|
available for as long as needed to satisfy these requirements.
|
||||||
|
|
||||||
|
e) Convey the object code using peer-to-peer transmission, provided
|
||||||
|
you inform other peers where the object code and Corresponding
|
||||||
|
Source of the work are being offered to the general public at no
|
||||||
|
charge under subsection 6d.
|
||||||
|
|
||||||
|
A separable portion of the object code, whose source code is excluded
|
||||||
|
from the Corresponding Source as a System Library, need not be
|
||||||
|
included in conveying the object code work.
|
||||||
|
|
||||||
|
A "User Product" is either (1) a "consumer product", which means any
|
||||||
|
tangible personal property which is normally used for personal, family,
|
||||||
|
or household purposes, or (2) anything designed or sold for incorporation
|
||||||
|
into a dwelling. In determining whether a product is a consumer product,
|
||||||
|
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||||
|
product received by a particular user, "normally used" refers to a
|
||||||
|
typical or common use of that class of product, regardless of the status
|
||||||
|
of the particular user or of the way in which the particular user
|
||||||
|
actually uses, or expects or is expected to use, the product. A product
|
||||||
|
is a consumer product regardless of whether the product has substantial
|
||||||
|
commercial, industrial or non-consumer uses, unless such uses represent
|
||||||
|
the only significant mode of use of the product.
|
||||||
|
|
||||||
|
"Installation Information" for a User Product means any methods,
|
||||||
|
procedures, authorization keys, or other information required to install
|
||||||
|
and execute modified versions of a covered work in that User Product from
|
||||||
|
a modified version of its Corresponding Source. The information must
|
||||||
|
suffice to ensure that the continued functioning of the modified object
|
||||||
|
code is in no case prevented or interfered with solely because
|
||||||
|
modification has been made.
|
||||||
|
|
||||||
|
If you convey an object code work under this section in, or with, or
|
||||||
|
specifically for use in, a User Product, and the conveying occurs as
|
||||||
|
part of a transaction in which the right of possession and use of the
|
||||||
|
User Product is transferred to the recipient in perpetuity or for a
|
||||||
|
fixed term (regardless of how the transaction is characterized), the
|
||||||
|
Corresponding Source conveyed under this section must be accompanied
|
||||||
|
by the Installation Information. But this requirement does not apply
|
||||||
|
if neither you nor any third party retains the ability to install
|
||||||
|
modified object code on the User Product (for example, the work has
|
||||||
|
been installed in ROM).
|
||||||
|
|
||||||
|
The requirement to provide Installation Information does not include a
|
||||||
|
requirement to continue to provide support service, warranty, or updates
|
||||||
|
for a work that has been modified or installed by the recipient, or for
|
||||||
|
the User Product in which it has been modified or installed. Access to a
|
||||||
|
network may be denied when the modification itself materially and
|
||||||
|
adversely affects the operation of the network or violates the rules and
|
||||||
|
protocols for communication across the network.
|
||||||
|
|
||||||
|
Corresponding Source conveyed, and Installation Information provided,
|
||||||
|
in accord with this section must be in a format that is publicly
|
||||||
|
documented (and with an implementation available to the public in
|
||||||
|
source code form), and must require no special password or key for
|
||||||
|
unpacking, reading or copying.
|
||||||
|
|
||||||
|
7. Additional Terms.
|
||||||
|
|
||||||
|
"Additional permissions" are terms that supplement the terms of this
|
||||||
|
License by making exceptions from one or more of its conditions.
|
||||||
|
Additional permissions that are applicable to the entire Program shall
|
||||||
|
be treated as though they were included in this License, to the extent
|
||||||
|
that they are valid under applicable law. If additional permissions
|
||||||
|
apply only to part of the Program, that part may be used separately
|
||||||
|
under those permissions, but the entire Program remains governed by
|
||||||
|
this License without regard to the additional permissions.
|
||||||
|
|
||||||
|
When you convey a copy of a covered work, you may at your option
|
||||||
|
remove any additional permissions from that copy, or from any part of
|
||||||
|
it. (Additional permissions may be written to require their own
|
||||||
|
removal in certain cases when you modify the work.) You may place
|
||||||
|
additional permissions on material, added by you to a covered work,
|
||||||
|
for which you have or can give appropriate copyright permission.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, for material you
|
||||||
|
add to a covered work, you may (if authorized by the copyright holders of
|
||||||
|
that material) supplement the terms of this License with terms:
|
||||||
|
|
||||||
|
a) Disclaiming warranty or limiting liability differently from the
|
||||||
|
terms of sections 15 and 16 of this License; or
|
||||||
|
|
||||||
|
b) Requiring preservation of specified reasonable legal notices or
|
||||||
|
author attributions in that material or in the Appropriate Legal
|
||||||
|
Notices displayed by works containing it; or
|
||||||
|
|
||||||
|
c) Prohibiting misrepresentation of the origin of that material, or
|
||||||
|
requiring that modified versions of such material be marked in
|
||||||
|
reasonable ways as different from the original version; or
|
||||||
|
|
||||||
|
d) Limiting the use for publicity purposes of names of licensors or
|
||||||
|
authors of the material; or
|
||||||
|
|
||||||
|
e) Declining to grant rights under trademark law for use of some
|
||||||
|
trade names, trademarks, or service marks; or
|
||||||
|
|
||||||
|
f) Requiring indemnification of licensors and authors of that
|
||||||
|
material by anyone who conveys the material (or modified versions of
|
||||||
|
it) with contractual assumptions of liability to the recipient, for
|
||||||
|
any liability that these contractual assumptions directly impose on
|
||||||
|
those licensors and authors.
|
||||||
|
|
||||||
|
All other non-permissive additional terms are considered "further
|
||||||
|
restrictions" within the meaning of section 10. If the Program as you
|
||||||
|
received it, or any part of it, contains a notice stating that it is
|
||||||
|
governed by this License along with a term that is a further
|
||||||
|
restriction, you may remove that term. If a license document contains
|
||||||
|
a further restriction but permits relicensing or conveying under this
|
||||||
|
License, you may add to a covered work material governed by the terms
|
||||||
|
of that license document, provided that the further restriction does
|
||||||
|
not survive such relicensing or conveying.
|
||||||
|
|
||||||
|
If you add terms to a covered work in accord with this section, you
|
||||||
|
must place, in the relevant source files, a statement of the
|
||||||
|
additional terms that apply to those files, or a notice indicating
|
||||||
|
where to find the applicable terms.
|
||||||
|
|
||||||
|
Additional terms, permissive or non-permissive, may be stated in the
|
||||||
|
form of a separately written license, or stated as exceptions;
|
||||||
|
the above requirements apply either way.
|
||||||
|
|
||||||
|
8. Termination.
|
||||||
|
|
||||||
|
You may not propagate or modify a covered work except as expressly
|
||||||
|
provided under this License. Any attempt otherwise to propagate or
|
||||||
|
modify it is void, and will automatically terminate your rights under
|
||||||
|
this License (including any patent licenses granted under the third
|
||||||
|
paragraph of section 11).
|
||||||
|
|
||||||
|
However, if you cease all violation of this License, then your
|
||||||
|
license from a particular copyright holder is reinstated (a)
|
||||||
|
provisionally, unless and until the copyright holder explicitly and
|
||||||
|
finally terminates your license, and (b) permanently, if the copyright
|
||||||
|
holder fails to notify you of the violation by some reasonable means
|
||||||
|
prior to 60 days after the cessation.
|
||||||
|
|
||||||
|
Moreover, your license from a particular copyright holder is
|
||||||
|
reinstated permanently if the copyright holder notifies you of the
|
||||||
|
violation by some reasonable means, this is the first time you have
|
||||||
|
received notice of violation of this License (for any work) from that
|
||||||
|
copyright holder, and you cure the violation prior to 30 days after
|
||||||
|
your receipt of the notice.
|
||||||
|
|
||||||
|
Termination of your rights under this section does not terminate the
|
||||||
|
licenses of parties who have received copies or rights from you under
|
||||||
|
this License. If your rights have been terminated and not permanently
|
||||||
|
reinstated, you do not qualify to receive new licenses for the same
|
||||||
|
material under section 10.
|
||||||
|
|
||||||
|
9. Acceptance Not Required for Having Copies.
|
||||||
|
|
||||||
|
You are not required to accept this License in order to receive or
|
||||||
|
run a copy of the Program. Ancillary propagation of a covered work
|
||||||
|
occurring solely as a consequence of using peer-to-peer transmission
|
||||||
|
to receive a copy likewise does not require acceptance. However,
|
||||||
|
nothing other than this License grants you permission to propagate or
|
||||||
|
modify any covered work. These actions infringe copyright if you do
|
||||||
|
not accept this License. Therefore, by modifying or propagating a
|
||||||
|
covered work, you indicate your acceptance of this License to do so.
|
||||||
|
|
||||||
|
10. Automatic Licensing of Downstream Recipients.
|
||||||
|
|
||||||
|
Each time you convey a covered work, the recipient automatically
|
||||||
|
receives a license from the original licensors, to run, modify and
|
||||||
|
propagate that work, subject to this License. You are not responsible
|
||||||
|
for enforcing compliance by third parties with this License.
|
||||||
|
|
||||||
|
An "entity transaction" is a transaction transferring control of an
|
||||||
|
organization, or substantially all assets of one, or subdividing an
|
||||||
|
organization, or merging organizations. If propagation of a covered
|
||||||
|
work results from an entity transaction, each party to that
|
||||||
|
transaction who receives a copy of the work also receives whatever
|
||||||
|
licenses to the work the party's predecessor in interest had or could
|
||||||
|
give under the previous paragraph, plus a right to possession of the
|
||||||
|
Corresponding Source of the work from the predecessor in interest, if
|
||||||
|
the predecessor has it or can get it with reasonable efforts.
|
||||||
|
|
||||||
|
You may not impose any further restrictions on the exercise of the
|
||||||
|
rights granted or affirmed under this License. For example, you may
|
||||||
|
not impose a license fee, royalty, or other charge for exercise of
|
||||||
|
rights granted under this License, and you may not initiate litigation
|
||||||
|
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||||
|
any patent claim is infringed by making, using, selling, offering for
|
||||||
|
sale, or importing the Program or any portion of it.
|
||||||
|
|
||||||
|
11. Patents.
|
||||||
|
|
||||||
|
A "contributor" is a copyright holder who authorizes use under this
|
||||||
|
License of the Program or a work on which the Program is based. The
|
||||||
|
work thus licensed is called the contributor's "contributor version".
|
||||||
|
|
||||||
|
A contributor's "essential patent claims" are all patent claims
|
||||||
|
owned or controlled by the contributor, whether already acquired or
|
||||||
|
hereafter acquired, that would be infringed by some manner, permitted
|
||||||
|
by this License, of making, using, or selling its contributor version,
|
||||||
|
but do not include claims that would be infringed only as a
|
||||||
|
consequence of further modification of the contributor version. For
|
||||||
|
purposes of this definition, "control" includes the right to grant
|
||||||
|
patent sublicenses in a manner consistent with the requirements of
|
||||||
|
this License.
|
||||||
|
|
||||||
|
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||||
|
patent license under the contributor's essential patent claims, to
|
||||||
|
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||||
|
propagate the contents of its contributor version.
|
||||||
|
|
||||||
|
In the following three paragraphs, a "patent license" is any express
|
||||||
|
agreement or commitment, however denominated, not to enforce a patent
|
||||||
|
(such as an express permission to practice a patent or covenant not to
|
||||||
|
sue for patent infringement). To "grant" such a patent license to a
|
||||||
|
party means to make such an agreement or commitment not to enforce a
|
||||||
|
patent against the party.
|
||||||
|
|
||||||
|
If you convey a covered work, knowingly relying on a patent license,
|
||||||
|
and the Corresponding Source of the work is not available for anyone
|
||||||
|
to copy, free of charge and under the terms of this License, through a
|
||||||
|
publicly available network server or other readily accessible means,
|
||||||
|
then you must either (1) cause the Corresponding Source to be so
|
||||||
|
available, or (2) arrange to deprive yourself of the benefit of the
|
||||||
|
patent license for this particular work, or (3) arrange, in a manner
|
||||||
|
consistent with the requirements of this License, to extend the patent
|
||||||
|
license to downstream recipients. "Knowingly relying" means you have
|
||||||
|
actual knowledge that, but for the patent license, your conveying the
|
||||||
|
covered work in a country, or your recipient's use of the covered work
|
||||||
|
in a country, would infringe one or more identifiable patents in that
|
||||||
|
country that you have reason to believe are valid.
|
||||||
|
|
||||||
|
If, pursuant to or in connection with a single transaction or
|
||||||
|
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||||
|
covered work, and grant a patent license to some of the parties
|
||||||
|
receiving the covered work authorizing them to use, propagate, modify
|
||||||
|
or convey a specific copy of the covered work, then the patent license
|
||||||
|
you grant is automatically extended to all recipients of the covered
|
||||||
|
work and works based on it.
|
||||||
|
|
||||||
|
A patent license is "discriminatory" if it does not include within
|
||||||
|
the scope of its coverage, prohibits the exercise of, or is
|
||||||
|
conditioned on the non-exercise of one or more of the rights that are
|
||||||
|
specifically granted under this License. You may not convey a covered
|
||||||
|
work if you are a party to an arrangement with a third party that is
|
||||||
|
in the business of distributing software, under which you make payment
|
||||||
|
to the third party based on the extent of your activity of conveying
|
||||||
|
the work, and under which the third party grants, to any of the
|
||||||
|
parties who would receive the covered work from you, a discriminatory
|
||||||
|
patent license (a) in connection with copies of the covered work
|
||||||
|
conveyed by you (or copies made from those copies), or (b) primarily
|
||||||
|
for and in connection with specific products or compilations that
|
||||||
|
contain the covered work, unless you entered into that arrangement,
|
||||||
|
or that patent license was granted, prior to 28 March 2007.
|
||||||
|
|
||||||
|
Nothing in this License shall be construed as excluding or limiting
|
||||||
|
any implied license or other defenses to infringement that may
|
||||||
|
otherwise be available to you under applicable patent law.
|
||||||
|
|
||||||
|
12. No Surrender of Others' Freedom.
|
||||||
|
|
||||||
|
If conditions are imposed on you (whether by court order, agreement or
|
||||||
|
otherwise) that contradict the conditions of this License, they do not
|
||||||
|
excuse you from the conditions of this License. If you cannot convey a
|
||||||
|
covered work so as to satisfy simultaneously your obligations under this
|
||||||
|
License and any other pertinent obligations, then as a consequence you may
|
||||||
|
not convey it at all. For example, if you agree to terms that obligate you
|
||||||
|
to collect a royalty for further conveying from those to whom you convey
|
||||||
|
the Program, the only way you could satisfy both those terms and this
|
||||||
|
License would be to refrain entirely from conveying the Program.
|
||||||
|
|
||||||
|
13. Use with the GNU Affero General Public License.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, you have
|
||||||
|
permission to link or combine any covered work with a work licensed
|
||||||
|
under version 3 of the GNU Affero General Public License into a single
|
||||||
|
combined work, and to convey the resulting work. The terms of this
|
||||||
|
License will continue to apply to the part which is the covered work,
|
||||||
|
but the special requirements of the GNU Affero General Public License,
|
||||||
|
section 13, concerning interaction through a network will apply to the
|
||||||
|
combination as such.
|
||||||
|
|
||||||
|
14. Revised Versions of this License.
|
||||||
|
|
||||||
|
The Free Software Foundation may publish revised and/or new versions of
|
||||||
|
the GNU General Public License from time to time. Such new versions will
|
||||||
|
be similar in spirit to the present version, but may differ in detail to
|
||||||
|
address new problems or concerns.
|
||||||
|
|
||||||
|
Each version is given a distinguishing version number. If the
|
||||||
|
Program specifies that a certain numbered version of the GNU General
|
||||||
|
Public License "or any later version" applies to it, you have the
|
||||||
|
option of following the terms and conditions either of that numbered
|
||||||
|
version or of any later version published by the Free Software
|
||||||
|
Foundation. If the Program does not specify a version number of the
|
||||||
|
GNU General Public License, you may choose any version ever published
|
||||||
|
by the Free Software Foundation.
|
||||||
|
|
||||||
|
If the Program specifies that a proxy can decide which future
|
||||||
|
versions of the GNU General Public License can be used, that proxy's
|
||||||
|
public statement of acceptance of a version permanently authorizes you
|
||||||
|
to choose that version for the Program.
|
||||||
|
|
||||||
|
Later license versions may give you additional or different
|
||||||
|
permissions. However, no additional obligations are imposed on any
|
||||||
|
author or copyright holder as a result of your choosing to follow a
|
||||||
|
later version.
|
||||||
|
|
||||||
|
15. Disclaimer of Warranty.
|
||||||
|
|
||||||
|
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||||
|
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||||
|
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||||
|
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||||
|
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||||
|
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||||
|
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||||
|
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||||
|
|
||||||
|
16. Limitation of Liability.
|
||||||
|
|
||||||
|
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||||
|
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||||
|
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||||
|
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||||
|
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||||
|
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||||
|
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||||
|
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||||
|
SUCH DAMAGES.
|
||||||
|
|
||||||
|
17. Interpretation of Sections 15 and 16.
|
||||||
|
|
||||||
|
If the disclaimer of warranty and limitation of liability provided
|
||||||
|
above cannot be given local legal effect according to their terms,
|
||||||
|
reviewing courts shall apply local law that most closely approximates
|
||||||
|
an absolute waiver of all civil liability in connection with the
|
||||||
|
Program, unless a warranty or assumption of liability accompanies a
|
||||||
|
copy of the Program in return for a fee.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
How to Apply These Terms to Your New Programs
|
||||||
|
|
||||||
|
If you develop a new program, and you want it to be of the greatest
|
||||||
|
possible use to the public, the best way to achieve this is to make it
|
||||||
|
free software which everyone can redistribute and change under these terms.
|
||||||
|
|
||||||
|
To do so, attach the following notices to the program. It is safest
|
||||||
|
to attach them to the start of each source file to most effectively
|
||||||
|
state the exclusion of warranty; and each file should have at least
|
||||||
|
the "copyright" line and a pointer to where the full notice is found.
|
||||||
|
|
||||||
|
<one line to give the program's name and a brief idea of what it does.>
|
||||||
|
Copyright (C) <year> <name of author>
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Also add information on how to contact you by electronic and paper mail.
|
||||||
|
|
||||||
|
If the program does terminal interaction, make it output a short
|
||||||
|
notice like this when it starts in an interactive mode:
|
||||||
|
|
||||||
|
<program> Copyright (C) <year> <name of author>
|
||||||
|
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||||
|
This is free software, and you are welcome to redistribute it
|
||||||
|
under certain conditions; type `show c' for details.
|
||||||
|
|
||||||
|
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||||
|
parts of the General Public License. Of course, your program's commands
|
||||||
|
might be different; for a GUI interface, you would use an "about box".
|
||||||
|
|
||||||
|
You should also get your employer (if you work as a programmer) or school,
|
||||||
|
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||||
|
For more information on this, and how to apply and follow the GNU GPL, see
|
||||||
|
<http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
The GNU General Public License does not permit incorporating your program
|
||||||
|
into proprietary programs. If your program is a subroutine library, you
|
||||||
|
may consider it more useful to permit linking proprietary applications with
|
||||||
|
the library. If this is what you want to do, use the GNU Lesser General
|
||||||
|
Public License instead of this License. But first, please read
|
||||||
|
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
||||||
|
|
81
doc/changelog.txt
Normal file
81
doc/changelog.txt
Normal file
|
@ -0,0 +1,81 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Lbre Media Server ChangeLog
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
0.01 (8/1/2013) SVN Rev 1:
|
||||||
|
|
||||||
|
+ Audio en un proceso independiente. Reproducción de .oggs
|
||||||
|
+ Nuevos tipos de Alpha Blending. Nuevo canal DMX en la personalidad de video para el tipo de Alpha.
|
||||||
|
+ Preview de capas y mezcla final en el GUI.
|
||||||
|
+ Cambios en la GUI para acoger los dos procesos independientes de Pure Data.
|
||||||
|
+ Muchos más mensajes de error y de estado
|
||||||
|
+ Añadir comprobación de inicio para no repetir mensajes de error en el arranque.
|
||||||
|
+ CTIP/MSEx 1.0. Thumbs de videos, video preview.
|
||||||
|
+ Cambio de nombre de "Pure Media Server" a "Libre Media Server". Primera beta.
|
||||||
|
+ Cambio de nombre de la clase "MediaServer" a "msex".
|
||||||
|
+ Mejoras en ola2pd.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Pure Media Server ChangeLog:
|
||||||
|
|
||||||
|
* 0.0.5 (20-11-2012)
|
||||||
|
- Interface en Qt y C++. PD y OLA se ejecutan desde ella.
|
||||||
|
- Descontinuado el audio.
|
||||||
|
- Mapeo por capa.
|
||||||
|
|
||||||
|
* 0.0.4
|
||||||
|
- Añadidos efectos
|
||||||
|
- 8 capas
|
||||||
|
- Selección de encendido por capa
|
||||||
|
- Añadido medidor de CPU0
|
||||||
|
- Cambio de pdp_qt por pix_filmQT (se pierde la reproducción de sonido)
|
||||||
|
- Se separan los parches de audio y de video
|
||||||
|
|
||||||
|
* 0.0.3 (2-7-2012) SVN Rev 114
|
||||||
|
- Posición en 16 bits
|
||||||
|
- Control mediante Open Lighting Arquitecture y external ola2pd
|
||||||
|
- 64 canales reservados por capa
|
||||||
|
- Añadida carpeta resources para archivos de configuración de otros programas (QLC, MagicQ) que controlan PMS
|
||||||
|
- Correción de keystone/videomapping por capar
|
||||||
|
- Reproducción de audio
|
||||||
|
- Actualización del método de instalación en instalación.txt (todavía falta más trabajo en él).
|
||||||
|
- Cambiados valores de locate para hacerlos más sensibles
|
||||||
|
- 4 capas
|
||||||
|
|
||||||
|
* 0.02 (9-6-2011) SVN Rev 58
|
||||||
|
- Direccionamiento de las capas (issue 14).
|
||||||
|
- Metodos de creacion y destruccion de nodo ArtNet. Configuracion del nodo por patch dmx.pd (issue 15).
|
||||||
|
- imágenes (issue 5).
|
||||||
|
- Metodos de reproduccion auto (issue 8). pix_film_player.pd
|
||||||
|
- Nuevo subpatch de control manual
|
||||||
|
- Añadidos canales DMX de tamaños por ejes (XYZ), rotacion y posicion (issue 9)
|
||||||
|
- Textos - Nuevo archivo Gem compilado con soporte de fuentes (issue 4)
|
||||||
|
|
||||||
|
|
||||||
|
* 0.01 (16-05-2011)
|
||||||
|
- Primera versión liberada!
|
||||||
|
- 2 capas de video con control de reproducción avanzado mediante pix_film_player.
|
||||||
|
- Control de Alpha y Color RGB
|
||||||
|
- Control por ArtNet mediante Artnetin, sólo en el universo 0, subnet 0.
|
||||||
|
|
100
doc/instalacion.txt
Normal file
100
doc/instalacion.txt
Normal file
|
@ -0,0 +1,100 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
0. Requerimientos
|
||||||
|
|
||||||
|
LMS está desarrollado y probado en Debian Wheezy y Ubuntu Precise 12.04.
|
||||||
|
|
||||||
|
Necesitas una tarjeta gráfica OpenGL y que los drivers para Xorg con aceleración por hardware estén correctamente instalados. Ejecutando "glxgears" en una terminal debería de abrir una ventana con tres engranajes girando. Si no es así, revisa la documentación de tu distribución.
|
||||||
|
|
||||||
|
Para resolver dependencias es necesario tener conexión a internet en el ordenador durante el proceso de instalación.
|
||||||
|
|
||||||
|
PMS se comunicaa con Pure Data mediante puertos TCP, del 9195 al 9198. Open Lighting Arqitecure utiliza el puerto 9090 para su servidor web. Es necesario que estos puertos no estén siendo utilizados por otras aplicaciones.
|
||||||
|
|
||||||
|
1. Instala todas las dependencias.
|
||||||
|
|
||||||
|
Abre una terminal, cd al directorio scripts. Ejecuta como root
|
||||||
|
|
||||||
|
./install_wheezy.sh
|
||||||
|
|
||||||
|
o
|
||||||
|
|
||||||
|
./install_precise.sh
|
||||||
|
|
||||||
|
dependiendo de la distribución en que estés. Confirma Sí cuando te pregunte confirmación para descargas archivos y asegúrate de estar conectado a internet. Luego pincha en No cuando te pregunte si quieres arrancar el demonio OLA en el inicio.
|
||||||
|
|
||||||
|
2. Configuración
|
||||||
|
|
||||||
|
Este proceso sólo es necesario la primera vez que se ejecuta LMS.
|
||||||
|
|
||||||
|
a. Ejecuta el archivo libremediaserver.
|
||||||
|
|
||||||
|
b. Abre un navegador web y dirígete a localhost:9090.
|
||||||
|
|
||||||
|
c. Pincha en el botón "add universe"
|
||||||
|
|
||||||
|
d. Marca en la casilla del protocolo de red o dispositivo por el que quieras introducir datos. Asegúrate de que en "Direction" sea "input".
|
||||||
|
|
||||||
|
Si el protocolo elegido es ArtNet en "Universe Id" introduce el número del universo ArtNet por el que quieres recibir. La Net y la Subnet de Artnet se pueden cambiar en el archivo ~/.ola/ola-artnet.conf, por defecto es la Net 0 y la SubNet 0. Este número lo tienes que introducir luego en LMS en el campo "OLA universe". En Universe Name puedes introducir un nombre familiar, por ejemplo "video".
|
||||||
|
|
||||||
|
Puedes confirmar que está llegando información pinchando en el universo en el menú de la izquierda y luego en la pestaña "DMX Monitor". Puedes cerrar el navegador.
|
||||||
|
|
||||||
|
Edita con un editor de textos el archivo "make_thumbs.sh" en el directorio scripts y cámbia en la primera línea el path a tu directorio de medias. Guarda y cierra.
|
||||||
|
Ejecuta el archivo make_thumbs.sh desde una terminal.
|
||||||
|
|
||||||
|
En LibreMediaServer, pincha en "Change Media Path" y elige el directorio donde estén tus medias. Configura las direcciones DMX de cada capa según el patch de la mesa.
|
||||||
|
|
||||||
|
Puedes grabar la configuración ahora o esperar a que termine el programa. El programa al salir siempre guarda la configuración, y la abre automáticamente cuando se inicia.
|
||||||
|
|
||||||
|
4. Compiling.
|
||||||
|
|
||||||
|
If you have troubles, or you are in another distro, you can try compiling from the source code. It's not the easiest way...
|
||||||
|
|
||||||
|
# To compile and install flext
|
||||||
|
|
||||||
|
wget http://crca.ucsd.edu/~msp/Software/pd-0.43-2.src.tar.gz
|
||||||
|
tar -xf pd-0.43-2.src.tar.gz
|
||||||
|
sudo apt-get install subversion
|
||||||
|
svn co https://svn.grrrr.org/ext/trunk/flext flext
|
||||||
|
cd flext
|
||||||
|
./build.sh pd gcc
|
||||||
|
Edit the paths in file ./buildsys/cnfg-lnx-gcc.txt
|
||||||
|
./build sh pd gcc
|
||||||
|
sudo ./build.sh pd gcc install
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
# Add enviroment path variables to .bashrc
|
||||||
|
|
||||||
|
echo "export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib" >> ~/.bashrc
|
||||||
|
echo "export CPLUS_INCLUDE_PATH=$CPLUS_INCLUDE_PATH:/usr/local/include" >> ~/.bashrc
|
||||||
|
echo "export C_INCLUDE_PATH=$C_INCLUDE_PATH:/usr/local/include" >> ~/.bashrc
|
||||||
|
|
||||||
|
# Build and install ola2pd
|
||||||
|
|
||||||
|
cd externals/ola2pd/
|
||||||
|
/path/to/flext/build.sh pd gcc
|
||||||
|
/path/to/flext/build.sh pd gcc install
|
||||||
|
|
||||||
|
# Build and install Libre Media Server
|
||||||
|
|
||||||
|
svn checkout http://puremediaserver.googlecode.com/svn/trunk/ puremediaserver-read-only
|
||||||
|
Open the file libremediaserver.pro with QtCreator and compile it.
|
||||||
|
|
22
doc/install.txt
Normal file
22
doc/install.txt
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Sorry, only in spanish at the moment: instalacion.txt
|
56
doc/leeme.txt
Normal file
56
doc/leeme.txt
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
LibreMediaServer es un programa para manejar visuales y audio en actuaciones escénicas, instalaciones, eventos, performances,..., basado en Software Libre.
|
||||||
|
|
||||||
|
El control de LMS se realiza mediante el Open Lighting Arquitecture, por lo que podemos usar cualquier protocolo de iluminación abierto (ArtNet, PathPort,
|
||||||
|
ShowNet, ACN,...) o dispositivo DMX-USB (Enttec Pro, Velleman, Anyuma,...).
|
||||||
|
|
||||||
|
El motor gráfico y de audio es Pure Data con Gem.
|
||||||
|
|
||||||
|
LibreMediaServer funciona en GNU/Linux. Está testeado en Debian Wheezy y Ubuntu Precise 12.04, y debería funcionar en más distribuciones basadas
|
||||||
|
en Debian.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Características:
|
||||||
|
|
||||||
|
- 8 capas de video, imágenes o texto.
|
||||||
|
- 8 capas de audio.
|
||||||
|
- Playback avanzado.
|
||||||
|
- Cada capa puede ser mapeada mediante 4 puntos de Bèzier.
|
||||||
|
- Un montón de formatos de video: avi, mov, mpg, mp4, ogg.
|
||||||
|
- Reproducción de audio en formato ogg.
|
||||||
|
- Reproducción de imágenes en formato jpeg, tiff.
|
||||||
|
- Efectos de Video.
|
||||||
|
- Control de posición (en 16 bits), rotación en los 3 ejes, tamaño, y color por capa.
|
||||||
|
- Máscaras Croma/Luma, pasa-altos y/o pasabajos en RGB.
|
||||||
|
- Reproducción de textos a través de un fichero de texto, hasta 255 frases con
|
||||||
|
hasta 255 fuentes distintas TrueType.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Para instalar LMS vea instalacion.txt
|
||||||
|
|
||||||
|
Para usar LMS vea manual.txt
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
316
doc/manual.txt
Normal file
316
doc/manual.txt
Normal file
|
@ -0,0 +1,316 @@
|
||||||
|
******************************
|
||||||
|
Pure Media Server 0.0.6
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
puremediaserver at gmail dot com
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Lee instalacion.txt para el proceso de instalación.
|
||||||
|
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Pure Media server es un programa para gestionar visuales en artes escénicas, eventos, performances, instalaciones,...
|
||||||
|
|
||||||
|
Se controla mediante el Open Lighting Arquitecture que soporta una gran variedad de protocolos y dispositivos estandard de iluminación: Artnet, ShowNet, PathPort, ACN, Enttec Open DMX Pro,... De momento la única opción de control es mediante el OLA.
|
||||||
|
|
||||||
|
Puedes controlarlo gratis con el MagicQ de ChamSys si no dispones de ninguna mesa o programa de iluminación. No es software libre, pero al menos es gratis. En la carpeta "MagicQ" hay un archivo de show y el archivo de personalidad.
|
||||||
|
|
||||||
|
El motor gráfico y de audio es Pure Data, que se ejecuta en background invisible al usuario. Ahora mismo podemos reproducir 255 carpetas con 255 videos cada una en cualquier formato en que esté el codec instalado en el sistema. Si lo puede leer en el reproductor de medios de gnome podrá reproducirlo PMS. También podemos reproducir fotos y textos. El reproductor de medios podemos variar la velocidad, ejecutarlo en distintas direcciones (hacia delante, hacia atrás, ping-pong), y en bucle o en un sólo disparo.
|
||||||
|
|
||||||
|
PMS tiene 8 capas de video o texto, cada dispone de una correción Bezier de 4 puntos, por lo que podemos mapear diferentes superficies, o lados de objetos. También podemos corregir el keystone mediante estos ajustes. Por supuesto, hay ajustes de color, posición, tamaño y rotación por cada capa.
|
||||||
|
|
||||||
|
Las mezclas entre capas se realizan mediante 6 canales: 3 canales son pasa altos RGB y otros 3 Pasabajos RGB, con lo que se puden hacer lumas y cromas. El orden de las capas se controla mediante el canal de posición Z: cuanto más grande sea más al fondo se encuentra. El dimmer también controla la opacidad, por lo que una capa al 100% bloqueará a las inferiores.
|
||||||
|
|
||||||
|
También podemos manejar 8 capas de audio, cada una reproduciendo un archivo .ogg. El control de volumen es en 16 bits de precisión y logarítmico, en equipos pequeños o auriculares no se oirá nada hasta el 50 0 60%.
|
||||||
|
|
||||||
|
El interface gráfico es muy simple, sólo sirve para manejar la configuración de Pure Data y sirve para ver el archivo que cada capa está reproduciendo. Tenemos dos pestañas: Una para la configuración de Video y otra para la de Audio, que se dberá patchear en la mesa independientemente. Como los controles son parecidos para las dos ventanas, las explicamos juntas. Empezando de arriba hacia abajo:
|
||||||
|
|
||||||
|
A. Caja de textos. Se muestran mensajes de estado y de error.
|
||||||
|
|
||||||
|
B. 8 Capas. Representan las 8 capas de video.
|
||||||
|
B.1 Botón de activado de la capa. Si no está en on la capa no está activada y no renderiza, se quedará en la pantalla el último frame renderizado; desactivando no va a negro.
|
||||||
|
B.2 Dirección DMX. Hay que introducir el primer canal DMX de la capa, la misma a la que se patcheó en la mesa.
|
||||||
|
B.3 Etiqueta de media. Se muestra el archivo que está siendo reproducido en la capa.
|
||||||
|
|
||||||
|
C. Change Media Path. Cambia el path al árbol de directorios de los media. Este control es común para el video y el audio, sólo hace falta introducirlo una vez, aunque se muestr en las dos pestañas.
|
||||||
|
|
||||||
|
D. Video/Audio. Inicia o detiene los procesos de video y de audio. Abre o cierra la conexión con OLA.
|
||||||
|
|
||||||
|
F. ReadDMX. Empieza o termina la lectura de datos DMX
|
||||||
|
|
||||||
|
H. OLA Universe. El universo de Open Lighting Arquitecture que hemos configurado como entrada y al que el proceso escuchará. Ver instalacion.txt
|
||||||
|
|
||||||
|
G. Window. Crea y destruye la ventana de reproducción.
|
||||||
|
|
||||||
|
I. Window Position. Posición de la ventana de renderizado en pixeles x,y.
|
||||||
|
|
||||||
|
J. Window Size. Tamaño de la ventana de renderizado en pixeles x, y.
|
||||||
|
|
||||||
|
K. IP Adress. Dirección IP de la inerface que queremos usar. Dejar en 0.0.0.0 para todas las interfaces.
|
||||||
|
|
||||||
|
E. Init CITP/MSEx. Inicia el peer CITP y manda los thumbs si alguna mesa lo solicita.
|
||||||
|
|
||||||
|
El CITP/MSEx no funciona en el interface localhost. Sin embargo la recepción de datos ArtNet sí. Necesita tener un interface de red activo en el momento de lanzar el programa, pero después se puede desconectar. Se puede usar en el mismo ordenador PMS y MagicQLinux para controlarlo.
|
||||||
|
|
||||||
|
Generación de thumbs:
|
||||||
|
|
||||||
|
Es necesario generar lo thumbnails de tus medias para poder transmitirlos por CITP/MSEx. Lo puedes hacer mediante el fichero make_thumbs.sh en la carpeta scripts. Primero ábrelo con un editor de texto y edita el path a tus medias. Guarda, cierra, y ejecuta el archivo. Debería de crear una subcarpeta llamada thumbs por cada carpeta de medias, y en ella el thumbnail con el primer fotograma de cada archivo, con el mismo nombre, pero acabado en jpeg. En siguientes versiones intentaré integrar esto cuando se pulse el botón "Init CITP/MSEx"
|
||||||
|
|
||||||
|
La ventana de renderizado se muestra sobre todas las demás ventanas y sin que aparezca el cursor en ella. Si tenemos problemas en la configuración, por ejemplo nos quedamos sin ver el escritorio, siempre podemos llevar el cursor a la ventana de renderizado y presionar Escape para cerrarla. La posición de la ventana se configura con los controles "Window Position" y el tamaño de la ventana con "Window Size", los dos primero la x y después la y. Para hacer algo útil deberemos tener el escritorio extendido a un segundo monitor y configurar en estos controles los valores de ese monitor. Para aplicar cambios hay que cerrar la ventana y reabrirla.
|
||||||
|
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Estructura de medias:
|
||||||
|
|
||||||
|
Los archivos de medios que utiliza PMS deben de estar ordenados en un árbol de ficheros. La dirección superior del árbol es la que se tiene que itnroducir en el archivo scripts/make_thumbs.sh y configurar en PMS mediante el botón "Change media Path".
|
||||||
|
|
||||||
|
El árbol de ficheros tiene el siguiente esquema:
|
||||||
|
|
||||||
|
+ media
|
||||||
|
+ video
|
||||||
|
+ 000-descripcion
|
||||||
|
- 000-miloop.mov
|
||||||
|
- 001-milooocool.avi
|
||||||
|
- 002-mipelo.mpg
|
||||||
|
...
|
||||||
|
- 255-ultimo.avi
|
||||||
|
|
||||||
|
+ 001-otrodir
|
||||||
|
- 000-otrapeli.mov
|
||||||
|
- 001-maspelis.mov
|
||||||
|
...
|
||||||
|
- 255.ultimodelasegundacarpeta.mov
|
||||||
|
+ 002-fuego
|
||||||
|
- 000-Boladefuego.avi
|
||||||
|
- 001-Murodefuego.avi
|
||||||
|
...
|
||||||
|
- 255-fuentedefuego.avi
|
||||||
|
...
|
||||||
|
|
||||||
|
+ 255-ultimodir
|
||||||
|
+255.ultimapeli.mov
|
||||||
|
+ audio
|
||||||
|
+ 000-mifichero.ogg
|
||||||
|
|
||||||
|
...
|
||||||
|
|
||||||
|
+ 255-miultimofichero.ogg
|
||||||
|
+ fonts
|
||||||
|
- 000-mifuente.ttf
|
||||||
|
...
|
||||||
|
- 255-miultimafuente.ttf
|
||||||
|
+ images
|
||||||
|
- 000-miprimerafoto.jpg
|
||||||
|
...
|
||||||
|
- 255-miultimafoto.jpg
|
||||||
|
|
||||||
|
Los números al principio de ficheros y directorios no son obligatorios, pero ayudan mucho a organizar el material. PMS busca por orden alfabético en los directorios/ficheros, y ese orden es el que hay que los valores de los canales Folder y File para reproducirlos.
|
||||||
|
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Textos:
|
||||||
|
|
||||||
|
Puedes definir hasta 255 frases editando con un editor ASCII el fichero text.txt. El formato es:
|
||||||
|
|
||||||
|
1, Esto es una frase;
|
||||||
|
2, El número es el valor del canal 6 de la capa folder;
|
||||||
|
3, no se pueden usar comas;
|
||||||
|
4, las frases tienen que acabar con punto y coma;
|
||||||
|
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Listado de canales DMX:
|
||||||
|
|
||||||
|
PureMediaServer Video:
|
||||||
|
|
||||||
|
Entre paréntesis el valor normal de uso (locate).
|
||||||
|
|
||||||
|
1 Alpha/Dimmer (255)
|
||||||
|
2 Rojo (127)
|
||||||
|
3 Verde (127)
|
||||||
|
4 Azul (127)
|
||||||
|
5 Speed (40; esto se corresponde a 25 fps. El valor del canal son los milisegundos del metro, por lo que la inversa es el valor real de FPS).
|
||||||
|
0-244: Velocidad
|
||||||
|
245-249: Autodeteccion fps, una sola vez
|
||||||
|
250-255: Autodeteccion fps, loop
|
||||||
|
|
||||||
|
En los modos auto el inicio y el fin del loop no son aplicables, se reproduce la película completa.
|
||||||
|
|
||||||
|
6 Directorio / Texto
|
||||||
|
7 Archivo / Fuente
|
||||||
|
8 Tipo de Media
|
||||||
|
0-24: OFF
|
||||||
|
25-49: Video
|
||||||
|
50-75: Imagenes
|
||||||
|
75-99: Texto
|
||||||
|
9 Reproduccion: Valores en 100%
|
||||||
|
00-10 Normal loop
|
||||||
|
11-20 Back loop
|
||||||
|
21-30 Ping-pong loop
|
||||||
|
31-40 Normal una vez
|
||||||
|
41-50 Back una vez
|
||||||
|
51-60 Ping-Pong una vez
|
||||||
|
61-70 Stop/pause
|
||||||
|
71-80 Continue
|
||||||
|
10 Inicio loop (0 principio peli- 255 final) (0)
|
||||||
|
11 Final Loop (0 principio peli - 255 final) (255)
|
||||||
|
12 Rotate X (0)
|
||||||
|
13 Rotate Y (0)
|
||||||
|
14 Rotate Z (0)
|
||||||
|
15 Size X Size Font (127)
|
||||||
|
16 Size Y (127)
|
||||||
|
17 Z (127)
|
||||||
|
18 X (127)
|
||||||
|
19 Y (127)
|
||||||
|
20 X Fino (127)
|
||||||
|
21 Y Fino (127)
|
||||||
|
|
||||||
|
Los siguientes canales son usados para transparencias
|
||||||
|
|
||||||
|
Los High filtran los pixeles con ese y los convierte en transparente (croma)
|
||||||
|
|
||||||
|
22 Alpha High Red (255)
|
||||||
|
23 Alpha High Green (255)
|
||||||
|
24 Alpha High Blue (255)
|
||||||
|
|
||||||
|
Los Low filtran todo menos los pixel con ese valor (máscara)
|
||||||
|
|
||||||
|
25 Alpha Low Red (0)
|
||||||
|
26 Alpha Low Green (0)
|
||||||
|
27 Alpha Low Blue (0)
|
||||||
|
|
||||||
|
Los siguientes canales se usan para correción de keystone y videomapping. Hay configuración por capa, el resto de configuraciones de posición y tamaño se reajustarán dentro de la nueva capa
|
||||||
|
|
||||||
|
28 Corner Bottom Left X (0)
|
||||||
|
29 Corner Bottom Left Y (0)
|
||||||
|
30 Corner Top Left X (0)
|
||||||
|
31 Corner Top Left Y (255)
|
||||||
|
32 Corner Bottom Right X (255)
|
||||||
|
33 Corner Bottom Right Y (0)
|
||||||
|
34 Corner Top Right X (255)
|
||||||
|
35 Corner Top Right Y (255)
|
||||||
|
|
||||||
|
Los siguientes canales son usados para control de efectos
|
||||||
|
|
||||||
|
36 Selección FX 1
|
||||||
|
37 Selección FX 2
|
||||||
|
38 Param 1 FX 1
|
||||||
|
39 Param 2 FX 1
|
||||||
|
40 Param 3 FX 1
|
||||||
|
41 Param 4 FX 1
|
||||||
|
42 Param 5 FX 1
|
||||||
|
43 Param 6 FX 1
|
||||||
|
44 Param 7 FX 1
|
||||||
|
45 Param 8 FX 1
|
||||||
|
|
||||||
|
46 - Blending Mode. Este canal elige el tipo de mezcla entre capas. Se corresponde a los modos de mezcla OpenGL:
|
||||||
|
|
||||||
|
0: GL_ONE_MINUS_SRC_ALPHA;
|
||||||
|
1: GL_ONE;
|
||||||
|
2: GL_ZERO;
|
||||||
|
3: GL_SRC_COLOR;
|
||||||
|
4: GL_ONE_MINUS_SRC_COLOR; (Locate, mezcla normal)
|
||||||
|
5: GL_DST_COLOR;
|
||||||
|
6: GL_ONE_MINUS_DST_COLOR;
|
||||||
|
7: GL_SRC_ALPHA;
|
||||||
|
8: GL_ONE_MINUS_SRC_ALPHA;
|
||||||
|
9: GL_DST_ALPHA;
|
||||||
|
10: GL_ONE_MINUS_DST_ALPHA;
|
||||||
|
11: GL_CONSTANT_COLOR;
|
||||||
|
12: GL_ONE_MINUS_CONSTANT_COLOR;
|
||||||
|
13: GL_CONSTANT_ALPHA;
|
||||||
|
14: GL_ONE_MINUS_CONSTANT_ALPHA;
|
||||||
|
15: GL_SRC_ALPHA_SATURATE;
|
||||||
|
16: GL_SRC1_COLOR;
|
||||||
|
17: GL_ONE_MINUS_SRC1_COLOR;
|
||||||
|
18: GL_SRC1_ALPHA;
|
||||||
|
19: GL_ONE_MINUS_SRC1_ALPHA;
|
||||||
|
20: GL_ONE_MINUS_SRC_ALPHA;
|
||||||
|
|
||||||
|
Más información sobre los distintos tipos de blending en http://www.opengl.org/wiki/GLAPI/glBlendFunc.
|
||||||
|
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Efectos Video:
|
||||||
|
|
||||||
|
0 - No effect
|
||||||
|
1 - Bitmask
|
||||||
|
Fx 1 All (255)
|
||||||
|
Fx 2 Red (255)
|
||||||
|
Fx 3 Green (255)
|
||||||
|
Fx 4 Blue (255)
|
||||||
|
2 - Halftone
|
||||||
|
FX 1 Size
|
||||||
|
FX 2 Angle
|
||||||
|
FX 3 Smooth
|
||||||
|
FX 4 Style
|
||||||
|
3 - Rds
|
||||||
|
FX 1 Method
|
||||||
|
FX 2 Stride
|
||||||
|
4 - Roll
|
||||||
|
FX 1 Axis
|
||||||
|
FX 2 Roll
|
||||||
|
5 - Invert
|
||||||
|
FX 1 On/Off
|
||||||
|
6 - Scanline
|
||||||
|
FX 1 Mode
|
||||||
|
Fx 2 Interlace
|
||||||
|
7 - Threshold
|
||||||
|
FX 1 All
|
||||||
|
FX 2 Red
|
||||||
|
Fx 3 Green
|
||||||
|
Fx 4 Blue
|
||||||
|
8 - Metaimage
|
||||||
|
FX 1 Cheap
|
||||||
|
FX 2 Distance
|
||||||
|
FX 3 Size
|
||||||
|
9 - Refraction
|
||||||
|
FX 1 Width
|
||||||
|
FX 2 Height
|
||||||
|
FX 3 Mag
|
||||||
|
FX 4 Refract
|
||||||
|
10 - Convolve
|
||||||
|
FX 1 Escala
|
||||||
|
FX 2 Modo (none, smooth, edge1, edge2)
|
||||||
|
11 - Gain
|
||||||
|
FX 1 Common
|
||||||
|
FX 2 Red
|
||||||
|
FX 3 Green
|
||||||
|
FX 4 Blue
|
||||||
|
12 - Lumaoffset
|
||||||
|
FX 1 Fill On/Off
|
||||||
|
FX 2 Smooth On/Off
|
||||||
|
FX 3 Gap
|
||||||
|
FX 4 Offset
|
||||||
|
13 - tIIR
|
||||||
|
FX 1 Feedback 1
|
||||||
|
FX 2 Feedback 2
|
||||||
|
FX 3 Feedback 3
|
||||||
|
FX 4 Feedforward 1
|
||||||
|
FX 5 Feedforward 2
|
||||||
|
14 - rtx
|
||||||
|
FX 1 Clamp discontinuity to the edge (On/Off)
|
||||||
|
15 - Normalize
|
||||||
|
No Params
|
||||||
|
16 - Kaleidoskope
|
||||||
|
FX 1 Segments
|
||||||
|
FX 2 Source Angle
|
||||||
|
FX 3 X
|
||||||
|
FX 4 Y
|
||||||
|
FX 5 cX
|
||||||
|
FX 6 CY
|
||||||
|
FX 7 RLP
|
||||||
|
FX 8 SAP
|
||||||
|
|
||||||
|
**************
|
||||||
|
|
||||||
|
PureMediaServer Audio:
|
||||||
|
|
||||||
|
1 - Volumen Coarse
|
||||||
|
2 - Pan
|
||||||
|
3 - Folder
|
||||||
|
4 - File
|
||||||
|
5 - Playback
|
||||||
|
6 - Control
|
||||||
|
7 - Volume Fine
|
||||||
|
8 - Entry Point Coarse - El valor de estos dos canales en centésimas de segundo.
|
||||||
|
9 - Entry Point Fine
|
22
doc/manual_en.txt
Normal file
22
doc/manual_en.txt
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Sorry, only in spanish at the moment: manual_es.txt
|
350
doc/manual_es.txt
Normal file
350
doc/manual_es.txt
Normal file
|
@ -0,0 +1,350 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Lee instalacion.txt para el proceso de instalación.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media server es un programa para gestionar visuales en artes escénicas, eventos, performances, instalaciones,...
|
||||||
|
|
||||||
|
Se controla mediante el Open Lighting Arquitecture que soporta una gran variedad de protocolos y dispositivos estandard de iluminación: Artnet, ShowNet, PathPort, ACN, Enttec Open DMX Pro,...
|
||||||
|
|
||||||
|
Puedes controlarlo gratis con el programa MagicQ de ChamSys si no dispones de ninguna mesa o programa de iluminación. No es software libre, pero al menos es gratis y multiplataforma. En la versión más moderna ahora (1.5.7.5) para GNU/Linux no funcionan los thumbnails, en Win sí. En la carpeta "MagicQ" hay un archivo de show y los archivos de personalidad, para audio y video.
|
||||||
|
|
||||||
|
El motor gráfico y de audio es Pure Data, que se ejecuta en background invisible al usuario. Ahora mismo podemos reproducir 255 carpetas con 255 videos cada una en cualquier formato en que esté el codec instalado en el sistema. Si lo puede leer en el reproductor de medios de gnome podrá reproducirlo LMS. También podemos reproducir fotos y textos. El reproductor de medios podemos variar la velocidad, ejecutarlo en distintas direcciones (hacia delante, hacia atrás, ping-pong), y en bucle o en un sólo disparo.
|
||||||
|
|
||||||
|
LMS tiene 8 capas de video o texto, cada dispone de una correción Bezier de 4 puntos, por lo que podemos mapear diferentes superficies, o lados de objetos. También podemos corregir el keystone mediante estos ajustes. Por supuesto, hay ajustes de color, posición, tamaño y rotación por cada capa.
|
||||||
|
|
||||||
|
Las mezclas entre capas se realizan mediante 7 canales: 3 canales pasa altos RGB, 3 canales Pasabajos RGB, con lo que se puden hacer lumas y cromas entre capas, y otro canal que define el método OpenGL de blending. El orden de las capas se controla mediante el canal de posición Z: cuanto más grande sea más al fondo se encuentra. Si no el orden de prioridad es cuanto más pequeño el número de capa más prioridad tiene (la capa 1 es la más prioritaria).
|
||||||
|
|
||||||
|
También podemos manejar 8 capas de audio, cada una reproduciendo un archivo .ogg. El control de volumen es en 16 bits de precisión y logarítmico.
|
||||||
|
|
||||||
|
El interface gráfico es muy simple, sólo sirve para manejar la configuración de Pure Data y sirve para ver el archivo que cada capa está reproduciendo. Tenemos dos pestañas: Una para la configuración de Video y otra para la de Audio. Cada capa de audio y/o video se deberá patchear en la mesa independientemente. Los dos procesos son independientes y pueden funcionar individualmente o conjuntamente.
|
||||||
|
Como los controles son parecidos para las dos ventanas, las explicamos juntas. Empezando de arriba hacia abajo:
|
||||||
|
|
||||||
|
A. Terminal. Se muestran mensajes de estado y de error. Común a las dos capas.
|
||||||
|
|
||||||
|
B. 8 Capas. Representan las 8 capas de video.
|
||||||
|
|
||||||
|
- B.1 Ventana de Preview. Muestra el archivo que está siendo reproducido en la capa, sin efectos ni modificaciones. Funciona a 1 frame por segundo.
|
||||||
|
- B.2 Botón de activado de la capa. Si no está en on la capa no está activada y no renderiza, se quedará en la pantalla el último frame renderizado; desactivando no va a negro.
|
||||||
|
- B.3 Dirección DMX. Hay que introducir el primer canal DMX de la capa, la misma a la que se patcheó en la mesa.
|
||||||
|
|
||||||
|
C. Change Media Path. Cambia el path al árbol de directorios de los media. Este control es común para el video y el audio, sólo hace falta introducirlo una vez, aunque se muestra en las dos pestañas.
|
||||||
|
|
||||||
|
D. Video/Audio. Inicia o detiene los procesos de video y de audio.
|
||||||
|
|
||||||
|
F. ReadDMX. Empieza o termina la lectura de datos DMX
|
||||||
|
|
||||||
|
H. OLA Universe. El universo de Open Lighting Arquitecture que hemos configurado como entrada y al que el proceso escuchará. Ver instalacion.txt para detalles y configuración de OLA..
|
||||||
|
|
||||||
|
G. Window. Crea y destruye la ventana de reproducción.
|
||||||
|
|
||||||
|
I. Window Position. Posición de la ventana de renderizado en pixeles x,y.
|
||||||
|
|
||||||
|
J. Window Size. Tamaño de la ventana de renderizado en pixeles x, y.
|
||||||
|
|
||||||
|
K. IP Adress. Dirección IP de la interface que queremos usar para el CITP/MSEx. Dejar en 0.0.0.0 para todas las interfaces.
|
||||||
|
|
||||||
|
E. Init CITP/MSEx. Inicia el peer CITP y manda los thumbs si alguna mesa lo solicita.
|
||||||
|
|
||||||
|
F. Venta de preview. La ventana grande es un preview de la mezcla final. Funciona a 2 frames por segundo.
|
||||||
|
|
||||||
|
El CITP/MSEx no funciona en el interface localhost. Sin embargo la recepción de datos ArtNet sí. Necesita tener un interface de red activo en el momento de lanzar el programa, pero después se puede desconectar. Se puede usar en el mismo ordenador LMS y MagicQLinux para controlarlo.
|
||||||
|
|
||||||
|
Generación de thumbs:
|
||||||
|
|
||||||
|
Es necesario generar lo thumbnails de tus medias para poder transmitirlos por CITP/MSEx. Lo puedes hacer mediante el fichero make_thumbs.sh en la carpeta scripts. Primero ábrelo con un editor de texto y edita el path a tus medias. Guarda, cierra, y ejecuta el archivo. Debería de crear una subcarpeta llamada thumbs por cada carpeta de medias, y en ella el thumbnail con el primer fotograma de cada archivo, con el mismo nombre, pero acabado en jpeg. En siguientes versiones intentaré integrar esto cuando se pulse el botón "Init CITP/MSEx".
|
||||||
|
|
||||||
|
La ventana de renderizado se muestra sobre todas las demás ventanas y sin que aparezca el cursor en ella. Si tenemos problemas en la configuración, por ejemplo nos quedamos sin ver el escritorio, siempre podemos llevar el cursor a la ventana de renderizado y presionar Escape para cerrarla. La posición de la ventana se configura con los controles "Window Position" y el tamaño de la ventana con "Window Size", los dos primero el ancho y después el alto. Para hacer algo útil deberemos tener el escritorio extendido a un segundo monitor y configurar en estos controles los valores de ese monitor. Para aplicar cambios hay que cerrar la ventana y reabrirla.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Estructura de medias:
|
||||||
|
|
||||||
|
Los archivos de medios que utiliza LMS deben de estar ordenados en un árbol de ficheros. La dirección superior del árbol es la que se tiene que introducir en el archivo scripts/make_thumbs.sh y configurar en LMS mediante el botón "Change media Path".
|
||||||
|
|
||||||
|
El árbol de ficheros tiene el siguiente esquema:
|
||||||
|
|
||||||
|
+ media
|
||||||
|
+ video
|
||||||
|
+ 000-descripcion
|
||||||
|
- 000-miloop.mov
|
||||||
|
- 001-milooocool.avi
|
||||||
|
- 002-mipelo.mpg
|
||||||
|
...
|
||||||
|
- 255-ultimo.avi
|
||||||
|
|
||||||
|
+ 001-otrodir
|
||||||
|
- 000-otrapeli.mov
|
||||||
|
- 001-maspelis.mov
|
||||||
|
...
|
||||||
|
- 255.ultimodelasegundacarpeta.mov
|
||||||
|
|
||||||
|
+ 002-fuego
|
||||||
|
- 000-Boladefuego.avi
|
||||||
|
- 001-Murodefuego.avi
|
||||||
|
...
|
||||||
|
- 255-fuentedefuego.avi
|
||||||
|
|
||||||
|
...
|
||||||
|
|
||||||
|
+ 255-ultimodir
|
||||||
|
+255.ultimapeli.mov
|
||||||
|
|
||||||
|
+ audio
|
||||||
|
+ 000-miprimealbum
|
||||||
|
- 000-mifichero.ogg
|
||||||
|
...
|
||||||
|
- 255-miultimofichero.ogg
|
||||||
|
|
||||||
|
+ 001-misegundoalbum
|
||||||
|
- 000-mifichero.ogg
|
||||||
|
...
|
||||||
|
- 255-miultimofichero.ogg
|
||||||
|
|
||||||
|
...
|
||||||
|
+ 255-miultimoalbum
|
||||||
|
- 000-mifichero.ogg
|
||||||
|
...
|
||||||
|
- 255-miultimofichero.ogg
|
||||||
|
|
||||||
|
+ fonts
|
||||||
|
- 000-mifuente.ttf
|
||||||
|
...
|
||||||
|
- 255-miultimafuente.ttf
|
||||||
|
|
||||||
|
+ images
|
||||||
|
- 000-miprimerafoto.jpg
|
||||||
|
...
|
||||||
|
- 255-miultimafoto.jpg
|
||||||
|
|
||||||
|
Los números al principio de ficheros y directorios no son obligatorios, pero ayudan mucho a organizar el material. LMS busca por orden alfabético en los directorios/ficheros, y ese orden es el que determina los valores de los canales Folder y File para reproducirlos.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Textos:
|
||||||
|
|
||||||
|
Puedes definir hasta 255 frases editando con un editor ASCII el fichero text.txt. El formato es:
|
||||||
|
|
||||||
|
1, Esto es una frase;
|
||||||
|
2, El número es el valor del canal 6 folder;
|
||||||
|
3, no se pueden usar comas;
|
||||||
|
4, las frases tienen que acabar con punto y coma;
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Listado de canales DMX:
|
||||||
|
|
||||||
|
LibreMediaServer Video:
|
||||||
|
|
||||||
|
Entre paréntesis el valor normal de uso (locate).
|
||||||
|
|
||||||
|
1 Alpha/Dimmer (255)
|
||||||
|
2 Rojo (127)
|
||||||
|
3 Verde (127)
|
||||||
|
4 Azul (127)
|
||||||
|
5 Speed (40; esto se corresponde a 25 fps. El valor del canal son los milisegundos del metro, por lo que la inversa es el valor real de FPS).
|
||||||
|
|
||||||
|
0-244: Velocidad de reproducción.
|
||||||
|
245-249: Autodeteccion de fps, una sola vez. Se reproducirá a la velocidad de la película.
|
||||||
|
250-255: Autodeteccion de fps, loop
|
||||||
|
|
||||||
|
En los modos auto el inicio y fin de loop no son aplicables, se reproduce la película completa en modo Normal (ver canal 9).
|
||||||
|
|
||||||
|
6 Directorio / Texto
|
||||||
|
7 Archivo / Fuente
|
||||||
|
8 Tipo de Media
|
||||||
|
0-24: OFF
|
||||||
|
25-49: Video
|
||||||
|
50-75: Imagenes
|
||||||
|
75-99: Texto
|
||||||
|
9 Modos de Reproduccion (Sólo aplicable si canal 5 < 245):
|
||||||
|
00-24 Normal loop
|
||||||
|
25-49 Back loop
|
||||||
|
50-74 Ping-pong loop
|
||||||
|
75-99 Normal una vez
|
||||||
|
100-124 Back una vez
|
||||||
|
125-149 Ping-Pong una vez
|
||||||
|
150-174 Stop/pause
|
||||||
|
175-200 Continue/Play
|
||||||
|
10 Inicio loop (0 principio peli- 255 final) (0)
|
||||||
|
11 Final Loop (0 principio peli - 255 final) (255)
|
||||||
|
12 Rotate X (0)
|
||||||
|
13 Rotate Y (0)
|
||||||
|
14 Rotate Z (0)
|
||||||
|
15 Size X (127)
|
||||||
|
16 Size Y (127)
|
||||||
|
17 Z (127)
|
||||||
|
18 X (127)
|
||||||
|
19 Y (127)
|
||||||
|
20 X Fino (127)
|
||||||
|
21 Y Fino (127)
|
||||||
|
|
||||||
|
Los siguientes canales son usados para lumas y cromas.
|
||||||
|
Los High filtran los pixeles con ese valor o superior y los convierte en transparente (croma)
|
||||||
|
|
||||||
|
22 Alpha High Red (255)
|
||||||
|
23 Alpha High Green (255)
|
||||||
|
24 Alpha High Blue (255)
|
||||||
|
|
||||||
|
Los Low filtran los pixeles con ese valor o inferior (máscara).
|
||||||
|
|
||||||
|
25 Alpha Low Red (0)
|
||||||
|
26 Alpha Low Green (0)
|
||||||
|
27 Alpha Low Blue (0)
|
||||||
|
|
||||||
|
Los siguientes canales se usan para correción de keystone y videomapping. Hay configuración por capa, el resto de configuraciones de posición y tamaño se reajustarán dentro de la nueva capa
|
||||||
|
|
||||||
|
28 Corner Bottom Left X (0)
|
||||||
|
29 Corner Bottom Left Y (0)
|
||||||
|
30 Corner Top Left X (0)
|
||||||
|
31 Corner Top Left Y (255)
|
||||||
|
32 Corner Bottom Right X (255)
|
||||||
|
33 Corner Bottom Right Y (0)
|
||||||
|
34 Corner Top Right X (255)
|
||||||
|
35 Corner Top Right Y (255)
|
||||||
|
|
||||||
|
Los siguientes canales son usados para control de efectos
|
||||||
|
|
||||||
|
36 Selección FX 1 - Ver abajo para lista de efectos.
|
||||||
|
37 Selección FX 2 (Reservado - No Implementado todavía).
|
||||||
|
38 Param 1 FX 1
|
||||||
|
39 Param 2 FX 1
|
||||||
|
40 Param 3 FX 1
|
||||||
|
41 Param 4 FX 1
|
||||||
|
42 Param 5 FX 1
|
||||||
|
43 Param 6 FX 1
|
||||||
|
44 Param 7 FX 1
|
||||||
|
45 Param 8 FX 1
|
||||||
|
|
||||||
|
46 - Blending Mode. Este canal elige el tipo de mezcla entre capas. Se corresponde a los modos de mezcla OpenGL:
|
||||||
|
|
||||||
|
0: GL_ONE_MINUS_SRC_ALPHA;
|
||||||
|
1: GL_ONE;
|
||||||
|
2: GL_ZERO;
|
||||||
|
3: GL_SRC_COLOR;
|
||||||
|
4: GL_ONE_MINUS_SRC_COLOR; (Locate, mezcla normal)
|
||||||
|
5: GL_DST_COLOR;
|
||||||
|
6: GL_ONE_MINUS_DST_COLOR;
|
||||||
|
7: GL_SRC_ALPHA;
|
||||||
|
8: GL_ONE_MINUS_SRC_ALPHA;
|
||||||
|
9: GL_DST_ALPHA;
|
||||||
|
10: GL_ONE_MINUS_DST_ALPHA;
|
||||||
|
11: GL_CONSTANT_COLOR;
|
||||||
|
12: GL_ONE_MINUS_CONSTANT_COLOR;
|
||||||
|
13: GL_CONSTANT_ALPHA;
|
||||||
|
14: GL_ONE_MINUS_CONSTANT_ALPHA;
|
||||||
|
15: GL_SRC_ALPHA_SATURATE;
|
||||||
|
16: GL_SRC1_COLOR;
|
||||||
|
17: GL_ONE_MINUS_SRC1_COLOR;
|
||||||
|
18: GL_SRC1_ALPHA;
|
||||||
|
19: GL_ONE_MINUS_SRC1_ALPHA;
|
||||||
|
20: GL_ONE_MINUS_SRC_ALPHA;
|
||||||
|
|
||||||
|
Más información sobre los distintos tipos de blending en http://www.opengl.org/wiki/GLAPI/glBlendFunc.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Efectos Video:
|
||||||
|
|
||||||
|
0 - No effect
|
||||||
|
1 - Bitmask
|
||||||
|
Fx 1 All (255)
|
||||||
|
Fx 2 Red (255)
|
||||||
|
Fx 3 Green (255)
|
||||||
|
Fx 4 Blue (255)
|
||||||
|
2 - Halftone
|
||||||
|
FX 1 Size
|
||||||
|
FX 2 Angle
|
||||||
|
FX 3 Smooth
|
||||||
|
FX 4 Style
|
||||||
|
3 - Rds
|
||||||
|
FX 1 Method
|
||||||
|
FX 2 Stride
|
||||||
|
4 - Roll
|
||||||
|
FX 1 Axis
|
||||||
|
FX 2 Roll
|
||||||
|
5 - Invert
|
||||||
|
FX 1 On/Off
|
||||||
|
6 - Scanline
|
||||||
|
FX 1 Mode
|
||||||
|
Fx 2 Interlace
|
||||||
|
7 - Threshold
|
||||||
|
FX 1 All
|
||||||
|
FX 2 Red
|
||||||
|
Fx 3 Green
|
||||||
|
Fx 4 Blue
|
||||||
|
8 - Metaimage
|
||||||
|
FX 1 Cheap
|
||||||
|
FX 2 Distance
|
||||||
|
FX 3 Size
|
||||||
|
9 - Refraction
|
||||||
|
FX 1 Width
|
||||||
|
FX 2 Height
|
||||||
|
FX 3 Mag
|
||||||
|
FX 4 Refract
|
||||||
|
10 - Convolve
|
||||||
|
FX 1 Escala
|
||||||
|
FX 2 Modo (none, smooth, edge1, edge2)
|
||||||
|
11 - Gain
|
||||||
|
FX 1 Common
|
||||||
|
FX 2 Red
|
||||||
|
FX 3 Green
|
||||||
|
FX 4 Blue
|
||||||
|
12 - Lumaoffset
|
||||||
|
FX 1 Fill On/Off
|
||||||
|
FX 2 Smooth On/Off
|
||||||
|
FX 3 Gap
|
||||||
|
FX 4 Offset
|
||||||
|
13 - tIIR
|
||||||
|
FX 1 Feedback 1
|
||||||
|
FX 2 Feedback 2
|
||||||
|
FX 3 Feedback 3
|
||||||
|
FX 4 Feedforward 1
|
||||||
|
FX 5 Feedforward 2
|
||||||
|
14 - rtx
|
||||||
|
FX 1 Clamp discontinuity to the edge (On/Off)
|
||||||
|
15 - Normalize
|
||||||
|
No Params
|
||||||
|
16 - Kaleidoskope
|
||||||
|
FX 1 Segments
|
||||||
|
FX 2 Source Angle
|
||||||
|
FX 3 X
|
||||||
|
FX 4 Y
|
||||||
|
FX 5 cX
|
||||||
|
FX 6 CY
|
||||||
|
FX 7 RLP
|
||||||
|
FX 8 SAP
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
PureMediaServer Audio:
|
||||||
|
|
||||||
|
1 - Volumen Coarse
|
||||||
|
2 - Pan
|
||||||
|
3 - Folder
|
||||||
|
4 - File
|
||||||
|
5 - Playback
|
||||||
|
6 - Control
|
||||||
|
7 - Volume Fine
|
||||||
|
8 - Entry Point Coarse - El valor de estos dos canales en centésimas de segundo.
|
||||||
|
9 - Entry Point Fine
|
49
doc/readme.txt
Normal file
49
doc/readme.txt
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Pure Media Server is an Open Source project to manage visuals and audio in stage, perfomances, installations, events,,...,
|
||||||
|
|
||||||
|
The control input is through Open Lighting Arquitecture, so we can use any open lighting protocolo (ArtNet, PathPort, ShowNet, ACN, SandNet,...) or DMX-USB device (Enttec USB DMX Pro, Velleman, Anyuma,..).
|
||||||
|
|
||||||
|
The graphic and audio engine are two Pure Data process running in the background. You will need a graphics card OpenGL capable and the driver for it
|
||||||
|
correctly installed.
|
||||||
|
|
||||||
|
I'm developing and testing in Debian Wheezy and Ubuntu precise 12.04. It should compile and work in anothers Debian based distros.
|
||||||
|
|
||||||
|
Features:
|
||||||
|
|
||||||
|
- 8 video, pictures or text layers.
|
||||||
|
- 8 audio layers.
|
||||||
|
- Advanced playback (normal, back, ping.pong, entry point, exit point, speed, loop).
|
||||||
|
- Each layer can be mapped onto a surface with 4 point of Bèzier.
|
||||||
|
- A lot of formats: avi, mov, mpg, HD,...
|
||||||
|
- Some video effects.
|
||||||
|
- Position, Rotation, Size.
|
||||||
|
- Croma/Luma mask.
|
||||||
|
- Text through a text file, with 255 phrases.
|
||||||
|
|
||||||
|
Sorry, at the moment the doc is only in spanish:
|
||||||
|
|
||||||
|
Install guide : instalacion.txt
|
||||||
|
|
||||||
|
Users guide : manual.txt
|
||||||
|
|
||||||
|
|
54
doc/todo.txt
Normal file
54
doc/todo.txt
Normal file
|
@ -0,0 +1,54 @@
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Libre Media Server - An Open source Media Server.
|
||||||
|
(c) Santiago Noreña 2012-2013
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Developing and support: libremediaserver@gmail.com
|
||||||
|
|
||||||
|
Code: http://code.google.com/p/libremediaserver
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Próximas versiones:
|
||||||
|
|
||||||
|
- Pure Data Video: Modularidad, sumar ventanas por instancias de PMS-video. NO SE PUEDE POR USAR LOS MISMOS PUERTOS. Opción de arranque?. Blending entre proyectores.Mirar ejemplo Gem multiprojection. Añdir shaders a la capa?
|
||||||
|
- Pure Data Video: Cambiar alpha por glgs. Mirar ejemplos en doc de Gem. Mirar requerimientos de tarjetas gráficas. Añadir shaders glgs.
|
||||||
|
- GUI: Cuadro de diálogo en open/save para diferentes archivos de configuración.
|
||||||
|
- GUI: Mover la configuración de ip address a un menú.
|
||||||
|
- GUI: Configuración para anular los previews y salvar tiempo de proceso.
|
||||||
|
- Conectividad: CITP/MSEx 1.1. Thumbs y previews de imágenes.
|
||||||
|
- Pure Data: Carpetas para imágenes y sonidos. Diferentes ficheros de texto.
|
||||||
|
- Pure Data: sincronismo de audio con videos --> Parece que hay que hacer un script para separar el audio del video, y luego ejecutarlos juntos. Un poco chapu, la verdad. La aternativa es volver a pdp mediante pdp2gem (inviable, demasiado proceso) --> De momento separando el .ogg del video, ejecutando en auto, y mandando play a la vez debería de estar sincronizados. Ahora mismo se podría separando el audio en un fichero .ogg y presionando el play a la vez en modo auto.
|
||||||
|
- Documentación en inglés.
|
||||||
|
- Medidor de CPU en el GUI
|
||||||
|
- Incluir archivos en el ejecutable como recursos Qt --> Podrá leer Pure Data los .pd_linux?
|
||||||
|
- Audio: Theremin, sintetizadores.
|
||||||
|
- Audio: Música fractal mediante generadores de fx de las mesas
|
||||||
|
- Audio: Tarjetas con varias salidas y varias mezclas.
|
||||||
|
- Video: Live input
|
||||||
|
- Empaquetar en .deb
|
||||||
|
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
Para considerar:
|
||||||
|
|
||||||
|
- Necesidad de 16 bits en size, rotation, entry-end points, puntos de bezier?
|
||||||
|
- Más puntos de Bezier?
|
||||||
|
- Hacer external con reproductor de pix_film --> Merece la pena codificarlo en C una vez hecho en PD? Ahorrará consumo de CPU?
|
||||||
|
- GUI: PD Watchdog reinicia --> Puede que sea mejor que se reproduzca más lento a forzar un reinicio?
|
||||||
|
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
Descartados:
|
||||||
|
|
||||||
|
- Separar textos en otra personalidad --> No posible, al iniciar un nuevo proceso inicia una nueva ventana- Malo para textos, bueno para varios proyectores y blending!. Investigar soft edge.
|
22
externals/artnetin/ChangeLog.txt
vendored
Executable file
22
externals/artnetin/ChangeLog.txt
vendored
Executable file
|
@ -0,0 +1,22 @@
|
||||||
|
***********************************
|
||||||
|
Artnetin
|
||||||
|
Santiago Noreña 2011-2012
|
||||||
|
puremediaserver@gmail.com
|
||||||
|
***********************************
|
||||||
|
|
||||||
|
* 0.0.3 (5/02/2012) SVN Rev 94
|
||||||
|
|
||||||
|
- Thread independiente
|
||||||
|
- Cambio de nombres: Open y close
|
||||||
|
- Comprobación de nodo activo antes de intentar crear otro
|
||||||
|
- Método free y comprobación antes de salir
|
||||||
|
|
||||||
|
* 0.0.2 (9-06-2011) SVN Rev 58
|
||||||
|
|
||||||
|
- Añadidos métodos "create" y "destroy" para manejar el nodo Art-Net
|
||||||
|
- Configuración de universo y subnet mediante patch (issue 14).
|
||||||
|
- Limpieza Makefile.am
|
||||||
|
|
||||||
|
* 0.0.1 (16-05-2011)
|
||||||
|
|
||||||
|
- Primera versión!
|
676
externals/artnetin/LICENSE.txt
vendored
Executable file
676
externals/artnetin/LICENSE.txt
vendored
Executable file
|
@ -0,0 +1,676 @@
|
||||||
|
|
||||||
|
GNU GENERAL PUBLIC LICENSE
|
||||||
|
Version 3, 29 June 2007
|
||||||
|
|
||||||
|
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||||
|
Everyone is permitted to copy and distribute verbatim copies
|
||||||
|
of this license document, but changing it is not allowed.
|
||||||
|
|
||||||
|
Preamble
|
||||||
|
|
||||||
|
The GNU General Public License is a free, copyleft license for
|
||||||
|
software and other kinds of works.
|
||||||
|
|
||||||
|
The licenses for most software and other practical works are designed
|
||||||
|
to take away your freedom to share and change the works. By contrast,
|
||||||
|
the GNU General Public License is intended to guarantee your freedom to
|
||||||
|
share and change all versions of a program--to make sure it remains free
|
||||||
|
software for all its users. We, the Free Software Foundation, use the
|
||||||
|
GNU General Public License for most of our software; it applies also to
|
||||||
|
any other work released this way by its authors. You can apply it to
|
||||||
|
your programs, too.
|
||||||
|
|
||||||
|
When we speak of free software, we are referring to freedom, not
|
||||||
|
price. Our General Public Licenses are designed to make sure that you
|
||||||
|
have the freedom to distribute copies of free software (and charge for
|
||||||
|
them if you wish), that you receive source code or can get it if you
|
||||||
|
want it, that you can change the software or use pieces of it in new
|
||||||
|
free programs, and that you know you can do these things.
|
||||||
|
|
||||||
|
To protect your rights, we need to prevent others from denying you
|
||||||
|
these rights or asking you to surrender the rights. Therefore, you have
|
||||||
|
certain responsibilities if you distribute copies of the software, or if
|
||||||
|
you modify it: responsibilities to respect the freedom of others.
|
||||||
|
|
||||||
|
For example, if you distribute copies of such a program, whether
|
||||||
|
gratis or for a fee, you must pass on to the recipients the same
|
||||||
|
freedoms that you received. You must make sure that they, too, receive
|
||||||
|
or can get the source code. And you must show them these terms so they
|
||||||
|
know their rights.
|
||||||
|
|
||||||
|
Developers that use the GNU GPL protect your rights with two steps:
|
||||||
|
(1) assert copyright on the software, and (2) offer you this License
|
||||||
|
giving you legal permission to copy, distribute and/or modify it.
|
||||||
|
|
||||||
|
For the developers' and authors' protection, the GPL clearly explains
|
||||||
|
that there is no warranty for this free software. For both users' and
|
||||||
|
authors' sake, the GPL requires that modified versions be marked as
|
||||||
|
changed, so that their problems will not be attributed erroneously to
|
||||||
|
authors of previous versions.
|
||||||
|
|
||||||
|
Some devices are designed to deny users access to install or run
|
||||||
|
modified versions of the software inside them, although the manufacturer
|
||||||
|
can do so. This is fundamentally incompatible with the aim of
|
||||||
|
protecting users' freedom to change the software. The systematic
|
||||||
|
pattern of such abuse occurs in the area of products for individuals to
|
||||||
|
use, which is precisely where it is most unacceptable. Therefore, we
|
||||||
|
have designed this version of the GPL to prohibit the practice for those
|
||||||
|
products. If such problems arise substantially in other domains, we
|
||||||
|
stand ready to extend this provision to those domains in future versions
|
||||||
|
of the GPL, as needed to protect the freedom of users.
|
||||||
|
|
||||||
|
Finally, every program is threatened constantly by software patents.
|
||||||
|
States should not allow patents to restrict development and use of
|
||||||
|
software on general-purpose computers, but in those that do, we wish to
|
||||||
|
avoid the special danger that patents applied to a free program could
|
||||||
|
make it effectively proprietary. To prevent this, the GPL assures that
|
||||||
|
patents cannot be used to render the program non-free.
|
||||||
|
|
||||||
|
The precise terms and conditions for copying, distribution and
|
||||||
|
modification follow.
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
0. Definitions.
|
||||||
|
|
||||||
|
"This License" refers to version 3 of the GNU General Public License.
|
||||||
|
|
||||||
|
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||||
|
works, such as semiconductor masks.
|
||||||
|
|
||||||
|
"The Program" refers to any copyrightable work licensed under this
|
||||||
|
License. Each licensee is addressed as "you". "Licensees" and
|
||||||
|
"recipients" may be individuals or organizations.
|
||||||
|
|
||||||
|
To "modify" a work means to copy from or adapt all or part of the work
|
||||||
|
in a fashion requiring copyright permission, other than the making of an
|
||||||
|
exact copy. The resulting work is called a "modified version" of the
|
||||||
|
earlier work or a work "based on" the earlier work.
|
||||||
|
|
||||||
|
A "covered work" means either the unmodified Program or a work based
|
||||||
|
on the Program.
|
||||||
|
|
||||||
|
To "propagate" a work means to do anything with it that, without
|
||||||
|
permission, would make you directly or secondarily liable for
|
||||||
|
infringement under applicable copyright law, except executing it on a
|
||||||
|
computer or modifying a private copy. Propagation includes copying,
|
||||||
|
distribution (with or without modification), making available to the
|
||||||
|
public, and in some countries other activities as well.
|
||||||
|
|
||||||
|
To "convey" a work means any kind of propagation that enables other
|
||||||
|
parties to make or receive copies. Mere interaction with a user through
|
||||||
|
a computer network, with no transfer of a copy, is not conveying.
|
||||||
|
|
||||||
|
An interactive user interface displays "Appropriate Legal Notices"
|
||||||
|
to the extent that it includes a convenient and prominently visible
|
||||||
|
feature that (1) displays an appropriate copyright notice, and (2)
|
||||||
|
tells the user that there is no warranty for the work (except to the
|
||||||
|
extent that warranties are provided), that licensees may convey the
|
||||||
|
work under this License, and how to view a copy of this License. If
|
||||||
|
the interface presents a list of user commands or options, such as a
|
||||||
|
menu, a prominent item in the list meets this criterion.
|
||||||
|
|
||||||
|
1. Source Code.
|
||||||
|
|
||||||
|
The "source code" for a work means the preferred form of the work
|
||||||
|
for making modifications to it. "Object code" means any non-source
|
||||||
|
form of a work.
|
||||||
|
|
||||||
|
A "Standard Interface" means an interface that either is an official
|
||||||
|
standard defined by a recognized standards body, or, in the case of
|
||||||
|
interfaces specified for a particular programming language, one that
|
||||||
|
is widely used among developers working in that language.
|
||||||
|
|
||||||
|
The "System Libraries" of an executable work include anything, other
|
||||||
|
than the work as a whole, that (a) is included in the normal form of
|
||||||
|
packaging a Major Component, but which is not part of that Major
|
||||||
|
Component, and (b) serves only to enable use of the work with that
|
||||||
|
Major Component, or to implement a Standard Interface for which an
|
||||||
|
implementation is available to the public in source code form. A
|
||||||
|
"Major Component", in this context, means a major essential component
|
||||||
|
(kernel, window system, and so on) of the specific operating system
|
||||||
|
(if any) on which the executable work runs, or a compiler used to
|
||||||
|
produce the work, or an object code interpreter used to run it.
|
||||||
|
|
||||||
|
The "Corresponding Source" for a work in object code form means all
|
||||||
|
the source code needed to generate, install, and (for an executable
|
||||||
|
work) run the object code and to modify the work, including scripts to
|
||||||
|
control those activities. However, it does not include the work's
|
||||||
|
System Libraries, or general-purpose tools or generally available free
|
||||||
|
programs which are used unmodified in performing those activities but
|
||||||
|
which are not part of the work. For example, Corresponding Source
|
||||||
|
includes interface definition files associated with source files for
|
||||||
|
the work, and the source code for shared libraries and dynamically
|
||||||
|
linked subprograms that the work is specifically designed to require,
|
||||||
|
such as by intimate data communication or control flow between those
|
||||||
|
subprograms and other parts of the work.
|
||||||
|
|
||||||
|
The Corresponding Source need not include anything that users
|
||||||
|
can regenerate automatically from other parts of the Corresponding
|
||||||
|
Source.
|
||||||
|
|
||||||
|
The Corresponding Source for a work in source code form is that
|
||||||
|
same work.
|
||||||
|
|
||||||
|
2. Basic Permissions.
|
||||||
|
|
||||||
|
All rights granted under this License are granted for the term of
|
||||||
|
copyright on the Program, and are irrevocable provided the stated
|
||||||
|
conditions are met. This License explicitly affirms your unlimited
|
||||||
|
permission to run the unmodified Program. The output from running a
|
||||||
|
covered work is covered by this License only if the output, given its
|
||||||
|
content, constitutes a covered work. This License acknowledges your
|
||||||
|
rights of fair use or other equivalent, as provided by copyright law.
|
||||||
|
|
||||||
|
You may make, run and propagate covered works that you do not
|
||||||
|
convey, without conditions so long as your license otherwise remains
|
||||||
|
in force. You may convey covered works to others for the sole purpose
|
||||||
|
of having them make modifications exclusively for you, or provide you
|
||||||
|
with facilities for running those works, provided that you comply with
|
||||||
|
the terms of this License in conveying all material for which you do
|
||||||
|
not control copyright. Those thus making or running the covered works
|
||||||
|
for you must do so exclusively on your behalf, under your direction
|
||||||
|
and control, on terms that prohibit them from making any copies of
|
||||||
|
your copyrighted material outside their relationship with you.
|
||||||
|
|
||||||
|
Conveying under any other circumstances is permitted solely under
|
||||||
|
the conditions stated below. Sublicensing is not allowed; section 10
|
||||||
|
makes it unnecessary.
|
||||||
|
|
||||||
|
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||||
|
|
||||||
|
No covered work shall be deemed part of an effective technological
|
||||||
|
measure under any applicable law fulfilling obligations under article
|
||||||
|
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||||
|
similar laws prohibiting or restricting circumvention of such
|
||||||
|
measures.
|
||||||
|
|
||||||
|
When you convey a covered work, you waive any legal power to forbid
|
||||||
|
circumvention of technological measures to the extent such circumvention
|
||||||
|
is effected by exercising rights under this License with respect to
|
||||||
|
the covered work, and you disclaim any intention to limit operation or
|
||||||
|
modification of the work as a means of enforcing, against the work's
|
||||||
|
users, your or third parties' legal rights to forbid circumvention of
|
||||||
|
technological measures.
|
||||||
|
|
||||||
|
4. Conveying Verbatim Copies.
|
||||||
|
|
||||||
|
You may convey verbatim copies of the Program's source code as you
|
||||||
|
receive it, in any medium, provided that you conspicuously and
|
||||||
|
appropriately publish on each copy an appropriate copyright notice;
|
||||||
|
keep intact all notices stating that this License and any
|
||||||
|
non-permissive terms added in accord with section 7 apply to the code;
|
||||||
|
keep intact all notices of the absence of any warranty; and give all
|
||||||
|
recipients a copy of this License along with the Program.
|
||||||
|
|
||||||
|
You may charge any price or no price for each copy that you convey,
|
||||||
|
and you may offer support or warranty protection for a fee.
|
||||||
|
|
||||||
|
5. Conveying Modified Source Versions.
|
||||||
|
|
||||||
|
You may convey a work based on the Program, or the modifications to
|
||||||
|
produce it from the Program, in the form of source code under the
|
||||||
|
terms of section 4, provided that you also meet all of these conditions:
|
||||||
|
|
||||||
|
a) The work must carry prominent notices stating that you modified
|
||||||
|
it, and giving a relevant date.
|
||||||
|
|
||||||
|
b) The work must carry prominent notices stating that it is
|
||||||
|
released under this License and any conditions added under section
|
||||||
|
7. This requirement modifies the requirement in section 4 to
|
||||||
|
"keep intact all notices".
|
||||||
|
|
||||||
|
c) You must license the entire work, as a whole, under this
|
||||||
|
License to anyone who comes into possession of a copy. This
|
||||||
|
License will therefore apply, along with any applicable section 7
|
||||||
|
additional terms, to the whole of the work, and all its parts,
|
||||||
|
regardless of how they are packaged. This License gives no
|
||||||
|
permission to license the work in any other way, but it does not
|
||||||
|
invalidate such permission if you have separately received it.
|
||||||
|
|
||||||
|
d) If the work has interactive user interfaces, each must display
|
||||||
|
Appropriate Legal Notices; however, if the Program has interactive
|
||||||
|
interfaces that do not display Appropriate Legal Notices, your
|
||||||
|
work need not make them do so.
|
||||||
|
|
||||||
|
A compilation of a covered work with other separate and independent
|
||||||
|
works, which are not by their nature extensions of the covered work,
|
||||||
|
and which are not combined with it such as to form a larger program,
|
||||||
|
in or on a volume of a storage or distribution medium, is called an
|
||||||
|
"aggregate" if the compilation and its resulting copyright are not
|
||||||
|
used to limit the access or legal rights of the compilation's users
|
||||||
|
beyond what the individual works permit. Inclusion of a covered work
|
||||||
|
in an aggregate does not cause this License to apply to the other
|
||||||
|
parts of the aggregate.
|
||||||
|
|
||||||
|
6. Conveying Non-Source Forms.
|
||||||
|
|
||||||
|
You may convey a covered work in object code form under the terms
|
||||||
|
of sections 4 and 5, provided that you also convey the
|
||||||
|
machine-readable Corresponding Source under the terms of this License,
|
||||||
|
in one of these ways:
|
||||||
|
|
||||||
|
a) Convey the object code in, or embodied in, a physical product
|
||||||
|
(including a physical distribution medium), accompanied by the
|
||||||
|
Corresponding Source fixed on a durable physical medium
|
||||||
|
customarily used for software interchange.
|
||||||
|
|
||||||
|
b) Convey the object code in, or embodied in, a physical product
|
||||||
|
(including a physical distribution medium), accompanied by a
|
||||||
|
written offer, valid for at least three years and valid for as
|
||||||
|
long as you offer spare parts or customer support for that product
|
||||||
|
model, to give anyone who possesses the object code either (1) a
|
||||||
|
copy of the Corresponding Source for all the software in the
|
||||||
|
product that is covered by this License, on a durable physical
|
||||||
|
medium customarily used for software interchange, for a price no
|
||||||
|
more than your reasonable cost of physically performing this
|
||||||
|
conveying of source, or (2) access to copy the
|
||||||
|
Corresponding Source from a network server at no charge.
|
||||||
|
|
||||||
|
c) Convey individual copies of the object code with a copy of the
|
||||||
|
written offer to provide the Corresponding Source. This
|
||||||
|
alternative is allowed only occasionally and noncommercially, and
|
||||||
|
only if you received the object code with such an offer, in accord
|
||||||
|
with subsection 6b.
|
||||||
|
|
||||||
|
d) Convey the object code by offering access from a designated
|
||||||
|
place (gratis or for a charge), and offer equivalent access to the
|
||||||
|
Corresponding Source in the same way through the same place at no
|
||||||
|
further charge. You need not require recipients to copy the
|
||||||
|
Corresponding Source along with the object code. If the place to
|
||||||
|
copy the object code is a network server, the Corresponding Source
|
||||||
|
may be on a different server (operated by you or a third party)
|
||||||
|
that supports equivalent copying facilities, provided you maintain
|
||||||
|
clear directions next to the object code saying where to find the
|
||||||
|
Corresponding Source. Regardless of what server hosts the
|
||||||
|
Corresponding Source, you remain obligated to ensure that it is
|
||||||
|
available for as long as needed to satisfy these requirements.
|
||||||
|
|
||||||
|
e) Convey the object code using peer-to-peer transmission, provided
|
||||||
|
you inform other peers where the object code and Corresponding
|
||||||
|
Source of the work are being offered to the general public at no
|
||||||
|
charge under subsection 6d.
|
||||||
|
|
||||||
|
A separable portion of the object code, whose source code is excluded
|
||||||
|
from the Corresponding Source as a System Library, need not be
|
||||||
|
included in conveying the object code work.
|
||||||
|
|
||||||
|
A "User Product" is either (1) a "consumer product", which means any
|
||||||
|
tangible personal property which is normally used for personal, family,
|
||||||
|
or household purposes, or (2) anything designed or sold for incorporation
|
||||||
|
into a dwelling. In determining whether a product is a consumer product,
|
||||||
|
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||||
|
product received by a particular user, "normally used" refers to a
|
||||||
|
typical or common use of that class of product, regardless of the status
|
||||||
|
of the particular user or of the way in which the particular user
|
||||||
|
actually uses, or expects or is expected to use, the product. A product
|
||||||
|
is a consumer product regardless of whether the product has substantial
|
||||||
|
commercial, industrial or non-consumer uses, unless such uses represent
|
||||||
|
the only significant mode of use of the product.
|
||||||
|
|
||||||
|
"Installation Information" for a User Product means any methods,
|
||||||
|
procedures, authorization keys, or other information required to install
|
||||||
|
and execute modified versions of a covered work in that User Product from
|
||||||
|
a modified version of its Corresponding Source. The information must
|
||||||
|
suffice to ensure that the continued functioning of the modified object
|
||||||
|
code is in no case prevented or interfered with solely because
|
||||||
|
modification has been made.
|
||||||
|
|
||||||
|
If you convey an object code work under this section in, or with, or
|
||||||
|
specifically for use in, a User Product, and the conveying occurs as
|
||||||
|
part of a transaction in which the right of possession and use of the
|
||||||
|
User Product is transferred to the recipient in perpetuity or for a
|
||||||
|
fixed term (regardless of how the transaction is characterized), the
|
||||||
|
Corresponding Source conveyed under this section must be accompanied
|
||||||
|
by the Installation Information. But this requirement does not apply
|
||||||
|
if neither you nor any third party retains the ability to install
|
||||||
|
modified object code on the User Product (for example, the work has
|
||||||
|
been installed in ROM).
|
||||||
|
|
||||||
|
The requirement to provide Installation Information does not include a
|
||||||
|
requirement to continue to provide support service, warranty, or updates
|
||||||
|
for a work that has been modified or installed by the recipient, or for
|
||||||
|
the User Product in which it has been modified or installed. Access to a
|
||||||
|
network may be denied when the modification itself materially and
|
||||||
|
adversely affects the operation of the network or violates the rules and
|
||||||
|
protocols for communication across the network.
|
||||||
|
|
||||||
|
Corresponding Source conveyed, and Installation Information provided,
|
||||||
|
in accord with this section must be in a format that is publicly
|
||||||
|
documented (and with an implementation available to the public in
|
||||||
|
source code form), and must require no special password or key for
|
||||||
|
unpacking, reading or copying.
|
||||||
|
|
||||||
|
7. Additional Terms.
|
||||||
|
|
||||||
|
"Additional permissions" are terms that supplement the terms of this
|
||||||
|
License by making exceptions from one or more of its conditions.
|
||||||
|
Additional permissions that are applicable to the entire Program shall
|
||||||
|
be treated as though they were included in this License, to the extent
|
||||||
|
that they are valid under applicable law. If additional permissions
|
||||||
|
apply only to part of the Program, that part may be used separately
|
||||||
|
under those permissions, but the entire Program remains governed by
|
||||||
|
this License without regard to the additional permissions.
|
||||||
|
|
||||||
|
When you convey a copy of a covered work, you may at your option
|
||||||
|
remove any additional permissions from that copy, or from any part of
|
||||||
|
it. (Additional permissions may be written to require their own
|
||||||
|
removal in certain cases when you modify the work.) You may place
|
||||||
|
additional permissions on material, added by you to a covered work,
|
||||||
|
for which you have or can give appropriate copyright permission.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, for material you
|
||||||
|
add to a covered work, you may (if authorized by the copyright holders of
|
||||||
|
that material) supplement the terms of this License with terms:
|
||||||
|
|
||||||
|
a) Disclaiming warranty or limiting liability differently from the
|
||||||
|
terms of sections 15 and 16 of this License; or
|
||||||
|
|
||||||
|
b) Requiring preservation of specified reasonable legal notices or
|
||||||
|
author attributions in that material or in the Appropriate Legal
|
||||||
|
Notices displayed by works containing it; or
|
||||||
|
|
||||||
|
c) Prohibiting misrepresentation of the origin of that material, or
|
||||||
|
requiring that modified versions of such material be marked in
|
||||||
|
reasonable ways as different from the original version; or
|
||||||
|
|
||||||
|
d) Limiting the use for publicity purposes of names of licensors or
|
||||||
|
authors of the material; or
|
||||||
|
|
||||||
|
e) Declining to grant rights under trademark law for use of some
|
||||||
|
trade names, trademarks, or service marks; or
|
||||||
|
|
||||||
|
f) Requiring indemnification of licensors and authors of that
|
||||||
|
material by anyone who conveys the material (or modified versions of
|
||||||
|
it) with contractual assumptions of liability to the recipient, for
|
||||||
|
any liability that these contractual assumptions directly impose on
|
||||||
|
those licensors and authors.
|
||||||
|
|
||||||
|
All other non-permissive additional terms are considered "further
|
||||||
|
restrictions" within the meaning of section 10. If the Program as you
|
||||||
|
received it, or any part of it, contains a notice stating that it is
|
||||||
|
governed by this License along with a term that is a further
|
||||||
|
restriction, you may remove that term. If a license document contains
|
||||||
|
a further restriction but permits relicensing or conveying under this
|
||||||
|
License, you may add to a covered work material governed by the terms
|
||||||
|
of that license document, provided that the further restriction does
|
||||||
|
not survive such relicensing or conveying.
|
||||||
|
|
||||||
|
If you add terms to a covered work in accord with this section, you
|
||||||
|
must place, in the relevant source files, a statement of the
|
||||||
|
additional terms that apply to those files, or a notice indicating
|
||||||
|
where to find the applicable terms.
|
||||||
|
|
||||||
|
Additional terms, permissive or non-permissive, may be stated in the
|
||||||
|
form of a separately written license, or stated as exceptions;
|
||||||
|
the above requirements apply either way.
|
||||||
|
|
||||||
|
8. Termination.
|
||||||
|
|
||||||
|
You may not propagate or modify a covered work except as expressly
|
||||||
|
provided under this License. Any attempt otherwise to propagate or
|
||||||
|
modify it is void, and will automatically terminate your rights under
|
||||||
|
this License (including any patent licenses granted under the third
|
||||||
|
paragraph of section 11).
|
||||||
|
|
||||||
|
However, if you cease all violation of this License, then your
|
||||||
|
license from a particular copyright holder is reinstated (a)
|
||||||
|
provisionally, unless and until the copyright holder explicitly and
|
||||||
|
finally terminates your license, and (b) permanently, if the copyright
|
||||||
|
holder fails to notify you of the violation by some reasonable means
|
||||||
|
prior to 60 days after the cessation.
|
||||||
|
|
||||||
|
Moreover, your license from a particular copyright holder is
|
||||||
|
reinstated permanently if the copyright holder notifies you of the
|
||||||
|
violation by some reasonable means, this is the first time you have
|
||||||
|
received notice of violation of this License (for any work) from that
|
||||||
|
copyright holder, and you cure the violation prior to 30 days after
|
||||||
|
your receipt of the notice.
|
||||||
|
|
||||||
|
Termination of your rights under this section does not terminate the
|
||||||
|
licenses of parties who have received copies or rights from you under
|
||||||
|
this License. If your rights have been terminated and not permanently
|
||||||
|
reinstated, you do not qualify to receive new licenses for the same
|
||||||
|
material under section 10.
|
||||||
|
|
||||||
|
9. Acceptance Not Required for Having Copies.
|
||||||
|
|
||||||
|
You are not required to accept this License in order to receive or
|
||||||
|
run a copy of the Program. Ancillary propagation of a covered work
|
||||||
|
occurring solely as a consequence of using peer-to-peer transmission
|
||||||
|
to receive a copy likewise does not require acceptance. However,
|
||||||
|
nothing other than this License grants you permission to propagate or
|
||||||
|
modify any covered work. These actions infringe copyright if you do
|
||||||
|
not accept this License. Therefore, by modifying or propagating a
|
||||||
|
covered work, you indicate your acceptance of this License to do so.
|
||||||
|
|
||||||
|
10. Automatic Licensing of Downstream Recipients.
|
||||||
|
|
||||||
|
Each time you convey a covered work, the recipient automatically
|
||||||
|
receives a license from the original licensors, to run, modify and
|
||||||
|
propagate that work, subject to this License. You are not responsible
|
||||||
|
for enforcing compliance by third parties with this License.
|
||||||
|
|
||||||
|
An "entity transaction" is a transaction transferring control of an
|
||||||
|
organization, or substantially all assets of one, or subdividing an
|
||||||
|
organization, or merging organizations. If propagation of a covered
|
||||||
|
work results from an entity transaction, each party to that
|
||||||
|
transaction who receives a copy of the work also receives whatever
|
||||||
|
licenses to the work the party's predecessor in interest had or could
|
||||||
|
give under the previous paragraph, plus a right to possession of the
|
||||||
|
Corresponding Source of the work from the predecessor in interest, if
|
||||||
|
the predecessor has it or can get it with reasonable efforts.
|
||||||
|
|
||||||
|
You may not impose any further restrictions on the exercise of the
|
||||||
|
rights granted or affirmed under this License. For example, you may
|
||||||
|
not impose a license fee, royalty, or other charge for exercise of
|
||||||
|
rights granted under this License, and you may not initiate litigation
|
||||||
|
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||||
|
any patent claim is infringed by making, using, selling, offering for
|
||||||
|
sale, or importing the Program or any portion of it.
|
||||||
|
|
||||||
|
11. Patents.
|
||||||
|
|
||||||
|
A "contributor" is a copyright holder who authorizes use under this
|
||||||
|
License of the Program or a work on which the Program is based. The
|
||||||
|
work thus licensed is called the contributor's "contributor version".
|
||||||
|
|
||||||
|
A contributor's "essential patent claims" are all patent claims
|
||||||
|
owned or controlled by the contributor, whether already acquired or
|
||||||
|
hereafter acquired, that would be infringed by some manner, permitted
|
||||||
|
by this License, of making, using, or selling its contributor version,
|
||||||
|
but do not include claims that would be infringed only as a
|
||||||
|
consequence of further modification of the contributor version. For
|
||||||
|
purposes of this definition, "control" includes the right to grant
|
||||||
|
patent sublicenses in a manner consistent with the requirements of
|
||||||
|
this License.
|
||||||
|
|
||||||
|
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||||
|
patent license under the contributor's essential patent claims, to
|
||||||
|
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||||
|
propagate the contents of its contributor version.
|
||||||
|
|
||||||
|
In the following three paragraphs, a "patent license" is any express
|
||||||
|
agreement or commitment, however denominated, not to enforce a patent
|
||||||
|
(such as an express permission to practice a patent or covenant not to
|
||||||
|
sue for patent infringement). To "grant" such a patent license to a
|
||||||
|
party means to make such an agreement or commitment not to enforce a
|
||||||
|
patent against the party.
|
||||||
|
|
||||||
|
If you convey a covered work, knowingly relying on a patent license,
|
||||||
|
and the Corresponding Source of the work is not available for anyone
|
||||||
|
to copy, free of charge and under the terms of this License, through a
|
||||||
|
publicly available network server or other readily accessible means,
|
||||||
|
then you must either (1) cause the Corresponding Source to be so
|
||||||
|
available, or (2) arrange to deprive yourself of the benefit of the
|
||||||
|
patent license for this particular work, or (3) arrange, in a manner
|
||||||
|
consistent with the requirements of this License, to extend the patent
|
||||||
|
license to downstream recipients. "Knowingly relying" means you have
|
||||||
|
actual knowledge that, but for the patent license, your conveying the
|
||||||
|
covered work in a country, or your recipient's use of the covered work
|
||||||
|
in a country, would infringe one or more identifiable patents in that
|
||||||
|
country that you have reason to believe are valid.
|
||||||
|
|
||||||
|
If, pursuant to or in connection with a single transaction or
|
||||||
|
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||||
|
covered work, and grant a patent license to some of the parties
|
||||||
|
receiving the covered work authorizing them to use, propagate, modify
|
||||||
|
or convey a specific copy of the covered work, then the patent license
|
||||||
|
you grant is automatically extended to all recipients of the covered
|
||||||
|
work and works based on it.
|
||||||
|
|
||||||
|
A patent license is "discriminatory" if it does not include within
|
||||||
|
the scope of its coverage, prohibits the exercise of, or is
|
||||||
|
conditioned on the non-exercise of one or more of the rights that are
|
||||||
|
specifically granted under this License. You may not convey a covered
|
||||||
|
work if you are a party to an arrangement with a third party that is
|
||||||
|
in the business of distributing software, under which you make payment
|
||||||
|
to the third party based on the extent of your activity of conveying
|
||||||
|
the work, and under which the third party grants, to any of the
|
||||||
|
parties who would receive the covered work from you, a discriminatory
|
||||||
|
patent license (a) in connection with copies of the covered work
|
||||||
|
conveyed by you (or copies made from those copies), or (b) primarily
|
||||||
|
for and in connection with specific products or compilations that
|
||||||
|
contain the covered work, unless you entered into that arrangement,
|
||||||
|
or that patent license was granted, prior to 28 March 2007.
|
||||||
|
|
||||||
|
Nothing in this License shall be construed as excluding or limiting
|
||||||
|
any implied license or other defenses to infringement that may
|
||||||
|
otherwise be available to you under applicable patent law.
|
||||||
|
|
||||||
|
12. No Surrender of Others' Freedom.
|
||||||
|
|
||||||
|
If conditions are imposed on you (whether by court order, agreement or
|
||||||
|
otherwise) that contradict the conditions of this License, they do not
|
||||||
|
excuse you from the conditions of this License. If you cannot convey a
|
||||||
|
covered work so as to satisfy simultaneously your obligations under this
|
||||||
|
License and any other pertinent obligations, then as a consequence you may
|
||||||
|
not convey it at all. For example, if you agree to terms that obligate you
|
||||||
|
to collect a royalty for further conveying from those to whom you convey
|
||||||
|
the Program, the only way you could satisfy both those terms and this
|
||||||
|
License would be to refrain entirely from conveying the Program.
|
||||||
|
|
||||||
|
13. Use with the GNU Affero General Public License.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, you have
|
||||||
|
permission to link or combine any covered work with a work licensed
|
||||||
|
under version 3 of the GNU Affero General Public License into a single
|
||||||
|
combined work, and to convey the resulting work. The terms of this
|
||||||
|
License will continue to apply to the part which is the covered work,
|
||||||
|
but the special requirements of the GNU Affero General Public License,
|
||||||
|
section 13, concerning interaction through a network will apply to the
|
||||||
|
combination as such.
|
||||||
|
|
||||||
|
14. Revised Versions of this License.
|
||||||
|
|
||||||
|
The Free Software Foundation may publish revised and/or new versions of
|
||||||
|
the GNU General Public License from time to time. Such new versions will
|
||||||
|
be similar in spirit to the present version, but may differ in detail to
|
||||||
|
address new problems or concerns.
|
||||||
|
|
||||||
|
Each version is given a distinguishing version number. If the
|
||||||
|
Program specifies that a certain numbered version of the GNU General
|
||||||
|
Public License "or any later version" applies to it, you have the
|
||||||
|
option of following the terms and conditions either of that numbered
|
||||||
|
version or of any later version published by the Free Software
|
||||||
|
Foundation. If the Program does not specify a version number of the
|
||||||
|
GNU General Public License, you may choose any version ever published
|
||||||
|
by the Free Software Foundation.
|
||||||
|
|
||||||
|
If the Program specifies that a proxy can decide which future
|
||||||
|
versions of the GNU General Public License can be used, that proxy's
|
||||||
|
public statement of acceptance of a version permanently authorizes you
|
||||||
|
to choose that version for the Program.
|
||||||
|
|
||||||
|
Later license versions may give you additional or different
|
||||||
|
permissions. However, no additional obligations are imposed on any
|
||||||
|
author or copyright holder as a result of your choosing to follow a
|
||||||
|
later version.
|
||||||
|
|
||||||
|
15. Disclaimer of Warranty.
|
||||||
|
|
||||||
|
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||||
|
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||||
|
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||||
|
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||||
|
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||||
|
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||||
|
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||||
|
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||||
|
|
||||||
|
16. Limitation of Liability.
|
||||||
|
|
||||||
|
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||||
|
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||||
|
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||||
|
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||||
|
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||||
|
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||||
|
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||||
|
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||||
|
SUCH DAMAGES.
|
||||||
|
|
||||||
|
17. Interpretation of Sections 15 and 16.
|
||||||
|
|
||||||
|
If the disclaimer of warranty and limitation of liability provided
|
||||||
|
above cannot be given local legal effect according to their terms,
|
||||||
|
reviewing courts shall apply local law that most closely approximates
|
||||||
|
an absolute waiver of all civil liability in connection with the
|
||||||
|
Program, unless a warranty or assumption of liability accompanies a
|
||||||
|
copy of the Program in return for a fee.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
How to Apply These Terms to Your New Programs
|
||||||
|
|
||||||
|
If you develop a new program, and you want it to be of the greatest
|
||||||
|
possible use to the public, the best way to achieve this is to make it
|
||||||
|
free software which everyone can redistribute and change under these terms.
|
||||||
|
|
||||||
|
To do so, attach the following notices to the program. It is safest
|
||||||
|
to attach them to the start of each source file to most effectively
|
||||||
|
state the exclusion of warranty; and each file should have at least
|
||||||
|
the "copyright" line and a pointer to where the full notice is found.
|
||||||
|
|
||||||
|
<one line to give the program's name and a brief idea of what it does.>
|
||||||
|
Copyright (C) <year> <name of author>
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Also add information on how to contact you by electronic and paper mail.
|
||||||
|
|
||||||
|
If the program does terminal interaction, make it output a short
|
||||||
|
notice like this when it starts in an interactive mode:
|
||||||
|
|
||||||
|
<program> Copyright (C) <year> <name of author>
|
||||||
|
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||||
|
This is free software, and you are welcome to redistribute it
|
||||||
|
under certain conditions; type `show c' for details.
|
||||||
|
|
||||||
|
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||||
|
parts of the General Public License. Of course, your program's commands
|
||||||
|
might be different; for a GUI interface, you would use an "about box".
|
||||||
|
|
||||||
|
You should also get your employer (if you work as a programmer) or school,
|
||||||
|
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||||
|
For more information on this, and how to apply and follow the GNU GPL, see
|
||||||
|
<http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
The GNU General Public License does not permit incorporating your program
|
||||||
|
into proprietary programs. If your program is a subroutine library, you
|
||||||
|
may consider it more useful to permit linking proprietary applications with
|
||||||
|
the library. If this is what you want to do, use the GNU Lesser General
|
||||||
|
Public License instead of this License. But first, please read
|
||||||
|
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
||||||
|
|
360
externals/artnetin/Makefile
vendored
Executable file
360
externals/artnetin/Makefile
vendored
Executable file
|
@ -0,0 +1,360 @@
|
||||||
|
## Pd library template version 1.0.9
|
||||||
|
# For instructions on how to use this template, see:
|
||||||
|
# http://puredata.info/docs/developer/MakefileTemplate
|
||||||
|
LIBRARY_NAME = artnetin
|
||||||
|
|
||||||
|
# add your .c source files, one object per file, to the SOURCES
|
||||||
|
# variable, help files will be included automatically, and for GUI
|
||||||
|
# objects, the matching .tcl file too
|
||||||
|
SOURCES = artnetin.c
|
||||||
|
|
||||||
|
# list all pd objects (i.e. myobject.pd) files here, and their helpfiles will
|
||||||
|
# be included automatically
|
||||||
|
PDOBJECTS = artnetin.pd
|
||||||
|
|
||||||
|
# example patches and related files, in the 'examples' subfolder
|
||||||
|
EXAMPLES = artnetin.pd
|
||||||
|
|
||||||
|
# manuals and related files, in the 'manual' subfolder
|
||||||
|
MANUAL = manual.txt
|
||||||
|
|
||||||
|
# if you want to include any other files in the source and binary tarballs,
|
||||||
|
# list them here. This can be anything from header files, test patches,
|
||||||
|
# documentation, etc. README.txt and LICENSE.txt are required and therefore
|
||||||
|
# automatically included
|
||||||
|
EXTRA_DIST =
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------------#
|
||||||
|
#
|
||||||
|
# things you might need to edit if you are using other C libraries
|
||||||
|
#
|
||||||
|
#-------------------------------------lpthread------------------------------------------#
|
||||||
|
|
||||||
|
# -I"$(PD_INCLUDE)/pd" supports the header location for 0.43
|
||||||
|
CFLAGS = -I"$(PD_INCLUDE)/pd" -Wall -W -g -I/usr/local/lib -I. -I..
|
||||||
|
LDFLAGS = -L/usr/local/lib -I. -I..
|
||||||
|
LIBS = -L/usr/local/lib -lartnet -lpthread -I. -I..
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------------#
|
||||||
|
#
|
||||||
|
# you shouldn't need to edit anything below here, if we did it right :)
|
||||||
|
#
|
||||||
|
#------------------------------------------------------------------------------#
|
||||||
|
|
||||||
|
# get library version from meta file
|
||||||
|
LIBRARY_VERSION = $(shell sed -n 's|^\#X text [0-9][0-9]* [0-9][0-9]* VERSION \(.*\);|\1|p' $(LIBRARY_NAME)-meta.pd)
|
||||||
|
|
||||||
|
CFLAGS += -DPD -DVERSION='"$(LIBRARY_VERSION)"'
|
||||||
|
|
||||||
|
PD_INCLUDE = $(PD_PATH)/include
|
||||||
|
# where to install the library, overridden below depending on platform
|
||||||
|
prefix = /usr/local
|
||||||
|
libdir = $(prefix)/lib
|
||||||
|
pkglibdir = $(libdir)/pd-externals
|
||||||
|
objectsdir = $(pkglibdir)
|
||||||
|
|
||||||
|
INSTALL = install
|
||||||
|
INSTALL_PROGRAM = $(INSTALL) -p -m 644
|
||||||
|
INSTALL_DATA = $(INSTALL) -p -m 644
|
||||||
|
INSTALL_DIR = $(INSTALL) -p -m 755 -d
|
||||||
|
|
||||||
|
ALLSOURCES := $(SOURCES) $(SOURCES_android) $(SOURCES_cygwin) $(SOURCES_macosx) \
|
||||||
|
$(SOURCES_iphoneos) $(SOURCES_linux) $(SOURCES_windows)
|
||||||
|
|
||||||
|
DISTDIR=$(LIBRARY_NAME)-$(LIBRARY_VERSION)
|
||||||
|
ORIGDIR=pd-$(LIBRARY_NAME:~=)_$(LIBRARY_VERSION)
|
||||||
|
|
||||||
|
UNAME := $(shell uname -s)
|
||||||
|
ifeq ($(UNAME),Darwin)
|
||||||
|
CPU := $(shell uname -p)
|
||||||
|
ifeq ($(CPU),arm) # iPhone/iPod Touch
|
||||||
|
SOURCES += $(SOURCES_iphoneos)
|
||||||
|
EXTENSION = pd_darwin
|
||||||
|
OS = iphoneos
|
||||||
|
PD_PATH = /Applications/Pd-extended.app/Contents/Resources
|
||||||
|
IPHONE_BASE=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin
|
||||||
|
CC=$(IPHONE_BASE)/gcc
|
||||||
|
CPP=$(IPHONE_BASE)/cpp
|
||||||
|
CXX=$(IPHONE_BASE)/g++
|
||||||
|
ISYSROOT = -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS3.0.sdk
|
||||||
|
IPHONE_CFLAGS = -miphoneos-version-min=3.0 $(ISYSROOT) -arch armv6
|
||||||
|
OPT_CFLAGS = -fast -funroll-loops -fomit-frame-pointer
|
||||||
|
CFLAGS := $(IPHONE_CFLAGS) $(OPT_CFLAGS) $(CFLAGS)
|
||||||
|
LDFLAGS += -arch armv6 -bundle -undefined dynamic_lookup $(ISYSROOT)
|
||||||
|
LIBS += -lc
|
||||||
|
STRIP = strip -x
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)
|
||||||
|
else # Mac OS X
|
||||||
|
SOURCES += $(SOURCES_macosx)
|
||||||
|
EXTENSION = pd_darwin
|
||||||
|
OS = macosx
|
||||||
|
PD_PATH = /Applications/Pd-extended.app/Contents/Resources
|
||||||
|
OPT_CFLAGS = -ftree-vectorize -ftree-vectorizer-verbose=2 -fast
|
||||||
|
# build universal 32-bit on 10.4 and 32/64 on newer
|
||||||
|
ifeq ($(shell uname -r | sed 's|\([0-9][0-9]*\)\.[0-9][0-9]*\.[0-9][0-9]*|\1|'), 8)
|
||||||
|
FAT_FLAGS = -arch ppc -arch i386 -mmacosx-version-min=10.4
|
||||||
|
else
|
||||||
|
FAT_FLAGS = -arch ppc -arch i386 -arch x86_64 -mmacosx-version-min=10.4
|
||||||
|
SOURCES += $(SOURCES_iphoneos)
|
||||||
|
endif
|
||||||
|
CFLAGS += $(FAT_FLAGS) -fPIC -I/sw/include
|
||||||
|
LDFLAGS += $(FAT_FLAGS) -bundle -undefined dynamic_lookup -L/sw/lib
|
||||||
|
# if the 'pd' binary exists, check the linking against it to aid with stripping
|
||||||
|
LDFLAGS += $(shell test -e $(PD_PATH)/bin/pd && echo -bundle_loader $(PD_PATH)/bin/pd)
|
||||||
|
LIBS += -lc
|
||||||
|
STRIP = strip -x
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)
|
||||||
|
# install into ~/Library/Pd on Mac OS X since /usr/local isn't used much
|
||||||
|
pkglibdir=$(HOME)/Library/Pd
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
# Tho Android uses Linux, we use this fake uname to provide an easy way to
|
||||||
|
# setup all this things needed to cross-compile for Android using the NDK
|
||||||
|
ifeq ($(UNAME),ANDROID)
|
||||||
|
CPU := arm
|
||||||
|
SOURCES += $(SOURCES_android)
|
||||||
|
EXTENSION = pd_linux
|
||||||
|
OS = android
|
||||||
|
PD_PATH = /usr
|
||||||
|
NDK_BASE := /usr/local/android-ndk
|
||||||
|
NDK_PLATFORM_VERSION := 5
|
||||||
|
NDK_SYSROOT=$(NDK_BASE)/platforms/android-$(NDK_PLATFORM_VERSION)/arch-arm
|
||||||
|
NDK_UNAME := $(shell uname -s | tr '[A-Z]' '[a-z]')
|
||||||
|
NDK_TOOLCHAIN_BASE=$(NDK_BASE)/toolchains/arm-linux-androideabi-4.4.3/prebuilt/$(NDK_UNAME)-x86
|
||||||
|
CC := $(NDK_TOOLCHAIN_BASE)/bin/arm-linux-androideabi-gcc --sysroot=$(NDK_SYSROOT)
|
||||||
|
OPT_CFLAGS = -O6 -funroll-loops -fomit-frame-pointer
|
||||||
|
CFLAGS +=
|
||||||
|
LDFLAGS += -Wl,--export-dynamic -shared
|
||||||
|
LIBS += -lc
|
||||||
|
STRIP := $(NDK_TOOLCHAIN_BASE)/bin/arm-linux-androideabi-strip \
|
||||||
|
--strip-unneeded -R .note -R .comment
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)-$(shell uname -m)
|
||||||
|
endif
|
||||||
|
ifeq ($(UNAME),Linux)
|
||||||
|
CPU := $(shell uname -m)
|
||||||
|
SOURCES += $(SOURCES_linux)
|
||||||
|
EXTENSION = pd_linux
|
||||||
|
OS = linux
|
||||||
|
PD_PATH = /usr
|
||||||
|
OPT_CFLAGS = -O6 -funroll-loops -fomit-frame-pointer
|
||||||
|
CFLAGS += -fPIC
|
||||||
|
LDFLAGS += -Wl,--export-dynamic -shared -fPIC
|
||||||
|
LIBS += -lc
|
||||||
|
STRIP = strip --strip-unneeded -R .note -R .comment
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)-$(shell uname -m)
|
||||||
|
endif
|
||||||
|
ifeq ($(UNAME),GNU)
|
||||||
|
# GNU/Hurd, should work like GNU/Linux for basically all externals
|
||||||
|
CPU := $(shell uname -m)
|
||||||
|
SOURCES += $(SOURCES_linux)
|
||||||
|
EXTENSION = pd_linux
|
||||||
|
OS = linux
|
||||||
|
PD_PATH = /usr
|
||||||
|
OPT_CFLAGS = -O6 -funroll-loops -fomit-frame-pointer
|
||||||
|
CFLAGS += -fPIC
|
||||||
|
LDFLAGS += -Wl,--export-dynamic -shared -fPIC
|
||||||
|
LIBS += -lc
|
||||||
|
STRIP = strip --strip-unneeded -R .note -R .comment
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)-$(shell uname -m)
|
||||||
|
endif
|
||||||
|
ifeq ($(UNAME),GNU/kFreeBSD)
|
||||||
|
# Debian GNU/kFreeBSD, should work like GNU/Linux for basically all externals
|
||||||
|
CPU := $(shell uname -m)
|
||||||
|
SOURCES += $(SOURCES_linux)
|
||||||
|
EXTENSION = pd_linux
|
||||||
|
OS = linux
|
||||||
|
PD_PATH = /usr
|
||||||
|
OPT_CFLAGS = -O6 -funroll-loops -fomit-frame-pointer
|
||||||
|
CFLAGS += -fPIC
|
||||||
|
LDFLAGS += -Wl,--export-dynamic -shared -fPIC
|
||||||
|
LIBS += -lc
|
||||||
|
STRIP = strip --strip-unneeded -R .note -R .comment
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)-$(shell uname -m)
|
||||||
|
endif
|
||||||
|
ifeq (CYGWIN,$(findstring CYGWIN,$(UNAME)))
|
||||||
|
CPU := $(shell uname -m)
|
||||||
|
SOURCES += $(SOURCES_cygwin)
|
||||||
|
EXTENSION = dll
|
||||||
|
OS = cygwin
|
||||||
|
PD_PATH = $(cygpath $(PROGRAMFILES))/pd
|
||||||
|
OPT_CFLAGS = -O6 -funroll-loops -fomit-frame-pointer
|
||||||
|
CFLAGS +=
|
||||||
|
LDFLAGS += -Wl,--export-dynamic -shared -L"$(PD_PATH)/src" -L"$(PD_PATH)/bin"
|
||||||
|
LIBS += -lc -lpd
|
||||||
|
STRIP = strip --strip-unneeded -R .note -R .comment
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)
|
||||||
|
endif
|
||||||
|
ifeq (MINGW,$(findstring MINGW,$(UNAME)))
|
||||||
|
CPU := $(shell uname -m)
|
||||||
|
SOURCES += $(SOURCES_windows)
|
||||||
|
EXTENSION = dll
|
||||||
|
OS = windows
|
||||||
|
PD_PATH = $(shell cd "$(PROGRAMFILES)"/pd && pwd)
|
||||||
|
OPT_CFLAGS = -O3 -funroll-loops -fomit-frame-pointer
|
||||||
|
CFLAGS += -mms-bitfields
|
||||||
|
LDFLAGS += -s -shared -Wl,--enable-auto-import
|
||||||
|
LIBS += -L"$(PD_PATH)/src" -L"$(PD_PATH)/bin" -L"$(PD_PATH)/obj" -lpd -lwsock32 -lkernel32 -luser32 -lgdi32
|
||||||
|
STRIP = strip --strip-unneeded -R .note -R .comment
|
||||||
|
DISTBINDIR=$(DISTDIR)-$(OS)
|
||||||
|
endif
|
||||||
|
|
||||||
|
# in case somebody manually set the HELPPATCHES above
|
||||||
|
HELPPATCHES ?= $(SOURCES:.c=-help.pd) $(PDOBJECTS:.pd=-help.pd)
|
||||||
|
|
||||||
|
CFLAGS += $(OPT_CFLAGS)
|
||||||
|
|
||||||
|
|
||||||
|
.PHONY = install libdir_install single_install install-doc install-exec install-examples install-manual clean dist etags $(LIBRARY_NAME)
|
||||||
|
|
||||||
|
all: $(SOURCES:.c=.$(EXTENSION))
|
||||||
|
|
||||||
|
%.o: %.c
|
||||||
|
$(CC) $(CFLAGS) -o "$*.o" -c "$*.c"
|
||||||
|
|
||||||
|
%.$(EXTENSION): %.o
|
||||||
|
$(CC) $(LDFLAGS) -o "$*.$(EXTENSION)" "$*.o" $(LIBS)
|
||||||
|
chmod a-x "$*.$(EXTENSION)"
|
||||||
|
|
||||||
|
# this links everything into a single binary file
|
||||||
|
$(LIBRARY_NAME): $(SOURCES:.c=.o) $(LIBRARY_NAME).o
|
||||||
|
$(CC) $(LDFLAGS) -o $(LIBRARY_NAME).$(EXTENSION) $(SOURCES:.c=.o) $(LIBRARY_NAME).o $(LIBS)
|
||||||
|
chmod a-x $(LIBRARY_NAME).$(EXTENSION)
|
||||||
|
|
||||||
|
install: libdir_install
|
||||||
|
|
||||||
|
# The meta and help files are explicitly installed to make sure they are
|
||||||
|
# actually there. Those files are not optional, then need to be there.
|
||||||
|
libdir_install: $(SOURCES:.c=.$(EXTENSION)) install-doc install-examples install-manual
|
||||||
|
$(INSTALL_DIR) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
$(INSTALL_DATA) $(LIBRARY_NAME)-meta.pd \
|
||||||
|
$(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
test -z "$(strip $(SOURCES))" || (\
|
||||||
|
$(INSTALL_PROGRAM) $(SOURCES:.c=.$(EXTENSION)) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME) && \
|
||||||
|
$(STRIP) $(addprefix $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/,$(SOURCES:.c=.$(EXTENSION))))
|
||||||
|
test -z "$(strip $(shell ls $(SOURCES:.c=.tcl)))" || \
|
||||||
|
$(INSTALL_DATA) $(shell ls $(SOURCES:.c=.tcl)) \
|
||||||
|
$(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
test -z "$(strip $(PDOBJECTS))" || \
|
||||||
|
$(INSTALL_DATA) $(PDOBJECTS) \
|
||||||
|
$(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
|
||||||
|
# install library linked as single binary
|
||||||
|
single_install: $(LIBRARY_NAME) install-doc install-exec
|
||||||
|
$(INSTALL_DIR) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
$(INSTALL_PROGRAM) $(LIBRARY_NAME).$(EXTENSION) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
$(STRIP) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/$(LIBRARY_NAME).$(EXTENSION)
|
||||||
|
|
||||||
|
install-doc:
|
||||||
|
$(INSTALL_DIR) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
test -z "$(strip $(SOURCES) $(PDOBJECTS))" || \
|
||||||
|
$(INSTALL_DATA) $(HELPPATCHES) \
|
||||||
|
$(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)
|
||||||
|
$(INSTALL_DATA) README.txt $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/README.txt
|
||||||
|
$(INSTALL_DATA) LICENSE.txt $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/LICENSE.txt
|
||||||
|
|
||||||
|
install-examples:
|
||||||
|
test -z "$(strip $(EXAMPLES))" || \
|
||||||
|
$(INSTALL_DIR) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/examples && \
|
||||||
|
for file in $(EXAMPLES); do \
|
||||||
|
$(INSTALL_DATA) examples/$$file $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/examples; \
|
||||||
|
done
|
||||||
|
|
||||||
|
install-manual:
|
||||||
|
test -z "$(strip $(MANUAL))" || \
|
||||||
|
$(INSTALL_DIR) $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/manual && \
|
||||||
|
for file in $(MANUAL); do \
|
||||||
|
$(INSTALL_DATA) manual/$$file $(DESTDIR)$(objectsdir)/$(LIBRARY_NAME)/manual; \
|
||||||
|
done
|
||||||
|
|
||||||
|
|
||||||
|
clean:
|
||||||
|
-rm -f -- $(SOURCES:.c=.o) $(SOURCES_LIB:.c=.o)
|
||||||
|
-rm -f -- $(SOURCES:.c=.$(EXTENSION))
|
||||||
|
-rm -f -- $(LIBRARY_NAME).o
|
||||||
|
-rm -f -- $(LIBRARY_NAME).$(EXTENSION)
|
||||||
|
|
||||||
|
distclean: clean
|
||||||
|
-rm -f -- $(DISTBINDIR).tar.gz
|
||||||
|
-rm -rf -- $(DISTBINDIR)
|
||||||
|
-rm -f -- $(DISTDIR).tar.gz
|
||||||
|
-rm -rf -- $(DISTDIR)
|
||||||
|
-rm -f -- $(ORIGDIR).tar.gz
|
||||||
|
-rm -rf -- $(ORIGDIR)
|
||||||
|
|
||||||
|
|
||||||
|
$(DISTBINDIR):
|
||||||
|
$(INSTALL_DIR) $(DISTBINDIR)
|
||||||
|
|
||||||
|
libdir: all $(DISTBINDIR)
|
||||||
|
$(INSTALL_DATA) $(LIBRARY_NAME)-meta.pd $(DISTBINDIR)
|
||||||
|
$(INSTALL_DATA) $(SOURCES) $(DISTBINDIR)
|
||||||
|
$(INSTALL_DATA) $(HELPPATCHES) $(DISTBINDIR)
|
||||||
|
test -z "$(strip $(EXTRA_DIST))" || \
|
||||||
|
$(INSTALL_DATA) $(EXTRA_DIST) $(DISTBINDIR)
|
||||||
|
# tar --exclude-vcs -czpf $(DISTBINDIR).tar.gz $(DISTBINDIR)
|
||||||
|
|
||||||
|
$(DISTDIR):
|
||||||
|
$(INSTALL_DIR) $(DISTDIR)
|
||||||
|
|
||||||
|
$(ORIGDIR):
|
||||||
|
$(INSTALL_DIR) $(ORIGDIR)
|
||||||
|
|
||||||
|
dist: $(DISTDIR)
|
||||||
|
$(INSTALL_DATA) Makefile $(DISTDIR)
|
||||||
|
$(INSTALL_DATA) README.txt $(DISTDIR)
|
||||||
|
$(INSTALL_DATA) LICENSE.txt $(DISTDIR)
|
||||||
|
$(INSTALL_DATA) $(LIBRARY_NAME)-meta.pd $(DISTDIR)
|
||||||
|
test -z "$(strip $(ALLSOURCES))" || \
|
||||||
|
$(INSTALL_DATA) $(ALLSOURCES) $(DISTDIR)
|
||||||
|
test -z "$(strip $(shell ls $(ALLSOURCES:.c=.tcl)))" || \
|
||||||
|
$(INSTALL_DATA) $(shell ls $(ALLSOURCES:.c=.tcl)) $(DISTDIR)
|
||||||
|
test -z "$(strip $(PDOBJECTS))" || \
|
||||||
|
$(INSTALL_DATA) $(PDOBJECTS) $(DISTDIR)
|
||||||
|
test -z "$(strip $(HELPPATCHES))" || \
|
||||||
|
$(INSTALL_DATA) $(HELPPATCHES) $(DISTDIR)
|
||||||
|
test -z "$(strip $(EXTRA_DIST))" || \
|
||||||
|
$(INSTALL_DATA) $(EXTRA_DIST) $(DISTDIR)
|
||||||
|
test -z "$(strip $(EXAMPLES))" || \
|
||||||
|
$(INSTALL_DIR) $(DISTDIR)/examples && \
|
||||||
|
for file in $(EXAMPLES); do \
|
||||||
|
$(INSTALL_DATA) examples/$$file $(DISTDIR)/examples; \
|
||||||
|
done
|
||||||
|
test -z "$(strip $(MANUAL))" || \
|
||||||
|
$(INSTALL_DIR) $(DISTDIR)/manual && \
|
||||||
|
for file in $(MANUAL); do \
|
||||||
|
$(INSTALL_DATA) manual/$$file $(DISTDIR)/manual; \
|
||||||
|
done
|
||||||
|
tar --exclude-vcs -czpf $(DISTDIR).tar.gz $(DISTDIR)
|
||||||
|
|
||||||
|
# make a Debian source package
|
||||||
|
dpkg-source:
|
||||||
|
debclean
|
||||||
|
make distclean dist
|
||||||
|
mv $(DISTDIR) $(ORIGDIR)
|
||||||
|
tar --exclude-vcs -czpf ../$(ORIGDIR).orig.tar.gz $(ORIGDIR)
|
||||||
|
rm -f -- $(DISTDIR).tar.gz
|
||||||
|
rm -rf -- $(DISTDIR) $(ORIGDIR)
|
||||||
|
cd .. && dpkg-source -b $(LIBRARY_NAME)
|
||||||
|
|
||||||
|
etags:
|
||||||
|
etags *.h $(SOURCES) ../../pd/src/*.[ch] /usr/include/*.h /usr/include/*/*.h
|
||||||
|
|
||||||
|
showsetup:
|
||||||
|
@echo "CFLAGS: $(CFLAGS)"
|
||||||
|
@echo "LDFLAGS: $(LDFLAGS)"
|
||||||
|
@echo "LIBS: $(LIBS)"
|
||||||
|
@echo "PD_INCLUDE: $(PD_INCLUDE)"
|
||||||
|
@echo "PD_PATH: $(PD_PATH)"
|
||||||
|
@echo "objectsdir: $(objectsdir)"
|
||||||
|
@echo "LIBRARY_NAME: $(LIBRARY_NAME)"
|
||||||
|
@echo "LIBRARY_VERSION: $(LIBRARY_VERSION)"
|
||||||
|
@echo "SOURCES: $(SOURCES)"
|
||||||
|
@echo "PDOBJECTS: $(PDOBJECTS)"
|
||||||
|
@echo "ALLSOURCES: $(ALLSOURCES)"
|
||||||
|
@echo "UNAME: $(UNAME)"
|
||||||
|
@echo "CPU: $(CPU)"
|
||||||
|
@echo "pkglibdir: $(pkglibdir)"
|
||||||
|
@echo "DISTDIR: $(DISTDIR)"
|
||||||
|
@echo "ORIGDIR: $(ORIGDIR)"
|
51
externals/artnetin/README.txt
vendored
Executable file
51
externals/artnetin/README.txt
vendored
Executable file
|
@ -0,0 +1,51 @@
|
||||||
|
******************************
|
||||||
|
Artnetin 0.0.3
|
||||||
|
Santiago Noreña
|
||||||
|
puremediaserver@gmail.com
|
||||||
|
|
||||||
|
Based on previous works by:
|
||||||
|
* Dirk Jagdmann (doj@cubic.org) dmxmonitor
|
||||||
|
* Simon Newton (nomis52@westnet.com.au) Modified dmxmonitor to use ArtNet
|
||||||
|
* Patrick Sébastien (http://www.workinprogress.ca/) pure data external pthread template
|
||||||
|
|
||||||
|
libartnet es parte del proyecto Open Lighting Arquitecture y (c) por Simon Newton
|
||||||
|
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Artnetin es un objeto de Pure Data que permite leer un universo entero de ArtNet y tratarlo como una lista de enteros en Pure Data.
|
||||||
|
|
||||||
|
*****************************
|
||||||
|
|
||||||
|
Instalación:
|
||||||
|
|
||||||
|
1. Compila e instala libartnet:
|
||||||
|
|
||||||
|
cd libartnet-1.1.0
|
||||||
|
./configure
|
||||||
|
make
|
||||||
|
sudo make install
|
||||||
|
|
||||||
|
2. Compila artnetin:
|
||||||
|
make
|
||||||
|
|
||||||
|
3. Copia el archivo artnetin.pd_linux en una localización dentro del path de Pure Data, o añade el path a Pure Data
|
||||||
|
|
||||||
|
*****************************
|
||||||
|
|
||||||
|
Uso:
|
||||||
|
|
||||||
|
Antes de que el objeto empiece a sacar valores hay que crear el nodo. Para ello hay que mandar un mensaje [open "nº subnet" "nº universo"].
|
||||||
|
También podemos especificar la IP del interface ene l que escuchará mandando el mensaje "ip + dirección ip" antes de mandar el mensaje open.
|
||||||
|
Si no le mandamos ningún parámetro con el mesaje open el objeto escucha en el interface activo con la IP más baja, típicamente 2.x.x.x, en la subnet 0 y universo 0.
|
||||||
|
El objeto saca una lista de 512 enteros con el universo entero.
|
||||||
|
Si queremos cambiar el universo, a subnet o la dirección ip hay que mandar un mensaje [close] y luego mandar un nuevo mensaje open con la nueva configuración.
|
||||||
|
Mandando bang al objeto nos imprime en la ventana de estado si el nodo está activo y en caso afirmativo en qué subnet, unverso y direcicń ip está escuchando.
|
||||||
|
|
||||||
|
*****************************
|
||||||
|
|
||||||
|
Ayuda y soporte:
|
||||||
|
|
||||||
|
puremediaserver@googlegroups.com
|
||||||
|
|
||||||
|
*****************************
|
||||||
|
|
346
externals/artnetin/artnet.h
vendored
Executable file
346
externals/artnetin/artnet.h
vendored
Executable file
|
@ -0,0 +1,346 @@
|
||||||
|
/*
|
||||||
|
* This library is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU Lesser General Public
|
||||||
|
* License as published by the Free Software Foundation; either
|
||||||
|
* version 2.1 of the License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This library is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
* Lesser General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU Lesser General Public
|
||||||
|
* License along with this library; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
*
|
||||||
|
* artnet.h
|
||||||
|
* Interface to libartnet
|
||||||
|
* Copyright (C) 2004-2007 Simon Newton
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef ARTNET_HEADER_H
|
||||||
|
#define ARTNET_HEADER_H
|
||||||
|
|
||||||
|
#include <stdint.h>
|
||||||
|
// order is important here for osx
|
||||||
|
#include <sys/types.h>
|
||||||
|
|
||||||
|
#ifndef WIN32
|
||||||
|
#include <sys/select.h>
|
||||||
|
#else
|
||||||
|
#include <Winsock2.h>
|
||||||
|
typedef unsigned long in_addr_t;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <artnet/common.h>
|
||||||
|
|
||||||
|
/* the external storage class is "extern" in UNIX; in MSW it's ugly. */
|
||||||
|
#ifndef EXTERN
|
||||||
|
#ifdef MSW
|
||||||
|
#define EXTERN __declspec(dllexport) extern
|
||||||
|
#else
|
||||||
|
#define EXTERN extern
|
||||||
|
#endif /* MSW */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
|
EXTERN int ARTNET_ADDRESS_NO_CHANGE;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* An enum for setting the behaviour of a port.
|
||||||
|
* Ports can either input data (DMX -> ArtNet) or
|
||||||
|
* output (ArtNet -> DMX) data.
|
||||||
|
*/
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_ENABLE_INPUT = 0x40, /**< Enables the input for this port */
|
||||||
|
ARTNET_ENABLE_OUTPUT = 0x80 /**< Enables the output for this port */
|
||||||
|
} artnet_port_settings_t;
|
||||||
|
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_PC_NONE = 0x00,
|
||||||
|
ARTNET_PC_CANCEL = 0x01,
|
||||||
|
ARTNET_PC_LED_NORMAL = 0x02,
|
||||||
|
ARTNET_PC_LED_MUTE = 0x03,
|
||||||
|
ARTNET_PC_LED_LOCATE = 0x04,
|
||||||
|
ARTNET_PC_RESET = 0x05,
|
||||||
|
ARTNET_PC_MERGE_LTP_O = 0x10,
|
||||||
|
ARTNET_PC_MERGE_LTP_1 = 0x11,
|
||||||
|
ARTNET_PC_MERGE_LTP_2 = 0x12,
|
||||||
|
ARTNET_PC_MERGE_LTP_3 = 0x13,
|
||||||
|
ARTNET_PC_MERGE_HTP_0 = 0x50,
|
||||||
|
ARTNET_PC_MERGE_HTP_1 = 0x51,
|
||||||
|
ARTNET_PC_MERGE_HTP_2 = 0x52,
|
||||||
|
ARTNET_PC_MERGE_HTP_3 = 0x53,
|
||||||
|
ARTNET_PC_CLR_0 = 0x93,
|
||||||
|
ARTNET_PC_CLR_1 = 0x93,
|
||||||
|
ARTNET_PC_CLR_2 = 0x93,
|
||||||
|
ARTNET_PC_CLR_3 = 0x93,
|
||||||
|
} artnet_port_command_t;
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* An enum for the type of data transmitted on a port.
|
||||||
|
* As far as I know, only DMX-512 is supported
|
||||||
|
*/
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_PORT_DMX = 0x00, /**< Data is DMX-512 */
|
||||||
|
ARTNET_PORT_MIDI = 0x01, /**< Data is MIDI */
|
||||||
|
ARTNET_PORT_AVAB = 0x02, /**< Data is Avab */
|
||||||
|
ARTNET_PORT_CMX = 0x03, /**< Data is Colortran CMX */
|
||||||
|
ARTNET_PORT_ADB = 0x04, /**< Data is ABD 62.5 */
|
||||||
|
ARTNET_PORT_ARTNET = 0x05 /**< Data is ArtNet */
|
||||||
|
} artnet_port_data_code;
|
||||||
|
|
||||||
|
|
||||||
|
// defines the status of the firmware transfer
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_FIRMWARE_BLOCKGOOD = 0x00,
|
||||||
|
ARTNET_FIRMWARE_ALLGOOD = 0x01,
|
||||||
|
ARTNET_FIRMWARE_FAIL = 0xff,
|
||||||
|
} artnet_firmware_status_code;
|
||||||
|
|
||||||
|
// tod actions
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_TOD_FULL = 0x00,
|
||||||
|
ARTNET_TOD_FLUSH = 0x01,
|
||||||
|
} artnet_tod_command_code;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* An enum for refering to a particular input or output port.
|
||||||
|
*/
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_INPUT_PORT = 1, /**< The input port */
|
||||||
|
ARTNET_OUTPUT_PORT, /**< The output port */
|
||||||
|
} artnet_port_dir_t;
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Enum describing the type of node
|
||||||
|
*/
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_SRV, /**< An ArtNet server (transmitts DMX data) */
|
||||||
|
ARTNET_NODE, /**< An ArtNet node (dmx reciever) */
|
||||||
|
ARTNET_MSRV, /**< A Media Server */
|
||||||
|
ARTNET_ROUTE, /**< No Effect currently */
|
||||||
|
ARTNET_BACKUP, /**< No Effect currently */
|
||||||
|
ARTNET_RAW /**< Raw Node - used for diagnostics */
|
||||||
|
} artnet_node_type;
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Enum for the talk-to-me value
|
||||||
|
* These values can be &'ed togeather, so for example to set private replies
|
||||||
|
* and auto replying use :
|
||||||
|
* (ARTNET_TTM_PRIVATE & ARTNET_TTM_AUTO)
|
||||||
|
*/
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_TTM_DEFAULT = 0xFF, /**< default, ArtPollReplies are broadcast, and nodes won't send a ArtPollReply when conditions change */
|
||||||
|
ARTNET_TTM_PRIVATE = 0xFE, /**< ArtPollReplies aren't broadcast */
|
||||||
|
ARTNET_TTM_AUTO = 0xFD /**< ArtPollReplies are send when node conditions chang */
|
||||||
|
} artnet_ttm_value_t;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Enums for the application defined handlers
|
||||||
|
*/
|
||||||
|
typedef enum {
|
||||||
|
ARTNET_RECV_HANDLER, /**< Called on reciept of any ArtNet packet */
|
||||||
|
ARTNET_SEND_HANDLER, /**< Called on transmission of any ArtNet packet */
|
||||||
|
ARTNET_POLL_HANDLER, /**< Called on reciept of an ArtPoll packet */
|
||||||
|
ARTNET_REPLY_HANDLER, /**< Called on reciept of an ArtPollReply packet */
|
||||||
|
ARTNET_DMX_HANDLER, /**< Called on reciept of an ArtDMX packet */
|
||||||
|
ARTNET_ADDRESS_HANDLER, /**< Called on reciept of an ArtAddress packet */
|
||||||
|
ARTNET_INPUT_HANDLER, /**< Called on reciept of an ArtInput packet */
|
||||||
|
ARTNET_TOD_REQUEST_HANDLER, /**< Called on reciept of an ArtTodRequest packet */
|
||||||
|
ARTNET_TOD_DATA_HANDLER, /**< Called on reciept of an ArtTodData packet */
|
||||||
|
ARTNET_TOD_CONTROL_HANDLER, /**< Called on reciept of an ArtTodControl packet */
|
||||||
|
ARTNET_RDM_HANDLER, /**< Called on reciept of an ArtRdm packet */
|
||||||
|
ARTNET_IPPROG_HANDLER, /**< Called on reciept of an ArtIPProg packet */
|
||||||
|
ARTNET_FIRMWARE_HANDLER, /**< Called on reciept of an ArtFirmware packet */
|
||||||
|
ARTNET_FIRMWARE_REPLY_HANDLER, /**< Called on reciept of an ArtFirmwareReply packet */
|
||||||
|
} artnet_handler_name_t;
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Describes a remote ArtNet node that has been discovered
|
||||||
|
*/
|
||||||
|
typedef struct artnet_node_entry_s {
|
||||||
|
uint8_t ip[ARTNET_IP_SIZE]; /**< The IP address, Network byte ordered*/
|
||||||
|
int16_t ver; /**< The firmware version */
|
||||||
|
int16_t sub; /**< The subnet address */
|
||||||
|
int16_t oem; /**< The OEM value */
|
||||||
|
uint8_t ubea; /**< The UBEA version */
|
||||||
|
uint8_t status;
|
||||||
|
uint8_t etsaman[ARTNET_ESTA_SIZE]; /**< The ESTA Manufacturer code */
|
||||||
|
uint8_t shortname[ARTNET_SHORT_NAME_LENGTH]; /**< The short node name */
|
||||||
|
uint8_t longname[ARTNET_LONG_NAME_LENGTH]; /**< The long node name */
|
||||||
|
uint8_t nodereport[ARTNET_REPORT_LENGTH]; /**< The node report */
|
||||||
|
int16_t numbports; /**< The number of ports */
|
||||||
|
uint8_t porttypes[ARTNET_MAX_PORTS]; /**< The type of ports */
|
||||||
|
uint8_t goodinput[ARTNET_MAX_PORTS];
|
||||||
|
uint8_t goodoutput[ARTNET_MAX_PORTS];
|
||||||
|
uint8_t swin[ARTNET_MAX_PORTS];
|
||||||
|
uint8_t swout[ARTNET_MAX_PORTS];
|
||||||
|
uint8_t swvideo;
|
||||||
|
uint8_t swmacro;
|
||||||
|
uint8_t swremote;
|
||||||
|
uint8_t style;
|
||||||
|
uint8_t mac[ARTNET_MAC_SIZE]; /**< The MAC address of the node */
|
||||||
|
} artnet_node_entry_t;
|
||||||
|
|
||||||
|
/** A pointer to an artnet_node_entry_t */
|
||||||
|
typedef artnet_node_entry_t *artnet_node_entry;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
char short_name[ARTNET_SHORT_NAME_LENGTH];
|
||||||
|
char long_name[ARTNET_LONG_NAME_LENGTH];
|
||||||
|
uint8_t subnet;
|
||||||
|
uint8_t in_ports[ARTNET_MAX_PORTS];
|
||||||
|
uint8_t out_ports[ARTNET_MAX_PORTS];
|
||||||
|
} artnet_node_config_t;
|
||||||
|
|
||||||
|
|
||||||
|
/** The local ArtNet node */
|
||||||
|
typedef void *artnet_node;
|
||||||
|
|
||||||
|
/** A list of remote ArtNet nodes */
|
||||||
|
typedef void *artnet_node_list;
|
||||||
|
|
||||||
|
// node control functions
|
||||||
|
EXTERN artnet_node artnet_new(const char *ip, int verbose);
|
||||||
|
EXTERN int artnet_setoem(artnet_node vn, uint8_t hi, uint8_t lo);
|
||||||
|
EXTERN int artnet_setesta(artnet_node vn, char hi, char lo);
|
||||||
|
EXTERN int artnet_set_bcast_limit(artnet_node vn, int limit);
|
||||||
|
EXTERN int artnet_start(artnet_node n);
|
||||||
|
EXTERN int artnet_read(artnet_node n, int timeout);
|
||||||
|
EXTERN int artnet_stop(artnet_node n);
|
||||||
|
EXTERN int artnet_destroy(artnet_node n);
|
||||||
|
|
||||||
|
int artnet_join(artnet_node vn1, artnet_node vn2);
|
||||||
|
|
||||||
|
// handler functions
|
||||||
|
// these need to be cleaned up into a generic interface
|
||||||
|
EXTERN int artnet_set_handler(artnet_node vn,
|
||||||
|
artnet_handler_name_t handler,
|
||||||
|
int (*fh)(artnet_node n, void *pp, void *d),
|
||||||
|
void* data);
|
||||||
|
EXTERN int artnet_set_dmx_handler(artnet_node vn,
|
||||||
|
int (*fh)(artnet_node n, int port, void *d),
|
||||||
|
void *data);
|
||||||
|
EXTERN int artnet_set_program_handler(artnet_node vn,
|
||||||
|
int (*fh)(artnet_node n, void *d),
|
||||||
|
void *data);
|
||||||
|
EXTERN int artnet_set_firmware_handler(artnet_node vn,
|
||||||
|
int (*fh)(artnet_node n, int ubea, uint16_t *data, int length, void *d),
|
||||||
|
void *data);
|
||||||
|
EXTERN int artnet_set_rdm_handler(artnet_node vn,
|
||||||
|
int (*fh)(artnet_node n, int address, uint8_t *rdm, int length, void *d),
|
||||||
|
void *data);
|
||||||
|
EXTERN int artnet_set_rdm_initiate_handler(artnet_node vn,
|
||||||
|
int (*fh)(artnet_node n, int port, void *d),
|
||||||
|
void *data);
|
||||||
|
EXTERN int artnet_set_rdm_tod_handler(artnet_node vn,
|
||||||
|
int (*fh)(artnet_node n, int port, void *d),
|
||||||
|
void *data);
|
||||||
|
|
||||||
|
// send functions
|
||||||
|
EXTERN int artnet_send_poll(artnet_node n,
|
||||||
|
const char *ip,
|
||||||
|
artnet_ttm_value_t talk_to_me);
|
||||||
|
EXTERN int artnet_send_poll_reply(artnet_node n);
|
||||||
|
EXTERN int artnet_send_dmx(artnet_node n,
|
||||||
|
int port_id,
|
||||||
|
int16_t length,
|
||||||
|
const uint8_t *data);
|
||||||
|
EXTERN int artnet_raw_send_dmx(artnet_node vn,
|
||||||
|
uint8_t uni,
|
||||||
|
int16_t length,
|
||||||
|
const uint8_t *data);
|
||||||
|
EXTERN int artnet_send_address(artnet_node n,
|
||||||
|
artnet_node_entry e,
|
||||||
|
const char *shortName,
|
||||||
|
const char *longName,
|
||||||
|
uint8_t inAddr[ARTNET_MAX_PORTS],
|
||||||
|
uint8_t outAddr[ARTNET_MAX_PORTS],
|
||||||
|
uint8_t subAddr,
|
||||||
|
artnet_port_command_t cmd);
|
||||||
|
EXTERN int artnet_send_input(artnet_node n,
|
||||||
|
artnet_node_entry e,
|
||||||
|
uint8_t settings[ARTNET_MAX_PORTS]);
|
||||||
|
EXTERN int artnet_send_firmware(artnet_node vn,
|
||||||
|
artnet_node_entry e,
|
||||||
|
int ubea,
|
||||||
|
uint16_t *data,
|
||||||
|
int length,
|
||||||
|
int (*fh)(artnet_node n, artnet_firmware_status_code code, void *d),
|
||||||
|
void *user_data);
|
||||||
|
EXTERN int artnet_send_firmware_reply(artnet_node vn,
|
||||||
|
artnet_node_entry e,
|
||||||
|
artnet_firmware_status_code code);
|
||||||
|
|
||||||
|
// rdm functions
|
||||||
|
EXTERN int artnet_send_tod_request(artnet_node vn);
|
||||||
|
EXTERN int artnet_send_tod_control(artnet_node vn,
|
||||||
|
uint8_t address,
|
||||||
|
artnet_tod_command_code action);
|
||||||
|
EXTERN int artnet_send_tod_data(artnet_node vn, int port);
|
||||||
|
EXTERN int artnet_send_rdm(artnet_node vn,
|
||||||
|
uint8_t address,
|
||||||
|
uint8_t *data,
|
||||||
|
int length);
|
||||||
|
EXTERN int artnet_add_rdm_device(artnet_node vn,
|
||||||
|
int port,
|
||||||
|
uint8_t uid[ARTNET_RDM_UID_WIDTH]);
|
||||||
|
EXTERN int artnet_add_rdm_devices(artnet_node vn,
|
||||||
|
int port,
|
||||||
|
uint8_t *uid,
|
||||||
|
int count);
|
||||||
|
EXTERN int artnet_remove_rdm_device(artnet_node vn,
|
||||||
|
int port,
|
||||||
|
uint8_t uid[ARTNET_RDM_UID_WIDTH]);
|
||||||
|
|
||||||
|
// recv functions
|
||||||
|
EXTERN uint8_t *artnet_read_dmx(artnet_node n, int port_id, int *length);
|
||||||
|
|
||||||
|
// state changing functions
|
||||||
|
EXTERN int artnet_set_node_type(artnet_node n, artnet_node_type type);
|
||||||
|
EXTERN int artnet_set_short_name(artnet_node vn, const char *name);
|
||||||
|
EXTERN int artnet_set_long_name(artnet_node n, const char *name);
|
||||||
|
|
||||||
|
//port manipulation functions
|
||||||
|
EXTERN int artnet_set_port_type(artnet_node n,
|
||||||
|
int id,
|
||||||
|
artnet_port_settings_t settings,
|
||||||
|
artnet_port_data_code data);
|
||||||
|
EXTERN int artnet_set_port_addr(artnet_node n,
|
||||||
|
int id,
|
||||||
|
artnet_port_dir_t dir,
|
||||||
|
uint8_t addr);
|
||||||
|
EXTERN int artnet_set_subnet_addr(artnet_node n, uint8_t subnet);
|
||||||
|
EXTERN int artnet_get_universe_addr(artnet_node n,
|
||||||
|
int id,
|
||||||
|
artnet_port_dir_t dir);
|
||||||
|
|
||||||
|
//node list functions
|
||||||
|
EXTERN artnet_node_list artnet_get_nl(artnet_node n);
|
||||||
|
EXTERN artnet_node_entry artnet_nl_first(artnet_node_list nl);
|
||||||
|
EXTERN artnet_node_entry artnet_nl_next(artnet_node_list nl);
|
||||||
|
EXTERN int artnet_nl_get_length(artnet_node_list nl);
|
||||||
|
|
||||||
|
// misc
|
||||||
|
EXTERN int artnet_dump_config(artnet_node n);
|
||||||
|
EXTERN int artnet_get_config(artnet_node n, artnet_node_config_t *config);
|
||||||
|
EXTERN int artnet_get_sd(artnet_node n);
|
||||||
|
EXTERN int artnet_set_fdset(artnet_node vn, fd_set *fdset);
|
||||||
|
|
||||||
|
char *artnet_strerror();
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
61
externals/artnetin/artnetin-help.pd
vendored
Executable file
61
externals/artnetin/artnetin-help.pd
vendored
Executable file
|
@ -0,0 +1,61 @@
|
||||||
|
#N canvas 565 87 709 679 10;
|
||||||
|
#X obj 157 287 artnetin;
|
||||||
|
#X floatatom 156 392 5 0 0 0 - - -;
|
||||||
|
#X floatatom 207 395 5 0 0 0 - - -;
|
||||||
|
#X floatatom 251 397 5 0 0 0 - - -;
|
||||||
|
#X floatatom 294 401 5 0 0 0 - - -;
|
||||||
|
#X floatatom 404 400 5 0 0 0 - - -;
|
||||||
|
#X floatatom 502 408 5 0 0 0 - - -;
|
||||||
|
#X obj 157 333 unpack f f f f f f f f f f f f f f f f f f f f f f f
|
||||||
|
f f f f f f f;
|
||||||
|
#X msg 45 189 close;
|
||||||
|
#X obj 227 179 pack f f;
|
||||||
|
#X floatatom 227 118 5 0 0 0 - - -;
|
||||||
|
#X floatatom 272 119 5 0 0 0 - - -;
|
||||||
|
#X text 183 116 Subnet;
|
||||||
|
#X text 306 119 universe;
|
||||||
|
#X text 300 215 Open the node at subnet/universe;
|
||||||
|
#X text 22 173 Close the node;
|
||||||
|
#X text 222 306 List 512 floats (DMX array);
|
||||||
|
#X obj 248 70 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
|
||||||
|
-1;
|
||||||
|
#X obj 157 113 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
|
||||||
|
-1 -1;
|
||||||
|
#X obj 61 368 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
|
||||||
|
-1;
|
||||||
|
#X text 18 111 Show status on console;
|
||||||
|
#X text 431 98 You must close the node and reopen it before new settings
|
||||||
|
take effect;
|
||||||
|
#X msg 550 217 ip 127.0.0.1;
|
||||||
|
#X text 547 199 Define which interface the node will open;
|
||||||
|
#X text 541 239 Defaults to lower ip addres;
|
||||||
|
#X obj 243 149 t b;
|
||||||
|
#X msg 227 213 open 2 2;
|
||||||
|
#X msg 231 238 open;
|
||||||
|
#X msg 322 180 open 5 5;
|
||||||
|
#X msg 167 181 open 0 0;
|
||||||
|
#X msg 546 181 ip 192.168.1.100;
|
||||||
|
#X msg 550 135 ip 2.0.0.100;
|
||||||
|
#X connect 0 0 7 0;
|
||||||
|
#X connect 0 0 19 0;
|
||||||
|
#X connect 7 0 1 0;
|
||||||
|
#X connect 7 1 2 0;
|
||||||
|
#X connect 7 2 3 0;
|
||||||
|
#X connect 7 3 4 0;
|
||||||
|
#X connect 7 19 5 0;
|
||||||
|
#X connect 7 29 6 0;
|
||||||
|
#X connect 8 0 0 0;
|
||||||
|
#X connect 10 0 9 0;
|
||||||
|
#X connect 11 0 9 1;
|
||||||
|
#X connect 11 0 25 0;
|
||||||
|
#X connect 17 0 10 0;
|
||||||
|
#X connect 17 0 11 0;
|
||||||
|
#X connect 18 0 0 0;
|
||||||
|
#X connect 22 0 0 0;
|
||||||
|
#X connect 25 0 9 0;
|
||||||
|
#X connect 26 0 0 0;
|
||||||
|
#X connect 27 0 0 0;
|
||||||
|
#X connect 28 0 0 0;
|
||||||
|
#X connect 29 0 0 0;
|
||||||
|
#X connect 30 0 0 0;
|
||||||
|
#X connect 31 0 0 0;
|
7
externals/artnetin/artnetin-meta.pd
vendored
Executable file
7
externals/artnetin/artnetin-meta.pd
vendored
Executable file
|
@ -0,0 +1,7 @@
|
||||||
|
#N canvas 15 49 200 200 10;
|
||||||
|
#N canvas 627 208 420 300 META 1;
|
||||||
|
#X text 13 41 NAME Artnetin;
|
||||||
|
#X text 10 25 AUTHOR Santiago Noreña puremediaserver@googlegroups.com
|
||||||
|
;
|
||||||
|
#X text 10 10 VERSION 0.0.4;
|
||||||
|
#X restore 10 10 pd META;
|
301
externals/artnetin/artnetin.c
vendored
Executable file
301
externals/artnetin/artnetin.c
vendored
Executable file
|
@ -0,0 +1,301 @@
|
||||||
|
/*
|
||||||
|
* artnetin is an external for Pure Data that reads an artnet universe
|
||||||
|
* and outputs it in an outlet like a list of 512 int.
|
||||||
|
*
|
||||||
|
* artnetin needs libartnet installed in the sytem to work
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This program is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation; either version 2
|
||||||
|
* of the License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
*/
|
||||||
|
/*
|
||||||
|
* Santiago Noreña
|
||||||
|
* puremediaserver@gmail.com
|
||||||
|
* Versión 0.0.4
|
||||||
|
*
|
||||||
|
* Based on previous works by:
|
||||||
|
* Dirk Jagdmann (doj@cubic.org) dmxmonitor
|
||||||
|
* Simon Newton (nomis52@westnet.com.au) libartnet and modified dmxmonitor to use ArtNet
|
||||||
|
* Patrick Sébastien http://www.workinprogress.ca/ pure data external pthread template
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
/*
|
||||||
|
* ToDo:
|
||||||
|
* - Cambiar funciones Unix por funciones PD (getbytes, freebytes,...)
|
||||||
|
* - cambiar variables a syntaxis pure data (x_subnet)
|
||||||
|
* - método max channels distinto de 512
|
||||||
|
* - meter thread_start en función principal
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "m_pd.h"
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
#include "pthread.h"
|
||||||
|
#include "artnet.h"
|
||||||
|
#include <malloc.h>
|
||||||
|
|
||||||
|
// ==============================================================================
|
||||||
|
// Our External's Memory structure
|
||||||
|
// ------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
t_class *artnetin_class;
|
||||||
|
|
||||||
|
typedef struct _artnetin
|
||||||
|
{
|
||||||
|
t_object x_obj;
|
||||||
|
artnet_node node; // el nodo artnet
|
||||||
|
int CHANNELS; // la longitud del array dmx
|
||||||
|
t_outlet *outlet1; // outlet pointer
|
||||||
|
int subnet; // variables subnet y universo; solo utiles para mostrar informacion del nodo en bang
|
||||||
|
int universe;
|
||||||
|
pthread_attr_t artnetin_thread_attr;
|
||||||
|
pthread_t x_threadid; // Control de thread
|
||||||
|
char *ip; // variable para definir el interface donde se creará el nodo.
|
||||||
|
} t_artnetin;
|
||||||
|
|
||||||
|
unsigned char *dmx; // El array DMX
|
||||||
|
|
||||||
|
// ==============================================================================
|
||||||
|
// dmx handler -
|
||||||
|
// ------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
static int dmx_handler(artnet_node node, int prt , void *d) {
|
||||||
|
int z;
|
||||||
|
int len;
|
||||||
|
t_artnetin *x = (t_artnetin*) d;
|
||||||
|
uint8_t *g = dmx; // Puntero al array dmx
|
||||||
|
uint8_t *data; // Puntero
|
||||||
|
data = artnet_read_dmx(node, prt, &len) ; // Nos devuelve el array dmx en data?
|
||||||
|
memcpy(g, data, len) ; // Copia el array dmx devuelto a g
|
||||||
|
|
||||||
|
t_atom dmxa[x->CHANNELS]; // Crea un array dmx en formato float pure dat
|
||||||
|
uint8_t *b = dmx; // Otro puntero a dmx; no podemos usar g?
|
||||||
|
for(z=0; z < x->CHANNELS; z++){ // Copiamos el array dmx al array dmxa
|
||||||
|
SETFLOAT(dmxa+z, *b);
|
||||||
|
b++;
|
||||||
|
}
|
||||||
|
outlet_list(x->outlet1 ,gensym("list"), x->CHANNELS, dmxa); // Saca el array dmxa mediante una lista
|
||||||
|
return (0);
|
||||||
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
// - bang - Devuelve información del estado del nodo
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
void artnetin_bang(t_artnetin *x) {
|
||||||
|
if ((int)x->x_threadid == 0) {
|
||||||
|
post ("Artnetin: Node not created");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
post ("Artnetin: Node created on thread %d", x->x_threadid);
|
||||||
|
post ("Artnetin: listening on Subnet %d Universe %d and IP address %s", x->subnet, x->universe, x->ip);
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// =============================================================================
|
||||||
|
// Worker Thread
|
||||||
|
// =============================================================================
|
||||||
|
static void *thread_read(void *w)
|
||||||
|
{
|
||||||
|
t_artnetin *x = (t_artnetin*) w;
|
||||||
|
int n, max, z;
|
||||||
|
int i = 0;
|
||||||
|
int artnet_sd;
|
||||||
|
pthread_testcancel();
|
||||||
|
while(1) {
|
||||||
|
artnet_sd = artnet_get_sd(x->node) ;
|
||||||
|
fd_set rd_fds;
|
||||||
|
struct timeval tv;
|
||||||
|
FD_ZERO(&rd_fds);
|
||||||
|
FD_SET(0, &rd_fds);
|
||||||
|
FD_SET(artnet_sd, &rd_fds) ;
|
||||||
|
max = artnet_sd ;
|
||||||
|
tv.tv_sec = 1;
|
||||||
|
tv.tv_usec = 0;
|
||||||
|
n = select(max+1, &rd_fds, NULL, NULL, &tv);
|
||||||
|
if(n>0) {
|
||||||
|
if (FD_ISSET(artnet_sd , &rd_fds)){
|
||||||
|
i = artnet_read(x->node,0);
|
||||||
|
}
|
||||||
|
if (i == 0) {
|
||||||
|
|
||||||
|
|
||||||
|
t_atom dmxa[x->CHANNELS];
|
||||||
|
uint8_t *b = dmx;
|
||||||
|
for(z=0; z<x->CHANNELS; z++){
|
||||||
|
SETFLOAT(dmxa+z, *b);
|
||||||
|
b++;
|
||||||
|
}
|
||||||
|
outlet_list(x->outlet1 ,gensym("list"), x->CHANNELS, dmxa);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
error("Artnetin: Bucle Read Error");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
// =============================================================================
|
||||||
|
// Start Thread
|
||||||
|
// =============================================================================
|
||||||
|
|
||||||
|
static void thread_start(t_artnetin *x)
|
||||||
|
{
|
||||||
|
|
||||||
|
// create the worker thread
|
||||||
|
if(pthread_attr_init(&x->artnetin_thread_attr) < 0)
|
||||||
|
{
|
||||||
|
sys_lock();
|
||||||
|
error("Artnetin: could not launch receive thread");
|
||||||
|
sys_unlock();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if(pthread_attr_setdetachstate(&x->artnetin_thread_attr, PTHREAD_CREATE_DETACHED) < 0)
|
||||||
|
{
|
||||||
|
sys_lock();
|
||||||
|
error("Artnetin: could not launch receive thread");
|
||||||
|
sys_unlock();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if(pthread_create(&x->x_threadid, &x->artnetin_thread_attr, thread_read, x) < 0)
|
||||||
|
{
|
||||||
|
sys_lock();
|
||||||
|
error("Artnetin: could not launch receive thread");
|
||||||
|
sys_unlock();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sys_lock();
|
||||||
|
post("Artnetin: thread %d launched", (int)x->x_threadid );
|
||||||
|
sys_unlock();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
// - Message: ip - define el interface donde escuchará el nodo mediante la ip
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
|
||||||
|
void artnetin_ip(t_artnetin *x, t_symbol *ip_addres)
|
||||||
|
{
|
||||||
|
x->ip = getbytes(15);
|
||||||
|
strcpy(x->ip, ip_addres->s_name);
|
||||||
|
post("Artnetin: IP %s", x->ip);
|
||||||
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
// - Message: open - Empieza el nodo artnet y lanza el thread que escuchará en ese nodo
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
void artnetin_open(t_artnetin *x, t_floatarg f1, t_floatarg f2)
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
if ((int)x->x_threadid == 0) {
|
||||||
|
x->subnet = f1;
|
||||||
|
x->universe = f2;
|
||||||
|
post("Artnetin: opening node Artnet Subnet %d Universe %d IP %s", x->subnet, x->universe, x->ip);
|
||||||
|
|
||||||
|
// char * ip_addr = NULL;
|
||||||
|
|
||||||
|
x->node = artnet_new(x->ip, 0 );
|
||||||
|
if(x->node == NULL) {
|
||||||
|
error("Artnetin: Unable to connect") ;
|
||||||
|
}
|
||||||
|
artnet_set_dmx_handler(x->node, dmx_handler, x);
|
||||||
|
artnet_set_subnet_addr(x->node, x->subnet);
|
||||||
|
artnet_set_port_type(x->node, 0, ARTNET_ENABLE_OUTPUT, ARTNET_PORT_DMX) ;
|
||||||
|
artnet_set_port_addr(x->node, 0, ARTNET_OUTPUT_PORT, x->universe);
|
||||||
|
artnet_set_long_name(x->node, "Artnetin Pure Data 0.0.4");
|
||||||
|
artnet_set_short_name(x->node, "Artnetin-PD");
|
||||||
|
artnet_start(x->node);
|
||||||
|
int i = artnet_read(x->node,0);
|
||||||
|
if (i == 0) {
|
||||||
|
post("Artnetin: Init OK");
|
||||||
|
thread_start(x);
|
||||||
|
}
|
||||||
|
else error ("Artnetin: Init Error");
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
error ("Artnetin: Node created. Close it before try reopen");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
// - Message: close
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
void artnetin_close(t_artnetin *x)
|
||||||
|
{
|
||||||
|
if ((int)x->x_threadid == 0) {
|
||||||
|
error("Artnetin: node not created. Doing nothing");
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
post("Artnetin: closing node");
|
||||||
|
artnet_stop(x->node) ;
|
||||||
|
artnet_destroy(x->node) ;
|
||||||
|
while(pthread_cancel(x->x_threadid) < 0);
|
||||||
|
x->x_threadid = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
// - Initialization
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
|
||||||
|
void *artnetin_new(void)
|
||||||
|
{
|
||||||
|
|
||||||
|
post("Artnetin: an ArtNet interface : v0.0.4");
|
||||||
|
post(" written by Santiago Noreña (puremediaserver@gmail.com)");
|
||||||
|
t_artnetin *x = (t_artnetin *)pd_new(artnetin_class); // local variable (pointer to a t_artnetin data structure)
|
||||||
|
x->outlet1 = outlet_new(&x->x_obj, &s_list); // Saca todos los canales mediante una lista
|
||||||
|
x->CHANNELS = 512; // Define el número de canales del array dmx
|
||||||
|
dmx = malloc(512) ; // localiza memoria para el array dmx; Cambiar por getbytes
|
||||||
|
if(!dmx) {
|
||||||
|
error("Artnetin: malloc failed") ;
|
||||||
|
}
|
||||||
|
memset(dmx, 0x00, x->CHANNELS) ; // Inicializa el array dmx a 0
|
||||||
|
x->ip = NULL; // Inicializa la dirección ip a NULL = interface con ip más baja
|
||||||
|
return (void *)x;
|
||||||
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
// - Object destruction
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
|
||||||
|
void artnetin_free(t_artnetin *x)
|
||||||
|
{
|
||||||
|
artnetin_close(x);
|
||||||
|
freebytes(x->ip, 15);
|
||||||
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
// - Object creation and setup
|
||||||
|
//--------------------------------------------------------------------------
|
||||||
|
|
||||||
|
void artnetin_setup(void)
|
||||||
|
{
|
||||||
|
artnetin_class = class_new ( gensym("artnetin"),(t_newmethod)artnetin_new, 0, sizeof(t_artnetin), CLASS_DEFAULT, A_GIMME, 0);
|
||||||
|
// Add message handlers
|
||||||
|
class_addmethod(artnetin_class, (t_method)artnetin_open, gensym("open"), A_DEFFLOAT, A_DEFFLOAT, 0);
|
||||||
|
class_addmethod(artnetin_class, (t_method)artnetin_close, gensym("close"), 0);
|
||||||
|
class_addmethod(artnetin_class, (t_method)artnetin_ip, gensym("ip"), A_SYMBOL, 0);
|
||||||
|
class_addbang(artnetin_class, artnetin_bang);
|
||||||
|
}
|
||||||
|
|
39
externals/artnetin/examples/artnetin.pd
vendored
Executable file
39
externals/artnetin/examples/artnetin.pd
vendored
Executable file
|
@ -0,0 +1,39 @@
|
||||||
|
#N canvas 0 25 588 689 10;
|
||||||
|
#X obj 157 287 artnetin;
|
||||||
|
#X floatatom 156 392 5 0 0 0 - - -;
|
||||||
|
#X floatatom 207 395 5 0 0 0 - - -;
|
||||||
|
#X floatatom 251 397 5 0 0 0 - - -;
|
||||||
|
#X floatatom 294 401 5 0 0 0 - - -;
|
||||||
|
#X floatatom 404 400 5 0 0 0 - - -;
|
||||||
|
#X floatatom 502 408 5 0 0 0 - - -;
|
||||||
|
#X obj 157 333 unpack f f f f f f f f f f f f f f f f f f f f f f f
|
||||||
|
f f f f f f f;
|
||||||
|
#X msg 74 236 close;
|
||||||
|
#X msg 227 213 open \$1;
|
||||||
|
#X obj 227 158 pack f f;
|
||||||
|
#X floatatom 222 116 5 0 0 0 - - -;
|
||||||
|
#X floatatom 300 117 5 0 0 0 - - -;
|
||||||
|
#X text 182 118 Subnet;
|
||||||
|
#X text 338 119 universe;
|
||||||
|
#X text 288 212 Open the node at subnet/universe;
|
||||||
|
#X text 63 192 Close the node;
|
||||||
|
#X text 218 303 List 512 floats (DMX array);
|
||||||
|
#X text -40 271 You must close the node and reopen it before new settings
|
||||||
|
take effect;
|
||||||
|
#X obj 264 25 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
|
||||||
|
-1;
|
||||||
|
#X text 292 25 Bang to start node;
|
||||||
|
#X connect 0 0 7 0;
|
||||||
|
#X connect 7 0 1 0;
|
||||||
|
#X connect 7 1 2 0;
|
||||||
|
#X connect 7 2 3 0;
|
||||||
|
#X connect 7 3 4 0;
|
||||||
|
#X connect 7 19 5 0;
|
||||||
|
#X connect 7 29 6 0;
|
||||||
|
#X connect 8 0 0 0;
|
||||||
|
#X connect 9 0 0 0;
|
||||||
|
#X connect 10 0 9 0;
|
||||||
|
#X connect 11 0 10 0;
|
||||||
|
#X connect 12 0 10 1;
|
||||||
|
#X connect 19 0 11 0;
|
||||||
|
#X connect 19 0 12 0;
|
653
externals/artnetin/m_pd.h
vendored
Executable file
653
externals/artnetin/m_pd.h
vendored
Executable file
|
@ -0,0 +1,653 @@
|
||||||
|
/* Copyright (c) 1997-1999 Miller Puckette.
|
||||||
|
* For information on usage and redistribution, and for a DISCLAIMER OF ALL
|
||||||
|
* WARRANTIES, see the file, "LICENSE.txt," in this distribution. */
|
||||||
|
|
||||||
|
#ifndef __m_pd_h_
|
||||||
|
|
||||||
|
#if defined(_LANGUAGE_C_PLUS_PLUS) || defined(__cplusplus)
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define PD_MAJOR_VERSION 0
|
||||||
|
#define PD_MINOR_VERSION 42
|
||||||
|
#define PD_BUGFIX_VERSION 6
|
||||||
|
#define PD_TEST_VERSION ""
|
||||||
|
|
||||||
|
/* old name for "MSW" flag -- we have to take it for the sake of many old
|
||||||
|
"nmakefiles" for externs, which will define NT and not MSW */
|
||||||
|
#if defined(NT) && !defined(MSW)
|
||||||
|
#define MSW
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* These pragmas are only used for MSVC, not MinGW or Cygwin <hans@at.or.at> */
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
/* #pragma warning( disable : 4091 ) */
|
||||||
|
#pragma warning( disable : 4305 ) /* uncast const double to float */
|
||||||
|
#pragma warning( disable : 4244 ) /* uncast float/int conversion etc. */
|
||||||
|
#pragma warning( disable : 4101 ) /* unused automatic variables */
|
||||||
|
#endif /* _MSC_VER */
|
||||||
|
|
||||||
|
/* the external storage class is "extern" in UNIX; in MSW it's ugly. */
|
||||||
|
#ifdef MSW
|
||||||
|
#ifdef PD_INTERNAL
|
||||||
|
#define EXTERN __declspec(dllexport) extern
|
||||||
|
#else
|
||||||
|
#define EXTERN __declspec(dllimport) extern
|
||||||
|
#endif /* PD_INTERNAL */
|
||||||
|
#else
|
||||||
|
#define EXTERN extern
|
||||||
|
#endif /* MSW */
|
||||||
|
|
||||||
|
/* and depending on the compiler, hidden data structures are
|
||||||
|
declared differently: */
|
||||||
|
#if defined( __GNUC__) || defined( __BORLANDC__ ) || defined( __MWERKS__ )
|
||||||
|
#define EXTERN_STRUCT struct
|
||||||
|
#else
|
||||||
|
#define EXTERN_STRUCT extern struct
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#if !defined(_SIZE_T) && !defined(_SIZE_T_)
|
||||||
|
#include <stddef.h> /* just for size_t -- how lame! */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define MAXPDSTRING 1000 /* use this for anything you want */
|
||||||
|
#define MAXPDARG 5 /* max number of args we can typecheck today */
|
||||||
|
|
||||||
|
/* signed and unsigned integer types the size of a pointer: */
|
||||||
|
#if !defined(PD_LONGINTTYPE)
|
||||||
|
#define PD_LONGINTTYPE long
|
||||||
|
#endif
|
||||||
|
#if !defined(PD_FLOATTYPE)
|
||||||
|
#define PD_FLOATTYPE float
|
||||||
|
#endif
|
||||||
|
typedef PD_LONGINTTYPE t_int; /* pointer-size integer */
|
||||||
|
typedef PD_FLOATTYPE t_float; /* a float type at most the same size */
|
||||||
|
typedef PD_FLOATTYPE t_floatarg; /* float type for function calls */
|
||||||
|
|
||||||
|
typedef struct _symbol
|
||||||
|
{
|
||||||
|
char *s_name;
|
||||||
|
struct _class **s_thing;
|
||||||
|
struct _symbol *s_next;
|
||||||
|
} t_symbol;
|
||||||
|
|
||||||
|
EXTERN_STRUCT _array;
|
||||||
|
#define t_array struct _array /* g_canvas.h */
|
||||||
|
|
||||||
|
/* pointers to glist and array elements go through a "stub" which sticks
|
||||||
|
around after the glist or array is freed. The stub itself is deleted when
|
||||||
|
both the glist/array is gone and the refcount is zero, ensuring that no
|
||||||
|
gpointers are pointing here. */
|
||||||
|
|
||||||
|
#define GP_NONE 0 /* the stub points nowhere (has been cut off) */
|
||||||
|
#define GP_GLIST 1 /* the stub points to a glist element */
|
||||||
|
#define GP_ARRAY 2 /* ... or array */
|
||||||
|
|
||||||
|
typedef struct _gstub
|
||||||
|
{
|
||||||
|
union
|
||||||
|
{
|
||||||
|
struct _glist *gs_glist; /* glist we're in */
|
||||||
|
struct _array *gs_array; /* array we're in */
|
||||||
|
} gs_un;
|
||||||
|
int gs_which; /* GP_GLIST/GP_ARRAY */
|
||||||
|
int gs_refcount; /* number of gpointers pointing here */
|
||||||
|
} t_gstub;
|
||||||
|
|
||||||
|
typedef struct _gpointer /* pointer to a gobj in a glist */
|
||||||
|
{
|
||||||
|
union
|
||||||
|
{
|
||||||
|
struct _scalar *gp_scalar; /* scalar we're in (if glist) */
|
||||||
|
union word *gp_w; /* raw data (if array) */
|
||||||
|
} gp_un;
|
||||||
|
int gp_valid; /* number which must match gpointee */
|
||||||
|
t_gstub *gp_stub; /* stub which points to glist/array */
|
||||||
|
} t_gpointer;
|
||||||
|
|
||||||
|
typedef union word
|
||||||
|
{
|
||||||
|
t_float w_float;
|
||||||
|
t_symbol *w_symbol;
|
||||||
|
t_gpointer *w_gpointer;
|
||||||
|
t_array *w_array;
|
||||||
|
struct _glist *w_list;
|
||||||
|
int w_index;
|
||||||
|
} t_word;
|
||||||
|
|
||||||
|
typedef enum
|
||||||
|
{
|
||||||
|
A_NULL,
|
||||||
|
A_FLOAT,
|
||||||
|
A_SYMBOL,
|
||||||
|
A_POINTER,
|
||||||
|
A_SEMI,
|
||||||
|
A_COMMA,
|
||||||
|
A_DEFFLOAT,
|
||||||
|
A_DEFSYM,
|
||||||
|
A_DOLLAR,
|
||||||
|
A_DOLLSYM,
|
||||||
|
A_GIMME,
|
||||||
|
A_CANT
|
||||||
|
} t_atomtype;
|
||||||
|
|
||||||
|
#define A_DEFSYMBOL A_DEFSYM /* better name for this */
|
||||||
|
|
||||||
|
typedef struct _atom
|
||||||
|
{
|
||||||
|
t_atomtype a_type;
|
||||||
|
union word a_w;
|
||||||
|
} t_atom;
|
||||||
|
|
||||||
|
EXTERN_STRUCT _class;
|
||||||
|
#define t_class struct _class
|
||||||
|
|
||||||
|
EXTERN_STRUCT _outlet;
|
||||||
|
#define t_outlet struct _outlet
|
||||||
|
|
||||||
|
EXTERN_STRUCT _inlet;
|
||||||
|
#define t_inlet struct _inlet
|
||||||
|
|
||||||
|
EXTERN_STRUCT _binbuf;
|
||||||
|
#define t_binbuf struct _binbuf
|
||||||
|
|
||||||
|
EXTERN_STRUCT _clock;
|
||||||
|
#define t_clock struct _clock
|
||||||
|
|
||||||
|
EXTERN_STRUCT _outconnect;
|
||||||
|
#define t_outconnect struct _outconnect
|
||||||
|
|
||||||
|
EXTERN_STRUCT _glist;
|
||||||
|
#define t_glist struct _glist
|
||||||
|
#define t_canvas struct _glist /* LATER lose this */
|
||||||
|
|
||||||
|
typedef t_class *t_pd; /* pure datum: nothing but a class pointer */
|
||||||
|
|
||||||
|
typedef struct _gobj /* a graphical object */
|
||||||
|
{
|
||||||
|
t_pd g_pd; /* pure datum header (class) */
|
||||||
|
struct _gobj *g_next; /* next in list */
|
||||||
|
} t_gobj;
|
||||||
|
|
||||||
|
typedef struct _scalar /* a graphical object holding data */
|
||||||
|
{
|
||||||
|
t_gobj sc_gobj; /* header for graphical object */
|
||||||
|
t_symbol *sc_template; /* template name (LATER replace with pointer) */
|
||||||
|
t_word sc_vec[1]; /* indeterminate-length array of words */
|
||||||
|
} t_scalar;
|
||||||
|
|
||||||
|
typedef struct _text /* patchable object - graphical, with text */
|
||||||
|
{
|
||||||
|
t_gobj te_g; /* header for graphical object */
|
||||||
|
t_binbuf *te_binbuf; /* holder for the text */
|
||||||
|
t_outlet *te_outlet; /* linked list of outlets */
|
||||||
|
t_inlet *te_inlet; /* linked list of inlets */
|
||||||
|
short te_xpix; /* x&y location (within the toplevel) */
|
||||||
|
short te_ypix;
|
||||||
|
short te_width; /* requested width in chars, 0 if auto */
|
||||||
|
unsigned int te_type:2; /* from defs below */
|
||||||
|
} t_text;
|
||||||
|
|
||||||
|
#define T_TEXT 0 /* just a textual comment */
|
||||||
|
#define T_OBJECT 1 /* a MAX style patchable object */
|
||||||
|
#define T_MESSAGE 2 /* a MAX stype message */
|
||||||
|
#define T_ATOM 3 /* a cell to display a number or symbol */
|
||||||
|
|
||||||
|
#define te_pd te_g.g_pd
|
||||||
|
|
||||||
|
/* t_object is synonym for t_text (LATER unify them) */
|
||||||
|
|
||||||
|
typedef struct _text t_object;
|
||||||
|
|
||||||
|
#define ob_outlet te_outlet
|
||||||
|
#define ob_inlet te_inlet
|
||||||
|
#define ob_binbuf te_binbuf
|
||||||
|
#define ob_pd te_g.g_pd
|
||||||
|
#define ob_g te_g
|
||||||
|
|
||||||
|
typedef void (*t_method)(void);
|
||||||
|
typedef void *(*t_newmethod)( void);
|
||||||
|
typedef void (*t_gotfn)(void *x, ...);
|
||||||
|
|
||||||
|
/* ---------------- pre-defined objects and symbols --------------*/
|
||||||
|
EXTERN t_pd pd_objectmaker; /* factory for creating "object" boxes */
|
||||||
|
EXTERN t_pd pd_canvasmaker; /* factory for creating canvases */
|
||||||
|
EXTERN t_symbol s_pointer;
|
||||||
|
EXTERN t_symbol s_float;
|
||||||
|
EXTERN t_symbol s_symbol;
|
||||||
|
EXTERN t_symbol s_bang;
|
||||||
|
EXTERN t_symbol s_list;
|
||||||
|
EXTERN t_symbol s_anything;
|
||||||
|
EXTERN t_symbol s_signal;
|
||||||
|
EXTERN t_symbol s__N;
|
||||||
|
EXTERN t_symbol s__X;
|
||||||
|
EXTERN t_symbol s_x;
|
||||||
|
EXTERN t_symbol s_y;
|
||||||
|
EXTERN t_symbol s_;
|
||||||
|
|
||||||
|
/* --------- prototypes from the central message system ----------- */
|
||||||
|
EXTERN void pd_typedmess(t_pd *x, t_symbol *s, int argc, t_atom *argv);
|
||||||
|
EXTERN void pd_forwardmess(t_pd *x, int argc, t_atom *argv);
|
||||||
|
EXTERN t_symbol *gensym(const char *s);
|
||||||
|
EXTERN t_gotfn getfn(t_pd *x, t_symbol *s);
|
||||||
|
EXTERN t_gotfn zgetfn(t_pd *x, t_symbol *s);
|
||||||
|
EXTERN void nullfn(void);
|
||||||
|
EXTERN void pd_vmess(t_pd *x, t_symbol *s, char *fmt, ...);
|
||||||
|
#define mess0(x, s) ((*getfn((x), (s)))((x)))
|
||||||
|
#define mess1(x, s, a) ((*getfn((x), (s)))((x), (a)))
|
||||||
|
#define mess2(x, s, a,b) ((*getfn((x), (s)))((x), (a),(b)))
|
||||||
|
#define mess3(x, s, a,b,c) ((*getfn((x), (s)))((x), (a),(b),(c)))
|
||||||
|
#define mess4(x, s, a,b,c,d) ((*getfn((x), (s)))((x), (a),(b),(c),(d)))
|
||||||
|
#define mess5(x, s, a,b,c,d,e) ((*getfn((x), (s)))((x), (a),(b),(c),(d),(e)))
|
||||||
|
EXTERN void obj_list(t_object *x, t_symbol *s, int argc, t_atom *argv);
|
||||||
|
EXTERN t_pd *pd_newest(void);
|
||||||
|
|
||||||
|
/* --------------- memory management -------------------- */
|
||||||
|
EXTERN void *getbytes(size_t nbytes);
|
||||||
|
EXTERN void *getzbytes(size_t nbytes);
|
||||||
|
EXTERN void *copybytes(void *src, size_t nbytes);
|
||||||
|
EXTERN void freebytes(void *x, size_t nbytes);
|
||||||
|
EXTERN void *resizebytes(void *x, size_t oldsize, size_t newsize);
|
||||||
|
|
||||||
|
/* -------------------- atoms ----------------------------- */
|
||||||
|
|
||||||
|
#define SETSEMI(atom) ((atom)->a_type = A_SEMI, (atom)->a_w.w_index = 0)
|
||||||
|
#define SETCOMMA(atom) ((atom)->a_type = A_COMMA, (atom)->a_w.w_index = 0)
|
||||||
|
#define SETPOINTER(atom, gp) ((atom)->a_type = A_POINTER, \
|
||||||
|
(atom)->a_w.w_gpointer = (gp))
|
||||||
|
#define SETFLOAT(atom, f) ((atom)->a_type = A_FLOAT, (atom)->a_w.w_float = (f))
|
||||||
|
#define SETSYMBOL(atom, s) ((atom)->a_type = A_SYMBOL, \
|
||||||
|
(atom)->a_w.w_symbol = (s))
|
||||||
|
#define SETDOLLAR(atom, n) ((atom)->a_type = A_DOLLAR, \
|
||||||
|
(atom)->a_w.w_index = (n))
|
||||||
|
#define SETDOLLSYM(atom, s) ((atom)->a_type = A_DOLLSYM, \
|
||||||
|
(atom)->a_w.w_symbol= (s))
|
||||||
|
|
||||||
|
EXTERN t_float atom_getfloat(t_atom *a);
|
||||||
|
EXTERN t_int atom_getint(t_atom *a);
|
||||||
|
EXTERN t_symbol *atom_getsymbol(t_atom *a);
|
||||||
|
EXTERN t_symbol *atom_gensym(t_atom *a);
|
||||||
|
EXTERN t_float atom_getfloatarg(int which, int argc, t_atom *argv);
|
||||||
|
EXTERN t_int atom_getintarg(int which, int argc, t_atom *argv);
|
||||||
|
EXTERN t_symbol *atom_getsymbolarg(int which, int argc, t_atom *argv);
|
||||||
|
|
||||||
|
EXTERN void atom_string(t_atom *a, char *buf, unsigned int bufsize);
|
||||||
|
|
||||||
|
/* ------------------ binbufs --------------- */
|
||||||
|
|
||||||
|
EXTERN t_binbuf *binbuf_new(void);
|
||||||
|
EXTERN void binbuf_free(t_binbuf *x);
|
||||||
|
EXTERN t_binbuf *binbuf_duplicate(t_binbuf *y);
|
||||||
|
|
||||||
|
EXTERN void binbuf_text(t_binbuf *x, char *text, size_t size);
|
||||||
|
EXTERN void binbuf_gettext(t_binbuf *x, char **bufp, int *lengthp);
|
||||||
|
EXTERN void binbuf_clear(t_binbuf *x);
|
||||||
|
EXTERN void binbuf_add(t_binbuf *x, int argc, t_atom *argv);
|
||||||
|
EXTERN void binbuf_addv(t_binbuf *x, char *fmt, ...);
|
||||||
|
EXTERN void binbuf_addbinbuf(t_binbuf *x, t_binbuf *y);
|
||||||
|
EXTERN void binbuf_addsemi(t_binbuf *x);
|
||||||
|
EXTERN void binbuf_restore(t_binbuf *x, int argc, t_atom *argv);
|
||||||
|
EXTERN void binbuf_print(t_binbuf *x);
|
||||||
|
EXTERN int binbuf_getnatom(t_binbuf *x);
|
||||||
|
EXTERN t_atom *binbuf_getvec(t_binbuf *x);
|
||||||
|
EXTERN void binbuf_eval(t_binbuf *x, t_pd *target, int argc, t_atom *argv);
|
||||||
|
EXTERN int binbuf_read(t_binbuf *b, char *filename, char *dirname,
|
||||||
|
int crflag);
|
||||||
|
EXTERN int binbuf_read_via_canvas(t_binbuf *b, char *filename, t_canvas *canvas,
|
||||||
|
int crflag);
|
||||||
|
EXTERN int binbuf_read_via_path(t_binbuf *b, char *filename, char *dirname,
|
||||||
|
int crflag);
|
||||||
|
EXTERN int binbuf_write(t_binbuf *x, char *filename, char *dir,
|
||||||
|
int crflag);
|
||||||
|
EXTERN void binbuf_evalfile(t_symbol *name, t_symbol *dir);
|
||||||
|
EXTERN t_symbol *binbuf_realizedollsym(t_symbol *s, int ac, t_atom *av,
|
||||||
|
int tonew);
|
||||||
|
|
||||||
|
/* ------------------ clocks --------------- */
|
||||||
|
|
||||||
|
EXTERN t_clock *clock_new(void *owner, t_method fn);
|
||||||
|
EXTERN void clock_set(t_clock *x, double systime);
|
||||||
|
EXTERN void clock_delay(t_clock *x, double delaytime);
|
||||||
|
EXTERN void clock_unset(t_clock *x);
|
||||||
|
EXTERN double clock_getlogicaltime(void);
|
||||||
|
EXTERN double clock_getsystime(void); /* OBSOLETE; use clock_getlogicaltime() */
|
||||||
|
EXTERN double clock_gettimesince(double prevsystime);
|
||||||
|
EXTERN double clock_getsystimeafter(double delaytime);
|
||||||
|
EXTERN void clock_free(t_clock *x);
|
||||||
|
|
||||||
|
/* ----------------- pure data ---------------- */
|
||||||
|
EXTERN t_pd *pd_new(t_class *cls);
|
||||||
|
EXTERN void pd_free(t_pd *x);
|
||||||
|
EXTERN void pd_bind(t_pd *x, t_symbol *s);
|
||||||
|
EXTERN void pd_unbind(t_pd *x, t_symbol *s);
|
||||||
|
EXTERN t_pd *pd_findbyclass(t_symbol *s, t_class *c);
|
||||||
|
EXTERN void pd_pushsym(t_pd *x);
|
||||||
|
EXTERN void pd_popsym(t_pd *x);
|
||||||
|
EXTERN t_symbol *pd_getfilename(void);
|
||||||
|
EXTERN t_symbol *pd_getdirname(void);
|
||||||
|
EXTERN void pd_bang(t_pd *x);
|
||||||
|
EXTERN void pd_pointer(t_pd *x, t_gpointer *gp);
|
||||||
|
EXTERN void pd_float(t_pd *x, t_float f);
|
||||||
|
EXTERN void pd_symbol(t_pd *x, t_symbol *s);
|
||||||
|
EXTERN void pd_list(t_pd *x, t_symbol *s, int argc, t_atom *argv);
|
||||||
|
EXTERN void pd_anything(t_pd *x, t_symbol *s, int argc, t_atom *argv);
|
||||||
|
#define pd_class(x) (*(x))
|
||||||
|
|
||||||
|
/* ----------------- pointers ---------------- */
|
||||||
|
EXTERN void gpointer_init(t_gpointer *gp);
|
||||||
|
EXTERN void gpointer_copy(const t_gpointer *gpfrom, t_gpointer *gpto);
|
||||||
|
EXTERN void gpointer_unset(t_gpointer *gp);
|
||||||
|
EXTERN int gpointer_check(const t_gpointer *gp, int headok);
|
||||||
|
|
||||||
|
/* ----------------- patchable "objects" -------------- */
|
||||||
|
EXTERN t_inlet *inlet_new(t_object *owner, t_pd *dest, t_symbol *s1,
|
||||||
|
t_symbol *s2);
|
||||||
|
EXTERN t_inlet *pointerinlet_new(t_object *owner, t_gpointer *gp);
|
||||||
|
EXTERN t_inlet *floatinlet_new(t_object *owner, t_float *fp);
|
||||||
|
EXTERN t_inlet *symbolinlet_new(t_object *owner, t_symbol **sp);
|
||||||
|
EXTERN t_inlet *signalinlet_new(t_object *owner, t_float f);
|
||||||
|
EXTERN void inlet_free(t_inlet *x);
|
||||||
|
|
||||||
|
EXTERN t_outlet *outlet_new(t_object *owner, t_symbol *s);
|
||||||
|
EXTERN void outlet_bang(t_outlet *x);
|
||||||
|
EXTERN void outlet_pointer(t_outlet *x, t_gpointer *gp);
|
||||||
|
EXTERN void outlet_float(t_outlet *x, t_float f);
|
||||||
|
EXTERN void outlet_symbol(t_outlet *x, t_symbol *s);
|
||||||
|
EXTERN void outlet_list(t_outlet *x, t_symbol *s, int argc, t_atom *argv);
|
||||||
|
EXTERN void outlet_anything(t_outlet *x, t_symbol *s, int argc, t_atom *argv);
|
||||||
|
EXTERN t_symbol *outlet_getsymbol(t_outlet *x);
|
||||||
|
EXTERN void outlet_free(t_outlet *x);
|
||||||
|
EXTERN t_object *pd_checkobject(t_pd *x);
|
||||||
|
|
||||||
|
|
||||||
|
/* -------------------- canvases -------------- */
|
||||||
|
|
||||||
|
EXTERN void glob_setfilename(void *dummy, t_symbol *name, t_symbol *dir);
|
||||||
|
|
||||||
|
EXTERN void canvas_setargs(int argc, t_atom *argv);
|
||||||
|
EXTERN void canvas_getargs(int *argcp, t_atom **argvp);
|
||||||
|
EXTERN t_symbol *canvas_getcurrentdir(void);
|
||||||
|
EXTERN t_glist *canvas_getcurrent(void);
|
||||||
|
EXTERN void canvas_makefilename(t_glist *c, char *file,
|
||||||
|
char *result,int resultsize);
|
||||||
|
EXTERN t_symbol *canvas_getdir(t_glist *x);
|
||||||
|
EXTERN char sys_font[]; /* default typeface set in s_main.c */
|
||||||
|
EXTERN char sys_fontweight[]; /* default font weight set in s_main.c */
|
||||||
|
EXTERN int sys_fontwidth(int fontsize);
|
||||||
|
EXTERN int sys_fontheight(int fontsize);
|
||||||
|
EXTERN void canvas_dataproperties(t_glist *x, t_scalar *sc, t_binbuf *b);
|
||||||
|
EXTERN int canvas_open(t_canvas *x, const char *name, const char *ext,
|
||||||
|
char *dirresult, char **nameresult, unsigned int size, int bin);
|
||||||
|
|
||||||
|
/* ---------------- widget behaviors ---------------------- */
|
||||||
|
|
||||||
|
EXTERN_STRUCT _widgetbehavior;
|
||||||
|
#define t_widgetbehavior struct _widgetbehavior
|
||||||
|
|
||||||
|
EXTERN_STRUCT _parentwidgetbehavior;
|
||||||
|
#define t_parentwidgetbehavior struct _parentwidgetbehavior
|
||||||
|
EXTERN t_parentwidgetbehavior *pd_getparentwidget(t_pd *x);
|
||||||
|
|
||||||
|
/* -------------------- classes -------------- */
|
||||||
|
|
||||||
|
#define CLASS_DEFAULT 0 /* flags for new classes below */
|
||||||
|
#define CLASS_PD 1
|
||||||
|
#define CLASS_GOBJ 2
|
||||||
|
#define CLASS_PATCHABLE 3
|
||||||
|
#define CLASS_NOINLET 8
|
||||||
|
|
||||||
|
#define CLASS_TYPEMASK 3
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN t_class *class_new(t_symbol *name, t_newmethod newmethod,
|
||||||
|
t_method freemethod, size_t size, int flags, t_atomtype arg1, ...);
|
||||||
|
EXTERN void class_addcreator(t_newmethod newmethod, t_symbol *s,
|
||||||
|
t_atomtype type1, ...);
|
||||||
|
EXTERN void class_addmethod(t_class *c, t_method fn, t_symbol *sel,
|
||||||
|
t_atomtype arg1, ...);
|
||||||
|
EXTERN void class_addbang(t_class *c, t_method fn);
|
||||||
|
EXTERN void class_addpointer(t_class *c, t_method fn);
|
||||||
|
EXTERN void class_doaddfloat(t_class *c, t_method fn);
|
||||||
|
EXTERN void class_addsymbol(t_class *c, t_method fn);
|
||||||
|
EXTERN void class_addlist(t_class *c, t_method fn);
|
||||||
|
EXTERN void class_addanything(t_class *c, t_method fn);
|
||||||
|
EXTERN void class_sethelpsymbol(t_class *c, t_symbol *s);
|
||||||
|
EXTERN void class_setwidget(t_class *c, t_widgetbehavior *w);
|
||||||
|
EXTERN void class_setparentwidget(t_class *c, t_parentwidgetbehavior *w);
|
||||||
|
EXTERN t_parentwidgetbehavior *class_parentwidget(t_class *c);
|
||||||
|
EXTERN char *class_getname(t_class *c);
|
||||||
|
EXTERN char *class_gethelpname(t_class *c);
|
||||||
|
EXTERN void class_setdrawcommand(t_class *c);
|
||||||
|
EXTERN int class_isdrawcommand(t_class *c);
|
||||||
|
EXTERN void class_domainsignalin(t_class *c, int onset);
|
||||||
|
EXTERN void class_set_extern_dir(t_symbol *s);
|
||||||
|
#define CLASS_MAINSIGNALIN(c, type, field) \
|
||||||
|
class_domainsignalin(c, (char *)(&((type *)0)->field) - (char *)0)
|
||||||
|
|
||||||
|
/* prototype for functions to save Pd's to a binbuf */
|
||||||
|
typedef void (*t_savefn)(t_gobj *x, t_binbuf *b);
|
||||||
|
EXTERN void class_setsavefn(t_class *c, t_savefn f);
|
||||||
|
EXTERN t_savefn class_getsavefn(t_class *c);
|
||||||
|
/* prototype for functions to open properties dialogs */
|
||||||
|
typedef void (*t_propertiesfn)(t_gobj *x, struct _glist *glist);
|
||||||
|
EXTERN void class_setpropertiesfn(t_class *c, t_propertiesfn f);
|
||||||
|
EXTERN t_propertiesfn class_getpropertiesfn(t_class *c);
|
||||||
|
|
||||||
|
#ifndef PD_CLASS_DEF
|
||||||
|
#define class_addbang(x, y) class_addbang((x), (t_method)(y))
|
||||||
|
#define class_addpointer(x, y) class_addpointer((x), (t_method)(y))
|
||||||
|
#define class_addfloat(x, y) class_doaddfloat((x), (t_method)(y))
|
||||||
|
#define class_addsymbol(x, y) class_addsymbol((x), (t_method)(y))
|
||||||
|
#define class_addlist(x, y) class_addlist((x), (t_method)(y))
|
||||||
|
#define class_addanything(x, y) class_addanything((x), (t_method)(y))
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* ------------ printing --------------------------------- */
|
||||||
|
EXTERN void post(const char *fmt, ...);
|
||||||
|
EXTERN void startpost(const char *fmt, ...);
|
||||||
|
EXTERN void poststring(const char *s);
|
||||||
|
EXTERN void postfloat(t_floatarg f);
|
||||||
|
EXTERN void postatom(int argc, t_atom *argv);
|
||||||
|
EXTERN void endpost(void);
|
||||||
|
EXTERN void error(const char *fmt, ...);
|
||||||
|
EXTERN void verbose(int level, const char *fmt, ...);
|
||||||
|
EXTERN void bug(const char *fmt, ...);
|
||||||
|
EXTERN void pd_error(void *object, const char *fmt, ...);
|
||||||
|
EXTERN void sys_logerror(const char *object, const char *s);
|
||||||
|
EXTERN void sys_unixerror(const char *object);
|
||||||
|
EXTERN void sys_ouch(void);
|
||||||
|
|
||||||
|
|
||||||
|
/* ------------ system interface routines ------------------- */
|
||||||
|
EXTERN int sys_isreadablefile(const char *name);
|
||||||
|
EXTERN int sys_isabsolutepath(const char *dir);
|
||||||
|
EXTERN void sys_bashfilename(const char *from, char *to);
|
||||||
|
EXTERN void sys_unbashfilename(const char *from, char *to);
|
||||||
|
EXTERN int open_via_path(const char *name, const char *ext, const char *dir,
|
||||||
|
char *dirresult, char **nameresult, unsigned int size, int bin);
|
||||||
|
EXTERN int sched_geteventno(void);
|
||||||
|
EXTERN double sys_getrealtime(void);
|
||||||
|
EXTERN int (*sys_idlehook)(void); /* hook to add idle time computation */
|
||||||
|
|
||||||
|
|
||||||
|
/* ------------ threading ------------------- */
|
||||||
|
EXTERN void sys_lock(void);
|
||||||
|
EXTERN void sys_unlock(void);
|
||||||
|
EXTERN int sys_trylock(void);
|
||||||
|
|
||||||
|
|
||||||
|
/* --------------- signals ----------------------------------- */
|
||||||
|
|
||||||
|
typedef PD_FLOATTYPE t_sample;
|
||||||
|
#define MAXLOGSIG 32
|
||||||
|
#define MAXSIGSIZE (1 << MAXLOGSIG)
|
||||||
|
|
||||||
|
typedef struct _signal
|
||||||
|
{
|
||||||
|
int s_n; /* number of points in the array */
|
||||||
|
t_sample *s_vec; /* the array */
|
||||||
|
t_float s_sr; /* sample rate */
|
||||||
|
int s_refcount; /* number of times used */
|
||||||
|
int s_isborrowed; /* whether we're going to borrow our array */
|
||||||
|
struct _signal *s_borrowedfrom; /* signal to borrow it from */
|
||||||
|
struct _signal *s_nextfree; /* next in freelist */
|
||||||
|
struct _signal *s_nextused; /* next in used list */
|
||||||
|
int s_vecsize; /* allocated size of array in points */
|
||||||
|
} t_signal;
|
||||||
|
|
||||||
|
typedef t_int *(*t_perfroutine)(t_int *args);
|
||||||
|
|
||||||
|
EXTERN t_int *plus_perform(t_int *args);
|
||||||
|
EXTERN t_int *zero_perform(t_int *args);
|
||||||
|
EXTERN t_int *copy_perform(t_int *args);
|
||||||
|
|
||||||
|
EXTERN void dsp_add_plus(t_sample *in1, t_sample *in2, t_sample *out, int n);
|
||||||
|
EXTERN void dsp_add_copy(t_sample *in, t_sample *out, int n);
|
||||||
|
EXTERN void dsp_add_scalarcopy(t_float *in, t_sample *out, int n);
|
||||||
|
EXTERN void dsp_add_zero(t_sample *out, int n);
|
||||||
|
|
||||||
|
EXTERN int sys_getblksize(void);
|
||||||
|
EXTERN t_float sys_getsr(void);
|
||||||
|
EXTERN int sys_get_inchannels(void);
|
||||||
|
EXTERN int sys_get_outchannels(void);
|
||||||
|
|
||||||
|
EXTERN void dsp_add(t_perfroutine f, int n, ...);
|
||||||
|
EXTERN void dsp_addv(t_perfroutine f, int n, t_int *vec);
|
||||||
|
EXTERN void pd_fft(t_float *buf, int npoints, int inverse);
|
||||||
|
EXTERN int ilog2(int n);
|
||||||
|
|
||||||
|
EXTERN void mayer_fht(t_sample *fz, int n);
|
||||||
|
EXTERN void mayer_fft(int n, t_sample *real, t_sample *imag);
|
||||||
|
EXTERN void mayer_ifft(int n, t_sample *real, t_sample *imag);
|
||||||
|
EXTERN void mayer_realfft(int n, t_sample *real);
|
||||||
|
EXTERN void mayer_realifft(int n, t_sample *real);
|
||||||
|
|
||||||
|
EXTERN float *cos_table;
|
||||||
|
#define LOGCOSTABSIZE 9
|
||||||
|
#define COSTABSIZE (1<<LOGCOSTABSIZE)
|
||||||
|
|
||||||
|
EXTERN int canvas_suspend_dsp(void);
|
||||||
|
EXTERN void canvas_resume_dsp(int oldstate);
|
||||||
|
EXTERN void canvas_update_dsp(void);
|
||||||
|
EXTERN int canvas_dspstate;
|
||||||
|
|
||||||
|
/* up/downsampling */
|
||||||
|
typedef struct _resample
|
||||||
|
{
|
||||||
|
int method; /* up/downsampling method ID */
|
||||||
|
|
||||||
|
t_int downsample; /* downsampling factor */
|
||||||
|
t_int upsample; /* upsampling factor */
|
||||||
|
|
||||||
|
t_sample *s_vec; /* here we hold the resampled data */
|
||||||
|
int s_n;
|
||||||
|
|
||||||
|
t_sample *coeffs; /* coefficients for filtering... */
|
||||||
|
int coefsize;
|
||||||
|
|
||||||
|
t_sample *buffer; /* buffer for filtering */
|
||||||
|
int bufsize;
|
||||||
|
} t_resample;
|
||||||
|
|
||||||
|
EXTERN void resample_init(t_resample *x);
|
||||||
|
EXTERN void resample_free(t_resample *x);
|
||||||
|
|
||||||
|
EXTERN void resample_dsp(t_resample *x, t_sample *in, int insize, t_sample *out, int outsize, int method);
|
||||||
|
EXTERN void resamplefrom_dsp(t_resample *x, t_sample *in, int insize, int outsize, int method);
|
||||||
|
EXTERN void resampleto_dsp(t_resample *x, t_sample *out, int insize, int outsize, int method);
|
||||||
|
|
||||||
|
/* ----------------------- utility functions for signals -------------- */
|
||||||
|
EXTERN t_float mtof(t_float);
|
||||||
|
EXTERN t_float ftom(t_float);
|
||||||
|
EXTERN t_float rmstodb(t_float);
|
||||||
|
EXTERN t_float powtodb(t_float);
|
||||||
|
EXTERN t_float dbtorms(t_float);
|
||||||
|
EXTERN t_float dbtopow(t_float);
|
||||||
|
|
||||||
|
EXTERN t_float q8_sqrt(t_float);
|
||||||
|
EXTERN t_float q8_rsqrt(t_float);
|
||||||
|
#ifndef N32
|
||||||
|
EXTERN t_float qsqrt(t_float); /* old names kept for extern compatibility */
|
||||||
|
EXTERN t_float qrsqrt(t_float);
|
||||||
|
#endif
|
||||||
|
/* --------------------- data --------------------------------- */
|
||||||
|
|
||||||
|
/* graphical arrays */
|
||||||
|
EXTERN_STRUCT _garray;
|
||||||
|
#define t_garray struct _garray
|
||||||
|
|
||||||
|
EXTERN t_class *garray_class;
|
||||||
|
EXTERN int garray_getfloatarray(t_garray *x, int *size, t_float **vec);
|
||||||
|
EXTERN int garray_getfloatwords(t_garray *x, int *size, t_word **vec);
|
||||||
|
EXTERN t_float garray_get(t_garray *x, t_symbol *s, t_int indx);
|
||||||
|
EXTERN void garray_redraw(t_garray *x);
|
||||||
|
EXTERN int garray_npoints(t_garray *x);
|
||||||
|
EXTERN char *garray_vec(t_garray *x);
|
||||||
|
EXTERN void garray_resize(t_garray *x, t_floatarg f);
|
||||||
|
EXTERN void garray_usedindsp(t_garray *x);
|
||||||
|
EXTERN void garray_setsaveit(t_garray *x, int saveit);
|
||||||
|
EXTERN t_class *scalar_class;
|
||||||
|
|
||||||
|
EXTERN t_float *value_get(t_symbol *s);
|
||||||
|
EXTERN void value_release(t_symbol *s);
|
||||||
|
EXTERN int value_getfloat(t_symbol *s, t_float *f);
|
||||||
|
EXTERN int value_setfloat(t_symbol *s, t_float f);
|
||||||
|
|
||||||
|
/* ------- GUI interface - functions to send strings to TK --------- */
|
||||||
|
typedef void (*t_guicallbackfn)(t_gobj *client, t_glist *glist);
|
||||||
|
|
||||||
|
EXTERN void sys_vgui(char *fmt, ...);
|
||||||
|
EXTERN void sys_gui(char *s);
|
||||||
|
EXTERN void sys_pretendguibytes(int n);
|
||||||
|
EXTERN void sys_queuegui(void *client, t_glist *glist, t_guicallbackfn f);
|
||||||
|
EXTERN void sys_unqueuegui(void *client);
|
||||||
|
/* dialog window creation and destruction */
|
||||||
|
EXTERN void gfxstub_new(t_pd *owner, void *key, const char *cmd);
|
||||||
|
EXTERN void gfxstub_deleteforkey(void *key);
|
||||||
|
|
||||||
|
extern t_class *glob_pdobject; /* object to send "pd" messages */
|
||||||
|
|
||||||
|
/*------------- Max 0.26 compatibility --------------------*/
|
||||||
|
|
||||||
|
/* the following reflects the new way classes are laid out, with the class
|
||||||
|
pointing to the messlist and not vice versa. Externs shouldn't feel it. */
|
||||||
|
typedef t_class *t_externclass;
|
||||||
|
|
||||||
|
EXTERN void c_extern(t_externclass *cls, t_newmethod newroutine,
|
||||||
|
t_method freeroutine, t_symbol *name, size_t size, int tiny, \
|
||||||
|
t_atomtype arg1, ...);
|
||||||
|
EXTERN void c_addmess(t_method fn, t_symbol *sel, t_atomtype arg1, ...);
|
||||||
|
|
||||||
|
#define t_getbytes getbytes
|
||||||
|
#define t_freebytes freebytes
|
||||||
|
#define t_resizebytes resizebytes
|
||||||
|
#define typedmess pd_typedmess
|
||||||
|
#define vmess pd_vmess
|
||||||
|
|
||||||
|
/* A definition to help gui objects straddle 0.34-0.35 changes. If this is
|
||||||
|
defined, there is a "te_xpix" field in objects, not a "te_xpos" as before: */
|
||||||
|
|
||||||
|
#define PD_USE_TE_XPIX
|
||||||
|
|
||||||
|
#if defined(__i386__) || defined(__x86_64__)
|
||||||
|
/* a test for NANs and denormals. Should only be necessary on i386. */
|
||||||
|
#define PD_BADFLOAT(f) ((((*(unsigned int*)&(f))&0x7f800000)==0) || \
|
||||||
|
(((*(unsigned int*)&(f))&0x7f800000)==0x7f800000))
|
||||||
|
/* more stringent test: anything not between 1e-19 and 1e19 in absolute val */
|
||||||
|
#define PD_BIGORSMALL(f) ((((*(unsigned int*)&(f))&0x60000000)==0) || \
|
||||||
|
(((*(unsigned int*)&(f))&0x60000000)==0x60000000))
|
||||||
|
#else
|
||||||
|
#define PD_BADFLOAT(f) 0
|
||||||
|
#define PD_BIGORSMALL(f) 0
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* get version number at run time */
|
||||||
|
EXTERN void sys_getversion(int *major, int *minor, int *bugfix);
|
||||||
|
|
||||||
|
#if defined(_LANGUAGE_C_PLUS_PLUS) || defined(__cplusplus)
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#define __m_pd_h_
|
||||||
|
#endif /* __m_pd_h_ */
|
38
externals/artnetin/manual/manual.txt
vendored
Executable file
38
externals/artnetin/manual/manual.txt
vendored
Executable file
|
@ -0,0 +1,38 @@
|
||||||
|
******************************
|
||||||
|
Artnetin 0.0.3
|
||||||
|
Santiago Noreña
|
||||||
|
puremediaserver@gmail.com
|
||||||
|
******************************
|
||||||
|
|
||||||
|
Artnetin es un objeto de Pure Data que permite leer un universo entero de ArtNet y tratarlo como entrada de datos de Pure Data.
|
||||||
|
|
||||||
|
*****************************
|
||||||
|
Instalación:
|
||||||
|
|
||||||
|
Artnetin depende de la biblioteca libartnet del proyecto OLA, por lo que antes de compilar el objeto deberías instalar libartnet. Para instalar libartnet:
|
||||||
|
wget http://linux-lighting.googlecode.com/files/libartnet-1.1.0.tar.gz
|
||||||
|
tar -zxf libartnet-1.1.0.tar.gz
|
||||||
|
cd libartnet-1.1.0
|
||||||
|
./configure
|
||||||
|
make
|
||||||
|
sudo make install
|
||||||
|
|
||||||
|
Para compilar artnetin:
|
||||||
|
make
|
||||||
|
|
||||||
|
Ahora deberías copiar el archivo artnetin.pd_linux en una carpeta que esté dentro de las rutas de Pure Data o en la carpeta del patch que uses.
|
||||||
|
*****************************
|
||||||
|
Uso:
|
||||||
|
|
||||||
|
- El objeto escucha en el interface activo con la IP más baja, típicamente 2.x.x.x.
|
||||||
|
|
||||||
|
- Están disponibles los 512 canales; El objeto saca una lista de 512 enteros con el universo entero.
|
||||||
|
|
||||||
|
- Antes de que el objeto empiece a sacar valores hay que crear el nodo. Para ello hay que mandar un mensaje [open "nº subnet" "nº universo"]. Si sólo le pasamos open, escuchará en la subnet 0, universo 0. Si queremos cambiar el universo de escucha hay que mandar un mensaje [close]. Después se puede volver a mandar un nuevo mensaje open con la nueva configuración.
|
||||||
|
|
||||||
|
*****************************
|
||||||
|
Ayuda y soporte:
|
||||||
|
|
||||||
|
puremediaserver@googlegroups.com
|
||||||
|
*****************************
|
||||||
|
|
676
externals/ola2pd/LICENSE.txt
vendored
Executable file
676
externals/ola2pd/LICENSE.txt
vendored
Executable file
|
@ -0,0 +1,676 @@
|
||||||
|
|
||||||
|
GNU GENERAL PUBLIC LICENSE
|
||||||
|
Version 3, 29 June 2007
|
||||||
|
|
||||||
|
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||||
|
Everyone is permitted to copy and distribute verbatim copies
|
||||||
|
of this license document, but changing it is not allowed.
|
||||||
|
|
||||||
|
Preamble
|
||||||
|
|
||||||
|
The GNU General Public License is a free, copyleft license for
|
||||||
|
software and other kinds of works.
|
||||||
|
|
||||||
|
The licenses for most software and other practical works are designed
|
||||||
|
to take away your freedom to share and change the works. By contrast,
|
||||||
|
the GNU General Public License is intended to guarantee your freedom to
|
||||||
|
share and change all versions of a program--to make sure it remains free
|
||||||
|
software for all its users. We, the Free Software Foundation, use the
|
||||||
|
GNU General Public License for most of our software; it applies also to
|
||||||
|
any other work released this way by its authors. You can apply it to
|
||||||
|
your programs, too.
|
||||||
|
|
||||||
|
When we speak of free software, we are referring to freedom, not
|
||||||
|
price. Our General Public Licenses are designed to make sure that you
|
||||||
|
have the freedom to distribute copies of free software (and charge for
|
||||||
|
them if you wish), that you receive source code or can get it if you
|
||||||
|
want it, that you can change the software or use pieces of it in new
|
||||||
|
free programs, and that you know you can do these things.
|
||||||
|
|
||||||
|
To protect your rights, we need to prevent others from denying you
|
||||||
|
these rights or asking you to surrender the rights. Therefore, you have
|
||||||
|
certain responsibilities if you distribute copies of the software, or if
|
||||||
|
you modify it: responsibilities to respect the freedom of others.
|
||||||
|
|
||||||
|
For example, if you distribute copies of such a program, whether
|
||||||
|
gratis or for a fee, you must pass on to the recipients the same
|
||||||
|
freedoms that you received. You must make sure that they, too, receive
|
||||||
|
or can get the source code. And you must show them these terms so they
|
||||||
|
know their rights.
|
||||||
|
|
||||||
|
Developers that use the GNU GPL protect your rights with two steps:
|
||||||
|
(1) assert copyright on the software, and (2) offer you this License
|
||||||
|
giving you legal permission to copy, distribute and/or modify it.
|
||||||
|
|
||||||
|
For the developers' and authors' protection, the GPL clearly explains
|
||||||
|
that there is no warranty for this free software. For both users' and
|
||||||
|
authors' sake, the GPL requires that modified versions be marked as
|
||||||
|
changed, so that their problems will not be attributed erroneously to
|
||||||
|
authors of previous versions.
|
||||||
|
|
||||||
|
Some devices are designed to deny users access to install or run
|
||||||
|
modified versions of the software inside them, although the manufacturer
|
||||||
|
can do so. This is fundamentally incompatible with the aim of
|
||||||
|
protecting users' freedom to change the software. The systematic
|
||||||
|
pattern of such abuse occurs in the area of products for individuals to
|
||||||
|
use, which is precisely where it is most unacceptable. Therefore, we
|
||||||
|
have designed this version of the GPL to prohibit the practice for those
|
||||||
|
products. If such problems arise substantially in other domains, we
|
||||||
|
stand ready to extend this provision to those domains in future versions
|
||||||
|
of the GPL, as needed to protect the freedom of users.
|
||||||
|
|
||||||
|
Finally, every program is threatened constantly by software patents.
|
||||||
|
States should not allow patents to restrict development and use of
|
||||||
|
software on general-purpose computers, but in those that do, we wish to
|
||||||
|
avoid the special danger that patents applied to a free program could
|
||||||
|
make it effectively proprietary. To prevent this, the GPL assures that
|
||||||
|
patents cannot be used to render the program non-free.
|
||||||
|
|
||||||
|
The precise terms and conditions for copying, distribution and
|
||||||
|
modification follow.
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
0. Definitions.
|
||||||
|
|
||||||
|
"This License" refers to version 3 of the GNU General Public License.
|
||||||
|
|
||||||
|
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||||
|
works, such as semiconductor masks.
|
||||||
|
|
||||||
|
"The Program" refers to any copyrightable work licensed under this
|
||||||
|
License. Each licensee is addressed as "you". "Licensees" and
|
||||||
|
"recipients" may be individuals or organizations.
|
||||||
|
|
||||||
|
To "modify" a work means to copy from or adapt all or part of the work
|
||||||
|
in a fashion requiring copyright permission, other than the making of an
|
||||||
|
exact copy. The resulting work is called a "modified version" of the
|
||||||
|
earlier work or a work "based on" the earlier work.
|
||||||
|
|
||||||
|
A "covered work" means either the unmodified Program or a work based
|
||||||
|
on the Program.
|
||||||
|
|
||||||
|
To "propagate" a work means to do anything with it that, without
|
||||||
|
permission, would make you directly or secondarily liable for
|
||||||
|
infringement under applicable copyright law, except executing it on a
|
||||||
|
computer or modifying a private copy. Propagation includes copying,
|
||||||
|
distribution (with or without modification), making available to the
|
||||||
|
public, and in some countries other activities as well.
|
||||||
|
|
||||||
|
To "convey" a work means any kind of propagation that enables other
|
||||||
|
parties to make or receive copies. Mere interaction with a user through
|
||||||
|
a computer network, with no transfer of a copy, is not conveying.
|
||||||
|
|
||||||
|
An interactive user interface displays "Appropriate Legal Notices"
|
||||||
|
to the extent that it includes a convenient and prominently visible
|
||||||
|
feature that (1) displays an appropriate copyright notice, and (2)
|
||||||
|
tells the user that there is no warranty for the work (except to the
|
||||||
|
extent that warranties are provided), that licensees may convey the
|
||||||
|
work under this License, and how to view a copy of this License. If
|
||||||
|
the interface presents a list of user commands or options, such as a
|
||||||
|
menu, a prominent item in the list meets this criterion.
|
||||||
|
|
||||||
|
1. Source Code.
|
||||||
|
|
||||||
|
The "source code" for a work means the preferred form of the work
|
||||||
|
for making modifications to it. "Object code" means any non-source
|
||||||
|
form of a work.
|
||||||
|
|
||||||
|
A "Standard Interface" means an interface that either is an official
|
||||||
|
standard defined by a recognized standards body, or, in the case of
|
||||||
|
interfaces specified for a particular programming language, one that
|
||||||
|
is widely used among developers working in that language.
|
||||||
|
|
||||||
|
The "System Libraries" of an executable work include anything, other
|
||||||
|
than the work as a whole, that (a) is included in the normal form of
|
||||||
|
packaging a Major Component, but which is not part of that Major
|
||||||
|
Component, and (b) serves only to enable use of the work with that
|
||||||
|
Major Component, or to implement a Standard Interface for which an
|
||||||
|
implementation is available to the public in source code form. A
|
||||||
|
"Major Component", in this context, means a major essential component
|
||||||
|
(kernel, window system, and so on) of the specific operating system
|
||||||
|
(if any) on which the executable work runs, or a compiler used to
|
||||||
|
produce the work, or an object code interpreter used to run it.
|
||||||
|
|
||||||
|
The "Corresponding Source" for a work in object code form means all
|
||||||
|
the source code needed to generate, install, and (for an executable
|
||||||
|
work) run the object code and to modify the work, including scripts to
|
||||||
|
control those activities. However, it does not include the work's
|
||||||
|
System Libraries, or general-purpose tools or generally available free
|
||||||
|
programs which are used unmodified in performing those activities but
|
||||||
|
which are not part of the work. For example, Corresponding Source
|
||||||
|
includes interface definition files associated with source files for
|
||||||
|
the work, and the source code for shared libraries and dynamically
|
||||||
|
linked subprograms that the work is specifically designed to require,
|
||||||
|
such as by intimate data communication or control flow between those
|
||||||
|
subprograms and other parts of the work.
|
||||||
|
|
||||||
|
The Corresponding Source need not include anything that users
|
||||||
|
can regenerate automatically from other parts of the Corresponding
|
||||||
|
Source.
|
||||||
|
|
||||||
|
The Corresponding Source for a work in source code form is that
|
||||||
|
same work.
|
||||||
|
|
||||||
|
2. Basic Permissions.
|
||||||
|
|
||||||
|
All rights granted under this License are granted for the term of
|
||||||
|
copyright on the Program, and are irrevocable provided the stated
|
||||||
|
conditions are met. This License explicitly affirms your unlimited
|
||||||
|
permission to run the unmodified Program. The output from running a
|
||||||
|
covered work is covered by this License only if the output, given its
|
||||||
|
content, constitutes a covered work. This License acknowledges your
|
||||||
|
rights of fair use or other equivalent, as provided by copyright law.
|
||||||
|
|
||||||
|
You may make, run and propagate covered works that you do not
|
||||||
|
convey, without conditions so long as your license otherwise remains
|
||||||
|
in force. You may convey covered works to others for the sole purpose
|
||||||
|
of having them make modifications exclusively for you, or provide you
|
||||||
|
with facilities for running those works, provided that you comply with
|
||||||
|
the terms of this License in conveying all material for which you do
|
||||||
|
not control copyright. Those thus making or running the covered works
|
||||||
|
for you must do so exclusively on your behalf, under your direction
|
||||||
|
and control, on terms that prohibit them from making any copies of
|
||||||
|
your copyrighted material outside their relationship with you.
|
||||||
|
|
||||||
|
Conveying under any other circumstances is permitted solely under
|
||||||
|
the conditions stated below. Sublicensing is not allowed; section 10
|
||||||
|
makes it unnecessary.
|
||||||
|
|
||||||
|
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||||
|
|
||||||
|
No covered work shall be deemed part of an effective technological
|
||||||
|
measure under any applicable law fulfilling obligations under article
|
||||||
|
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||||
|
similar laws prohibiting or restricting circumvention of such
|
||||||
|
measures.
|
||||||
|
|
||||||
|
When you convey a covered work, you waive any legal power to forbid
|
||||||
|
circumvention of technological measures to the extent such circumvention
|
||||||
|
is effected by exercising rights under this License with respect to
|
||||||
|
the covered work, and you disclaim any intention to limit operation or
|
||||||
|
modification of the work as a means of enforcing, against the work's
|
||||||
|
users, your or third parties' legal rights to forbid circumvention of
|
||||||
|
technological measures.
|
||||||
|
|
||||||
|
4. Conveying Verbatim Copies.
|
||||||
|
|
||||||
|
You may convey verbatim copies of the Program's source code as you
|
||||||
|
receive it, in any medium, provided that you conspicuously and
|
||||||
|
appropriately publish on each copy an appropriate copyright notice;
|
||||||
|
keep intact all notices stating that this License and any
|
||||||
|
non-permissive terms added in accord with section 7 apply to the code;
|
||||||
|
keep intact all notices of the absence of any warranty; and give all
|
||||||
|
recipients a copy of this License along with the Program.
|
||||||
|
|
||||||
|
You may charge any price or no price for each copy that you convey,
|
||||||
|
and you may offer support or warranty protection for a fee.
|
||||||
|
|
||||||
|
5. Conveying Modified Source Versions.
|
||||||
|
|
||||||
|
You may convey a work based on the Program, or the modifications to
|
||||||
|
produce it from the Program, in the form of source code under the
|
||||||
|
terms of section 4, provided that you also meet all of these conditions:
|
||||||
|
|
||||||
|
a) The work must carry prominent notices stating that you modified
|
||||||
|
it, and giving a relevant date.
|
||||||
|
|
||||||
|
b) The work must carry prominent notices stating that it is
|
||||||
|
released under this License and any conditions added under section
|
||||||
|
7. This requirement modifies the requirement in section 4 to
|
||||||
|
"keep intact all notices".
|
||||||
|
|
||||||
|
c) You must license the entire work, as a whole, under this
|
||||||
|
License to anyone who comes into possession of a copy. This
|
||||||
|
License will therefore apply, along with any applicable section 7
|
||||||
|
additional terms, to the whole of the work, and all its parts,
|
||||||
|
regardless of how they are packaged. This License gives no
|
||||||
|
permission to license the work in any other way, but it does not
|
||||||
|
invalidate such permission if you have separately received it.
|
||||||
|
|
||||||
|
d) If the work has interactive user interfaces, each must display
|
||||||
|
Appropriate Legal Notices; however, if the Program has interactive
|
||||||
|
interfaces that do not display Appropriate Legal Notices, your
|
||||||
|
work need not make them do so.
|
||||||
|
|
||||||
|
A compilation of a covered work with other separate and independent
|
||||||
|
works, which are not by their nature extensions of the covered work,
|
||||||
|
and which are not combined with it such as to form a larger program,
|
||||||
|
in or on a volume of a storage or distribution medium, is called an
|
||||||
|
"aggregate" if the compilation and its resulting copyright are not
|
||||||
|
used to limit the access or legal rights of the compilation's users
|
||||||
|
beyond what the individual works permit. Inclusion of a covered work
|
||||||
|
in an aggregate does not cause this License to apply to the other
|
||||||
|
parts of the aggregate.
|
||||||
|
|
||||||
|
6. Conveying Non-Source Forms.
|
||||||
|
|
||||||
|
You may convey a covered work in object code form under the terms
|
||||||
|
of sections 4 and 5, provided that you also convey the
|
||||||
|
machine-readable Corresponding Source under the terms of this License,
|
||||||
|
in one of these ways:
|
||||||
|
|
||||||
|
a) Convey the object code in, or embodied in, a physical product
|
||||||
|
(including a physical distribution medium), accompanied by the
|
||||||
|
Corresponding Source fixed on a durable physical medium
|
||||||
|
customarily used for software interchange.
|
||||||
|
|
||||||
|
b) Convey the object code in, or embodied in, a physical product
|
||||||
|
(including a physical distribution medium), accompanied by a
|
||||||
|
written offer, valid for at least three years and valid for as
|
||||||
|
long as you offer spare parts or customer support for that product
|
||||||
|
model, to give anyone who possesses the object code either (1) a
|
||||||
|
copy of the Corresponding Source for all the software in the
|
||||||
|
product that is covered by this License, on a durable physical
|
||||||
|
medium customarily used for software interchange, for a price no
|
||||||
|
more than your reasonable cost of physically performing this
|
||||||
|
conveying of source, or (2) access to copy the
|
||||||
|
Corresponding Source from a network server at no charge.
|
||||||
|
|
||||||
|
c) Convey individual copies of the object code with a copy of the
|
||||||
|
written offer to provide the Corresponding Source. This
|
||||||
|
alternative is allowed only occasionally and noncommercially, and
|
||||||
|
only if you received the object code with such an offer, in accord
|
||||||
|
with subsection 6b.
|
||||||
|
|
||||||
|
d) Convey the object code by offering access from a designated
|
||||||
|
place (gratis or for a charge), and offer equivalent access to the
|
||||||
|
Corresponding Source in the same way through the same place at no
|
||||||
|
further charge. You need not require recipients to copy the
|
||||||
|
Corresponding Source along with the object code. If the place to
|
||||||
|
copy the object code is a network server, the Corresponding Source
|
||||||
|
may be on a different server (operated by you or a third party)
|
||||||
|
that supports equivalent copying facilities, provided you maintain
|
||||||
|
clear directions next to the object code saying where to find the
|
||||||
|
Corresponding Source. Regardless of what server hosts the
|
||||||
|
Corresponding Source, you remain obligated to ensure that it is
|
||||||
|
available for as long as needed to satisfy these requirements.
|
||||||
|
|
||||||
|
e) Convey the object code using peer-to-peer transmission, provided
|
||||||
|
you inform other peers where the object code and Corresponding
|
||||||
|
Source of the work are being offered to the general public at no
|
||||||
|
charge under subsection 6d.
|
||||||
|
|
||||||
|
A separable portion of the object code, whose source code is excluded
|
||||||
|
from the Corresponding Source as a System Library, need not be
|
||||||
|
included in conveying the object code work.
|
||||||
|
|
||||||
|
A "User Product" is either (1) a "consumer product", which means any
|
||||||
|
tangible personal property which is normally used for personal, family,
|
||||||
|
or household purposes, or (2) anything designed or sold for incorporation
|
||||||
|
into a dwelling. In determining whether a product is a consumer product,
|
||||||
|
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||||
|
product received by a particular user, "normally used" refers to a
|
||||||
|
typical or common use of that class of product, regardless of the status
|
||||||
|
of the particular user or of the way in which the particular user
|
||||||
|
actually uses, or expects or is expected to use, the product. A product
|
||||||
|
is a consumer product regardless of whether the product has substantial
|
||||||
|
commercial, industrial or non-consumer uses, unless such uses represent
|
||||||
|
the only significant mode of use of the product.
|
||||||
|
|
||||||
|
"Installation Information" for a User Product means any methods,
|
||||||
|
procedures, authorization keys, or other information required to install
|
||||||
|
and execute modified versions of a covered work in that User Product from
|
||||||
|
a modified version of its Corresponding Source. The information must
|
||||||
|
suffice to ensure that the continued functioning of the modified object
|
||||||
|
code is in no case prevented or interfered with solely because
|
||||||
|
modification has been made.
|
||||||
|
|
||||||
|
If you convey an object code work under this section in, or with, or
|
||||||
|
specifically for use in, a User Product, and the conveying occurs as
|
||||||
|
part of a transaction in which the right of possession and use of the
|
||||||
|
User Product is transferred to the recipient in perpetuity or for a
|
||||||
|
fixed term (regardless of how the transaction is characterized), the
|
||||||
|
Corresponding Source conveyed under this section must be accompanied
|
||||||
|
by the Installation Information. But this requirement does not apply
|
||||||
|
if neither you nor any third party retains the ability to install
|
||||||
|
modified object code on the User Product (for example, the work has
|
||||||
|
been installed in ROM).
|
||||||
|
|
||||||
|
The requirement to provide Installation Information does not include a
|
||||||
|
requirement to continue to provide support service, warranty, or updates
|
||||||
|
for a work that has been modified or installed by the recipient, or for
|
||||||
|
the User Product in which it has been modified or installed. Access to a
|
||||||
|
network may be denied when the modification itself materially and
|
||||||
|
adversely affects the operation of the network or violates the rules and
|
||||||
|
protocols for communication across the network.
|
||||||
|
|
||||||
|
Corresponding Source conveyed, and Installation Information provided,
|
||||||
|
in accord with this section must be in a format that is publicly
|
||||||
|
documented (and with an implementation available to the public in
|
||||||
|
source code form), and must require no special password or key for
|
||||||
|
unpacking, reading or copying.
|
||||||
|
|
||||||
|
7. Additional Terms.
|
||||||
|
|
||||||
|
"Additional permissions" are terms that supplement the terms of this
|
||||||
|
License by making exceptions from one or more of its conditions.
|
||||||
|
Additional permissions that are applicable to the entire Program shall
|
||||||
|
be treated as though they were included in this License, to the extent
|
||||||
|
that they are valid under applicable law. If additional permissions
|
||||||
|
apply only to part of the Program, that part may be used separately
|
||||||
|
under those permissions, but the entire Program remains governed by
|
||||||
|
this License without regard to the additional permissions.
|
||||||
|
|
||||||
|
When you convey a copy of a covered work, you may at your option
|
||||||
|
remove any additional permissions from that copy, or from any part of
|
||||||
|
it. (Additional permissions may be written to require their own
|
||||||
|
removal in certain cases when you modify the work.) You may place
|
||||||
|
additional permissions on material, added by you to a covered work,
|
||||||
|
for which you have or can give appropriate copyright permission.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, for material you
|
||||||
|
add to a covered work, you may (if authorized by the copyright holders of
|
||||||
|
that material) supplement the terms of this License with terms:
|
||||||
|
|
||||||
|
a) Disclaiming warranty or limiting liability differently from the
|
||||||
|
terms of sections 15 and 16 of this License; or
|
||||||
|
|
||||||
|
b) Requiring preservation of specified reasonable legal notices or
|
||||||
|
author attributions in that material or in the Appropriate Legal
|
||||||
|
Notices displayed by works containing it; or
|
||||||
|
|
||||||
|
c) Prohibiting misrepresentation of the origin of that material, or
|
||||||
|
requiring that modified versions of such material be marked in
|
||||||
|
reasonable ways as different from the original version; or
|
||||||
|
|
||||||
|
d) Limiting the use for publicity purposes of names of licensors or
|
||||||
|
authors of the material; or
|
||||||
|
|
||||||
|
e) Declining to grant rights under trademark law for use of some
|
||||||
|
trade names, trademarks, or service marks; or
|
||||||
|
|
||||||
|
f) Requiring indemnification of licensors and authors of that
|
||||||
|
material by anyone who conveys the material (or modified versions of
|
||||||
|
it) with contractual assumptions of liability to the recipient, for
|
||||||
|
any liability that these contractual assumptions directly impose on
|
||||||
|
those licensors and authors.
|
||||||
|
|
||||||
|
All other non-permissive additional terms are considered "further
|
||||||
|
restrictions" within the meaning of section 10. If the Program as you
|
||||||
|
received it, or any part of it, contains a notice stating that it is
|
||||||
|
governed by this License along with a term that is a further
|
||||||
|
restriction, you may remove that term. If a license document contains
|
||||||
|
a further restriction but permits relicensing or conveying under this
|
||||||
|
License, you may add to a covered work material governed by the terms
|
||||||
|
of that license document, provided that the further restriction does
|
||||||
|
not survive such relicensing or conveying.
|
||||||
|
|
||||||
|
If you add terms to a covered work in accord with this section, you
|
||||||
|
must place, in the relevant source files, a statement of the
|
||||||
|
additional terms that apply to those files, or a notice indicating
|
||||||
|
where to find the applicable terms.
|
||||||
|
|
||||||
|
Additional terms, permissive or non-permissive, may be stated in the
|
||||||
|
form of a separately written license, or stated as exceptions;
|
||||||
|
the above requirements apply either way.
|
||||||
|
|
||||||
|
8. Termination.
|
||||||
|
|
||||||
|
You may not propagate or modify a covered work except as expressly
|
||||||
|
provided under this License. Any attempt otherwise to propagate or
|
||||||
|
modify it is void, and will automatically terminate your rights under
|
||||||
|
this License (including any patent licenses granted under the third
|
||||||
|
paragraph of section 11).
|
||||||
|
|
||||||
|
However, if you cease all violation of this License, then your
|
||||||
|
license from a particular copyright holder is reinstated (a)
|
||||||
|
provisionally, unless and until the copyright holder explicitly and
|
||||||
|
finally terminates your license, and (b) permanently, if the copyright
|
||||||
|
holder fails to notify you of the violation by some reasonable means
|
||||||
|
prior to 60 days after the cessation.
|
||||||
|
|
||||||
|
Moreover, your license from a particular copyright holder is
|
||||||
|
reinstated permanently if the copyright holder notifies you of the
|
||||||
|
violation by some reasonable means, this is the first time you have
|
||||||
|
received notice of violation of this License (for any work) from that
|
||||||
|
copyright holder, and you cure the violation prior to 30 days after
|
||||||
|
your receipt of the notice.
|
||||||
|
|
||||||
|
Termination of your rights under this section does not terminate the
|
||||||
|
licenses of parties who have received copies or rights from you under
|
||||||
|
this License. If your rights have been terminated and not permanently
|
||||||
|
reinstated, you do not qualify to receive new licenses for the same
|
||||||
|
material under section 10.
|
||||||
|
|
||||||
|
9. Acceptance Not Required for Having Copies.
|
||||||
|
|
||||||
|
You are not required to accept this License in order to receive or
|
||||||
|
run a copy of the Program. Ancillary propagation of a covered work
|
||||||
|
occurring solely as a consequence of using peer-to-peer transmission
|
||||||
|
to receive a copy likewise does not require acceptance. However,
|
||||||
|
nothing other than this License grants you permission to propagate or
|
||||||
|
modify any covered work. These actions infringe copyright if you do
|
||||||
|
not accept this License. Therefore, by modifying or propagating a
|
||||||
|
covered work, you indicate your acceptance of this License to do so.
|
||||||
|
|
||||||
|
10. Automatic Licensing of Downstream Recipients.
|
||||||
|
|
||||||
|
Each time you convey a covered work, the recipient automatically
|
||||||
|
receives a license from the original licensors, to run, modify and
|
||||||
|
propagate that work, subject to this License. You are not responsible
|
||||||
|
for enforcing compliance by third parties with this License.
|
||||||
|
|
||||||
|
An "entity transaction" is a transaction transferring control of an
|
||||||
|
organization, or substantially all assets of one, or subdividing an
|
||||||
|
organization, or merging organizations. If propagation of a covered
|
||||||
|
work results from an entity transaction, each party to that
|
||||||
|
transaction who receives a copy of the work also receives whatever
|
||||||
|
licenses to the work the party's predecessor in interest had or could
|
||||||
|
give under the previous paragraph, plus a right to possession of the
|
||||||
|
Corresponding Source of the work from the predecessor in interest, if
|
||||||
|
the predecessor has it or can get it with reasonable efforts.
|
||||||
|
|
||||||
|
You may not impose any further restrictions on the exercise of the
|
||||||
|
rights granted or affirmed under this License. For example, you may
|
||||||
|
not impose a license fee, royalty, or other charge for exercise of
|
||||||
|
rights granted under this License, and you may not initiate litigation
|
||||||
|
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||||
|
any patent claim is infringed by making, using, selling, offering for
|
||||||
|
sale, or importing the Program or any portion of it.
|
||||||
|
|
||||||
|
11. Patents.
|
||||||
|
|
||||||
|
A "contributor" is a copyright holder who authorizes use under this
|
||||||
|
License of the Program or a work on which the Program is based. The
|
||||||
|
work thus licensed is called the contributor's "contributor version".
|
||||||
|
|
||||||
|
A contributor's "essential patent claims" are all patent claims
|
||||||
|
owned or controlled by the contributor, whether already acquired or
|
||||||
|
hereafter acquired, that would be infringed by some manner, permitted
|
||||||
|
by this License, of making, using, or selling its contributor version,
|
||||||
|
but do not include claims that would be infringed only as a
|
||||||
|
consequence of further modification of the contributor version. For
|
||||||
|
purposes of this definition, "control" includes the right to grant
|
||||||
|
patent sublicenses in a manner consistent with the requirements of
|
||||||
|
this License.
|
||||||
|
|
||||||
|
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||||
|
patent license under the contributor's essential patent claims, to
|
||||||
|
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||||
|
propagate the contents of its contributor version.
|
||||||
|
|
||||||
|
In the following three paragraphs, a "patent license" is any express
|
||||||
|
agreement or commitment, however denominated, not to enforce a patent
|
||||||
|
(such as an express permission to practice a patent or covenant not to
|
||||||
|
sue for patent infringement). To "grant" such a patent license to a
|
||||||
|
party means to make such an agreement or commitment not to enforce a
|
||||||
|
patent against the party.
|
||||||
|
|
||||||
|
If you convey a covered work, knowingly relying on a patent license,
|
||||||
|
and the Corresponding Source of the work is not available for anyone
|
||||||
|
to copy, free of charge and under the terms of this License, through a
|
||||||
|
publicly available network server or other readily accessible means,
|
||||||
|
then you must either (1) cause the Corresponding Source to be so
|
||||||
|
available, or (2) arrange to deprive yourself of the benefit of the
|
||||||
|
patent license for this particular work, or (3) arrange, in a manner
|
||||||
|
consistent with the requirements of this License, to extend the patent
|
||||||
|
license to downstream recipients. "Knowingly relying" means you have
|
||||||
|
actual knowledge that, but for the patent license, your conveying the
|
||||||
|
covered work in a country, or your recipient's use of the covered work
|
||||||
|
in a country, would infringe one or more identifiable patents in that
|
||||||
|
country that you have reason to believe are valid.
|
||||||
|
|
||||||
|
If, pursuant to or in connection with a single transaction or
|
||||||
|
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||||
|
covered work, and grant a patent license to some of the parties
|
||||||
|
receiving the covered work authorizing them to use, propagate, modify
|
||||||
|
or convey a specific copy of the covered work, then the patent license
|
||||||
|
you grant is automatically extended to all recipients of the covered
|
||||||
|
work and works based on it.
|
||||||
|
|
||||||
|
A patent license is "discriminatory" if it does not include within
|
||||||
|
the scope of its coverage, prohibits the exercise of, or is
|
||||||
|
conditioned on the non-exercise of one or more of the rights that are
|
||||||
|
specifically granted under this License. You may not convey a covered
|
||||||
|
work if you are a party to an arrangement with a third party that is
|
||||||
|
in the business of distributing software, under which you make payment
|
||||||
|
to the third party based on the extent of your activity of conveying
|
||||||
|
the work, and under which the third party grants, to any of the
|
||||||
|
parties who would receive the covered work from you, a discriminatory
|
||||||
|
patent license (a) in connection with copies of the covered work
|
||||||
|
conveyed by you (or copies made from those copies), or (b) primarily
|
||||||
|
for and in connection with specific products or compilations that
|
||||||
|
contain the covered work, unless you entered into that arrangement,
|
||||||
|
or that patent license was granted, prior to 28 March 2007.
|
||||||
|
|
||||||
|
Nothing in this License shall be construed as excluding or limiting
|
||||||
|
any implied license or other defenses to infringement that may
|
||||||
|
otherwise be available to you under applicable patent law.
|
||||||
|
|
||||||
|
12. No Surrender of Others' Freedom.
|
||||||
|
|
||||||
|
If conditions are imposed on you (whether by court order, agreement or
|
||||||
|
otherwise) that contradict the conditions of this License, they do not
|
||||||
|
excuse you from the conditions of this License. If you cannot convey a
|
||||||
|
covered work so as to satisfy simultaneously your obligations under this
|
||||||
|
License and any other pertinent obligations, then as a consequence you may
|
||||||
|
not convey it at all. For example, if you agree to terms that obligate you
|
||||||
|
to collect a royalty for further conveying from those to whom you convey
|
||||||
|
the Program, the only way you could satisfy both those terms and this
|
||||||
|
License would be to refrain entirely from conveying the Program.
|
||||||
|
|
||||||
|
13. Use with the GNU Affero General Public License.
|
||||||
|
|
||||||
|
Notwithstanding any other provision of this License, you have
|
||||||
|
permission to link or combine any covered work with a work licensed
|
||||||
|
under version 3 of the GNU Affero General Public License into a single
|
||||||
|
combined work, and to convey the resulting work. The terms of this
|
||||||
|
License will continue to apply to the part which is the covered work,
|
||||||
|
but the special requirements of the GNU Affero General Public License,
|
||||||
|
section 13, concerning interaction through a network will apply to the
|
||||||
|
combination as such.
|
||||||
|
|
||||||
|
14. Revised Versions of this License.
|
||||||
|
|
||||||
|
The Free Software Foundation may publish revised and/or new versions of
|
||||||
|
the GNU General Public License from time to time. Such new versions will
|
||||||
|
be similar in spirit to the present version, but may differ in detail to
|
||||||
|
address new problems or concerns.
|
||||||
|
|
||||||
|
Each version is given a distinguishing version number. If the
|
||||||
|
Program specifies that a certain numbered version of the GNU General
|
||||||
|
Public License "or any later version" applies to it, you have the
|
||||||
|
option of following the terms and conditions either of that numbered
|
||||||
|
version or of any later version published by the Free Software
|
||||||
|
Foundation. If the Program does not specify a version number of the
|
||||||
|
GNU General Public License, you may choose any version ever published
|
||||||
|
by the Free Software Foundation.
|
||||||
|
|
||||||
|
If the Program specifies that a proxy can decide which future
|
||||||
|
versions of the GNU General Public License can be used, that proxy's
|
||||||
|
public statement of acceptance of a version permanently authorizes you
|
||||||
|
to choose that version for the Program.
|
||||||
|
|
||||||
|
Later license versions may give you additional or different
|
||||||
|
permissions. However, no additional obligations are imposed on any
|
||||||
|
author or copyright holder as a result of your choosing to follow a
|
||||||
|
later version.
|
||||||
|
|
||||||
|
15. Disclaimer of Warranty.
|
||||||
|
|
||||||
|
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||||
|
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||||
|
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||||
|
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||||
|
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||||
|
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||||
|
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||||
|
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||||
|
|
||||||
|
16. Limitation of Liability.
|
||||||
|
|
||||||
|
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||||
|
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||||
|
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||||
|
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||||
|
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||||
|
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||||
|
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||||
|
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||||
|
SUCH DAMAGES.
|
||||||
|
|
||||||
|
17. Interpretation of Sections 15 and 16.
|
||||||
|
|
||||||
|
If the disclaimer of warranty and limitation of liability provided
|
||||||
|
above cannot be given local legal effect according to their terms,
|
||||||
|
reviewing courts shall apply local law that most closely approximates
|
||||||
|
an absolute waiver of all civil liability in connection with the
|
||||||
|
Program, unless a warranty or assumption of liability accompanies a
|
||||||
|
copy of the Program in return for a fee.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
How to Apply These Terms to Your New Programs
|
||||||
|
|
||||||
|
If you develop a new program, and you want it to be of the greatest
|
||||||
|
possible use to the public, the best way to achieve this is to make it
|
||||||
|
free software which everyone can redistribute and change under these terms.
|
||||||
|
|
||||||
|
To do so, attach the following notices to the program. It is safest
|
||||||
|
to attach them to the start of each source file to most effectively
|
||||||
|
state the exclusion of warranty; and each file should have at least
|
||||||
|
the "copyright" line and a pointer to where the full notice is found.
|
||||||
|
|
||||||
|
<one line to give the program's name and a brief idea of what it does.>
|
||||||
|
Copyright (C) <year> <name of author>
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Also add information on how to contact you by electronic and paper mail.
|
||||||
|
|
||||||
|
If the program does terminal interaction, make it output a short
|
||||||
|
notice like this when it starts in an interactive mode:
|
||||||
|
|
||||||
|
<program> Copyright (C) <year> <name of author>
|
||||||
|
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||||
|
This is free software, and you are welcome to redistribute it
|
||||||
|
under certain conditions; type `show c' for details.
|
||||||
|
|
||||||
|
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||||
|
parts of the General Public License. Of course, your program's commands
|
||||||
|
might be different; for a GUI interface, you would use an "about box".
|
||||||
|
|
||||||
|
You should also get your employer (if you work as a programmer) or school,
|
||||||
|
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||||
|
For more information on this, and how to apply and follow the GNU GPL, see
|
||||||
|
<http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
The GNU General Public License does not permit incorporating your program
|
||||||
|
into proprietary programs. If your program is a subroutine library, you
|
||||||
|
may consider it more useful to permit linking proprietary applications with
|
||||||
|
the library. If this is what you want to do, use the GNU Lesser General
|
||||||
|
Public License instead of this License. But first, please read
|
||||||
|
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
||||||
|
|
68
externals/ola2pd/leeme.txt
vendored
Normal file
68
externals/ola2pd/leeme.txt
vendored
Normal file
|
@ -0,0 +1,68 @@
|
||||||
|
*******************************************************************************
|
||||||
|
ola2pd 0.02 6/01/2013
|
||||||
|
|
||||||
|
(C) 2012-2013 Santi Noreña belfegor<AT>gmail.com
|
||||||
|
|
||||||
|
Based on dmxmonitor by Dirk Jagdmann doj<AT>cubic.org
|
||||||
|
and dmxmonitor_ola by Simon Newton nomis52<AT>gmail.com
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
ola2pd es un objeto de Pure Data que permite leer un universo DMX512 del demonio de Open Lighting Arquitecture. Este proporciona soporte para muchos protocoles de iluminación basados en red (Pathport, ArtNet, ACN, ShowNet, SandNet) y dispositivos USB-DMX (Enttec Open DMX Pro, Velleman, Robe,...).
|
||||||
|
|
||||||
|
El objeto está desarrollado con las cabeceras Flext de Thomas Grill. Se incluye el binario para GNU/Linux, testeado en Debian Wheezy y Ubuntu Precise 12.04.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Instalación:
|
||||||
|
|
||||||
|
- Instala y configura OLA siguiendo las instrucciones de http://code.google.com/p/linux-lighting
|
||||||
|
|
||||||
|
- Copia el archivo ola2pd.pd_linux en una carpeta que esté dentro de las rutas de Pure Data (la carpeta pd-externals en la carpeta de usuario es el sitio indicado) o en la carpeta del patch que uses.
|
||||||
|
|
||||||
|
- Si el binario no funciona en tu distribución puedes probar a compilarlo tú mismo. Necesitas tener instalado y compilado flext, y las fuentes de Pure Data/Max. Después se puede compilar con el build.sh de flext bash /home/user/flext/build.sh <system> <compiler>.
|
||||||
|
|
||||||
|
- En Ubuntu hay que hacer un paso más. El gcc de Ubuntu tiene una opción habilitada que hace que build.sh no linke bien la biblioteca ola. Como workaround copia la salida de la terminal entre el último g+++ y -lflext-pd_t en un archivo de texto y mueve -lola al final de la línea. Copia todo de nuevo y pégalo en terminal.
|
||||||
|
|
||||||
|
En mi caso copio
|
||||||
|
|
||||||
|
g++ -L/usr/include/ola -lola -pthread -shared -Wl,-S -L/home/santi/PMS/pd-0.43-2/bin -L/usr/lib -o pd-linux/release-multi/ola2pd.pd_linux pd-linux/release-multi/main.opp -lflext-pd_t
|
||||||
|
|
||||||
|
y lo cambio a
|
||||||
|
|
||||||
|
g++ -L/usr/include/ola -pthread -shared -Wl,-S -L/home/santi/PMS/pd-0.43-2/bin -L/usr/lib -o pd-linux/release-multi/ola2pd.pd_linux pd-linux/release-multi/main.opp -lflext-pd_t -lola
|
||||||
|
|
||||||
|
Después ya se tiene el binario listo para usar.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Uso:
|
||||||
|
|
||||||
|
- El demonio olad debe de estar corriendo en el sistema y con un universo al menos configurado como input para que podamos tomar datos de él.
|
||||||
|
- El demonio olad escucha en el interface activo con la IP más baja, típicamente 2.x.x.x. Podemos ver si están llegando datos dirigiendo un navegador web a localhost:9090. Después pinchando en el universo que queramos monitorizar y luego pinchando en la pestaña "DMX MMonitor".
|
||||||
|
- Están disponibles los 512 canales; El objeto saca una lista de 512 enteros.
|
||||||
|
- Antes de que el objeto empiece a sacar valores hay que crear el nodo. Para ello hay que mandar un mensaje [open]. Antes de ello podemos configurar el universo de OLA al que queremos que escuche con el mensaje <universe x>. donde x es el número de universo OLA. Por defecto escucha en el universo 0. Si queremos cambiar el universo de escucha hay que cerrar el nodo mandando un mensaje [close], mandar el mensaje <universe x>, y volver a mandar [open]
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Créditos:
|
||||||
|
|
||||||
|
- Simon Newton por OLA y ola_dmxmonitor. Esto es una modificación de ese código.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Repositorio SVN:
|
||||||
|
|
||||||
|
http://code.google.com/p/libremediaserver/externals/ola2pd
|
||||||
|
|
||||||
|
Contacto:
|
||||||
|
|
||||||
|
belfegor@gmail.com
|
||||||
|
|
||||||
|
*******************************************************************************
|
197
externals/ola2pd/main.cpp
vendored
Normal file
197
externals/ola2pd/main.cpp
vendored
Normal file
|
@ -0,0 +1,197 @@
|
||||||
|
/*
|
||||||
|
* ola2pd - interface from Open Lighting Arquitecture to Pure Data
|
||||||
|
* v 0.02 - 5/1/2013
|
||||||
|
*
|
||||||
|
* Copyright (c) 2012-2013 Santiago Noreña (libremediaserver@gmail.com)
|
||||||
|
*
|
||||||
|
* ola2pd is an external for Pure Data and Max that reads one DMX512
|
||||||
|
* universe from the Open Lighting Arquitecture and output it like a list
|
||||||
|
* of 512 channels.
|
||||||
|
*
|
||||||
|
* Based on dmxmonitor Copyright (C) 2001 Dirk Jagdmann <doj@cubic.org>
|
||||||
|
* and ola_dmxmonitor by Simon Newton (nomis52<AT>gmail.com)
|
||||||
|
*
|
||||||
|
* This program is free software; you can redistribute it and/or
|
||||||
|
* modify it under the terms of the GNU General Public License
|
||||||
|
* as published by the Free Software Foundation; either version 2
|
||||||
|
* of the License, or (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Define flext
|
||||||
|
#define FLEXT_USE_CMEM 1
|
||||||
|
//#define FLEXT_SHARED 1
|
||||||
|
#define FLEXT_ATTRIBUTES 1
|
||||||
|
#include <flext.h>
|
||||||
|
#if !defined(FLEXT_VERSION) || (FLEXT_VERSION < 500)
|
||||||
|
#error You need at least flext version 0.5.0
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_CONFIG_H
|
||||||
|
#include <config.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// Define general
|
||||||
|
|
||||||
|
#include <errno.h>
|
||||||
|
#include <string>
|
||||||
|
|
||||||
|
// Define ola
|
||||||
|
|
||||||
|
#include <ola/BaseTypes.h>
|
||||||
|
#include <ola/Callback.h>
|
||||||
|
#include <ola/OlaCallbackClient.h>
|
||||||
|
#include <ola/OlaClientWrapper.h>
|
||||||
|
#include <ola/DmxBuffer.h>
|
||||||
|
#include <ola/io/SelectServer.h>
|
||||||
|
#include <ola/network/TCPSocket.h>
|
||||||
|
|
||||||
|
using ola::DmxBuffer;
|
||||||
|
using ola::OlaCallbackClient;
|
||||||
|
using ola::OlaCallbackClientWrapper;
|
||||||
|
using ola::io::SelectServer;
|
||||||
|
using std::string;
|
||||||
|
|
||||||
|
class ola2pd:
|
||||||
|
|
||||||
|
public flext_base
|
||||||
|
{
|
||||||
|
|
||||||
|
FLEXT_HEADER_S(ola2pd,flext_base,setup)
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
// constructor with no arguments
|
||||||
|
ola2pd():
|
||||||
|
// initialize data members
|
||||||
|
m_universe(0),
|
||||||
|
m_clientpointer(NULL),
|
||||||
|
m_counter(0)
|
||||||
|
// m_stdin_descriptor(STDIN_FILENO)
|
||||||
|
{
|
||||||
|
// --- define inlets and outlets ---
|
||||||
|
AddInAnything(); // default inlet
|
||||||
|
AddOutList(); // outlet for DMX list
|
||||||
|
post("ola2pd v0.02 - an interface to Open Lighting Arquitecture");
|
||||||
|
post("(C) 2012-2013 Santi Noreña libremediaserver@gmail.com");
|
||||||
|
}
|
||||||
|
void NewDmx(unsigned int universe,
|
||||||
|
const DmxBuffer &buffer,
|
||||||
|
const string &error);
|
||||||
|
void RegisterComplete(const string &error);
|
||||||
|
// void StdinReady();
|
||||||
|
bool CheckDataLoss();
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
void m_open() {
|
||||||
|
if (m_clientpointer == NULL)
|
||||||
|
{
|
||||||
|
// set up ola connection
|
||||||
|
if (!m_client.Setup()) {
|
||||||
|
post("%s: %s",thisName(), strerror(errno));
|
||||||
|
}
|
||||||
|
m_clientpointer = m_client.GetClient();
|
||||||
|
m_clientpointer->SetDmxCallback(ola::NewCallback(this, &ola2pd::NewDmx));
|
||||||
|
m_clientpointer->RegisterUniverse(m_universe,ola::REGISTER,ola::NewSingleCallback(this, &ola2pd::RegisterComplete));
|
||||||
|
// m_client.GetSelectServer()->AddReadDescriptor(&m_stdin_descriptor);
|
||||||
|
// m_stdin_descriptor.SetOnData(ola::NewCallback(this, &ola2pd::StdinReady));
|
||||||
|
m_client.GetSelectServer()->RegisterRepeatingTimeout(5000,ola::NewCallback(this, &ola2pd::CheckDataLoss));
|
||||||
|
post("ola2pd: Init complete. Start listening...");
|
||||||
|
m_client.GetSelectServer()->Run();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void m_close() {
|
||||||
|
if (m_clientpointer != NULL)
|
||||||
|
{
|
||||||
|
m_clientpointer->RegisterUniverse(m_universe,ola::UNREGISTER,ola::NewSingleCallback(this, &ola2pd::RegisterComplete));
|
||||||
|
m_client.GetSelectServer()->Terminate();
|
||||||
|
post("ola2pd: Close complete");
|
||||||
|
m_clientpointer = NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void m_bang() {
|
||||||
|
if (m_clientpointer != NULL) {post("%s listening on universe %d",thisName(),m_universe);}
|
||||||
|
else {post("%s configured on universe %d. Send open to start listening",thisName(),m_universe);}
|
||||||
|
}
|
||||||
|
|
||||||
|
private:
|
||||||
|
unsigned int m_universe;
|
||||||
|
unsigned int m_counter;
|
||||||
|
// ola::io::UnmanagedFileDescriptor m_stdin_descriptor;
|
||||||
|
struct timeval m_last_data;
|
||||||
|
OlaCallbackClientWrapper m_client;
|
||||||
|
OlaCallbackClient *m_clientpointer;
|
||||||
|
|
||||||
|
static void setup(t_classid c)
|
||||||
|
{
|
||||||
|
// --- set up methods (class scope) ---
|
||||||
|
// register a bang method to the default inlet (0)
|
||||||
|
FLEXT_CADDBANG(c,0,m_bang);
|
||||||
|
// set up tagged methods for the default inlet (0)
|
||||||
|
FLEXT_CADDMETHOD_(c,0,"open",m_open);
|
||||||
|
FLEXT_CADDMETHOD_(c,0,"close",m_close);
|
||||||
|
// --- set up attributes (class scope) ---
|
||||||
|
FLEXT_CADDATTR_VAR1(c,"universe",m_universe);
|
||||||
|
}
|
||||||
|
FLEXT_CALLBACK(m_bang)
|
||||||
|
FLEXT_THREAD(m_open)
|
||||||
|
FLEXT_CALLBACK(m_close)
|
||||||
|
FLEXT_ATTRVAR_I(m_universe) // wrapper functions (get and set) for integer variable universe
|
||||||
|
};
|
||||||
|
// instantiate the class (constructor takes no arguments)
|
||||||
|
FLEXT_NEW("ola2pd",ola2pd)
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Called when there is new DMX data
|
||||||
|
*/
|
||||||
|
|
||||||
|
void ola2pd::NewDmx(unsigned int universe,
|
||||||
|
const DmxBuffer &buffer,
|
||||||
|
const string &error) {
|
||||||
|
m_counter++;
|
||||||
|
gettimeofday(&m_last_data, NULL);
|
||||||
|
int z;
|
||||||
|
AtomList dmxlist;
|
||||||
|
dmxlist(512);
|
||||||
|
for(z=0; z < 512; z++){SetFloat(dmxlist[z],(buffer.Get(z)));}
|
||||||
|
ToOutList(0, dmxlist);
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Check for data loss.
|
||||||
|
*/
|
||||||
|
|
||||||
|
bool ola2pd::CheckDataLoss() {
|
||||||
|
struct timeval now, diff;
|
||||||
|
if (timerisset(&m_last_data)) {
|
||||||
|
gettimeofday(&now, NULL);
|
||||||
|
timersub(&now, &m_last_data, &diff);
|
||||||
|
if (diff.tv_sec > 4 || (diff.tv_sec == 4 && diff.tv_usec > 4000000)) {
|
||||||
|
// loss of data
|
||||||
|
post("ola2pd: Can not read DMX!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Control de errores en el registro de Universos en OLA
|
||||||
|
*/
|
||||||
|
void ola2pd::RegisterComplete(const string &error) {
|
||||||
|
if (!error.empty()) {
|
||||||
|
post("ola2pd:Register command failed");
|
||||||
|
m_client.GetSelectServer()->Terminate();
|
||||||
|
}
|
||||||
|
}
|
BIN
externals/ola2pd/ola2pd.pd_linux
vendored
Executable file
BIN
externals/ola2pd/ola2pd.pd_linux
vendored
Executable file
Binary file not shown.
34
externals/ola2pd/ola2pd_help.pd
vendored
Executable file
34
externals/ola2pd/ola2pd_help.pd
vendored
Executable file
|
@ -0,0 +1,34 @@
|
||||||
|
#N canvas 533 109 610 300 10;
|
||||||
|
#X obj 192 126 ola2pd;
|
||||||
|
#X obj 324 52 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
|
||||||
|
-1;
|
||||||
|
#X msg 190 47 open;
|
||||||
|
#X msg 240 49 close;
|
||||||
|
#X msg 92 68 universe 0;
|
||||||
|
#X msg 8 68 universe 2;
|
||||||
|
#X obj 192 175 list split 4;
|
||||||
|
#X obj 192 219 unpack f f f f;
|
||||||
|
#X floatatom 110 252 5 0 0 0 - - -;
|
||||||
|
#X floatatom 192 253 5 0 0 0 - - -;
|
||||||
|
#X floatatom 278 253 5 0 0 0 - - -;
|
||||||
|
#X floatatom 356 253 5 0 0 0 - - -;
|
||||||
|
#X text 98 268 Channel 1;
|
||||||
|
#X text 182 270 Channel 2;
|
||||||
|
#X text 267 270 Channel 3;
|
||||||
|
#X text 348 270 Channel 4;
|
||||||
|
#X text 11 6 ola2pd - Interface for reading dmx data from Open Lightin
|
||||||
|
Arquitecture. (c) 2012-2013 Santi Noreña - GPL License;
|
||||||
|
#X text 248 103 Start and configure olad before sending open to ola2pd!
|
||||||
|
;
|
||||||
|
#X text 16 52 OLA Universe to bind;
|
||||||
|
#X connect 0 0 6 0;
|
||||||
|
#X connect 1 0 0 0;
|
||||||
|
#X connect 2 0 0 0;
|
||||||
|
#X connect 3 0 0 0;
|
||||||
|
#X connect 4 0 0 0;
|
||||||
|
#X connect 5 0 0 0;
|
||||||
|
#X connect 6 0 7 0;
|
||||||
|
#X connect 7 0 8 0;
|
||||||
|
#X connect 7 1 9 0;
|
||||||
|
#X connect 7 2 10 0;
|
||||||
|
#X connect 7 3 11 0;
|
19
externals/ola2pd/package.txt
vendored
Normal file
19
externals/ola2pd/package.txt
vendored
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
NAME=ola2pd
|
||||||
|
SRCS=main.cpp
|
||||||
|
|
||||||
|
# user defined compiler flags
|
||||||
|
UFLAGS += -v
|
||||||
|
|
||||||
|
# user defined linker flags
|
||||||
|
LDFLAGS += -lola
|
||||||
|
|
||||||
|
# FLEXT HEADERS
|
||||||
|
|
||||||
|
# multithreading
|
||||||
|
|
||||||
|
BUILDTYPE=multi
|
||||||
|
|
||||||
|
# Type mode of the release
|
||||||
|
|
||||||
|
BUILDMODE=release
|
||||||
|
|
71
externals/ola2pd/readme.txt
vendored
Normal file
71
externals/ola2pd/readme.txt
vendored
Normal file
|
@ -0,0 +1,71 @@
|
||||||
|
*******************************************************************************
|
||||||
|
ola2pd 0.02 6/1/2013
|
||||||
|
|
||||||
|
(C) 2012-2013 Santi Noreña belfegor<AT>gmail.com
|
||||||
|
|
||||||
|
Based on dmxmonitor by Dirk Jagdmann doj<AT>cubic.org
|
||||||
|
and dmxmonitor_ola by Simon Newton nomis52<AT>gmail.com
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
ola2pd is an external for Pure Data that reads one DMX512 universe from the Open Lighting Arquitecture daemon. OLA supports a lot of of lighting protocols (ArtNet, Pathport, ACN, ShowNet, SandNet) and USB-DMX devices (Enttec Open DMX Pro, Velleman, Robe,...)
|
||||||
|
|
||||||
|
Ola2pd has been developed with the flext headers from Thoma Grill. The binary file included has been tested in Ubuntu Precise 12.04 and Debian Wheezy.
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Install:
|
||||||
|
|
||||||
|
- Install and set up OLA following the project instructions from http://code.google.com/p/linux-lighting
|
||||||
|
|
||||||
|
- Copy the file ola2pd.pd_linux in a folder in the Pure Data paths. ~/pd-extenals is a good place, or in the folder of the patch you are using.
|
||||||
|
|
||||||
|
- If the binary doesn't work in you distribution, you can try compiling it yourself. You need having compiled and installed the flext headers http://grrrr.org/research/software/flext/, the Pure Data sources, and the OLA headers. See build.txt in the flext package for details. Basically you must run the flext build tool (build.sh) in the ola2pd folder.
|
||||||
|
|
||||||
|
- For Ubuntu there is an aditional compilation step. Ubuntu's gcc has a option making buils.sh doesn't link correctly the OLA library. You can copy the last command of the build.sh terminal output and change the option -lola to the end of the command. For me, i copy:
|
||||||
|
|
||||||
|
g++ -L/usr/include/ola -lola -pthread -shared -Wl,-S -L/home/santi/PMS/pd-0.43-2/bin -L/usr/lib -o pd-linux/release-multi/ola2pd.pd_linux pd-linux/release-multi/main.opp -lflext-pd_t
|
||||||
|
|
||||||
|
and i change to:
|
||||||
|
|
||||||
|
g++ -L/usr/include/ola -pthread -shared -Wl,-S -L/home/santi/PMS/pd-0.43-2/bin -L/usr/lib -o pd-linux/release-multi/ola2pd.pd_linux pd-linux/release-multi/main.opp -lflext-pd_t -lola
|
||||||
|
|
||||||
|
After you can run
|
||||||
|
|
||||||
|
strip --strip-unneeded pd-linux/release-multi/ola2pd.pd_linux
|
||||||
|
|
||||||
|
to make the binary smaller. After, the binary is ready to work
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Usage:
|
||||||
|
|
||||||
|
- The ola daemon must be running in the system and set up with at least one input universe.
|
||||||
|
- olad listens on the network interface with lower IP address, tipically 2.x.x.x. You can see if valid data is arriving pointing one web browser to localhost:9090. Click in the universe you want and click in the "DMX Monitor" tab. You should see the arriving data.
|
||||||
|
- Before ola2pd begins output values, we can configure the listening universe with the message [universe x), where x is the number of the OLA universe we want to listen. The object begins listening with [open) message. We can change the listening universe closing the connection with a [close) message, sending the new universe and reopening the node.
|
||||||
|
- ola2pd outputs a list with the 512 channel of the universe. We can manipulate with [list split] and [unpack].
|
||||||
|
- See ola2pd-help.pd
|
||||||
|
|
||||||
|
*******************************************************************************
|
||||||
|
|
||||||
|
Credits:
|
||||||
|
|
||||||
|
- Simon Newton for OLA and ola_dmxmonitor, this is a modification of that code.
|
||||||
|
|
||||||
|
*****************************
|
||||||
|
|
||||||
|
SVN:
|
||||||
|
|
||||||
|
http://code.google.com/p/puremediaserver/externals/ola2pd
|
||||||
|
|
||||||
|
Contact:
|
||||||
|
|
||||||
|
belfegor@gmail.com
|
||||||
|
|
||||||
|
*****************************
|
28
externals/pix2jpg/LICENSE.txt
vendored
Normal file
28
externals/pix2jpg/LICENSE.txt
vendored
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
pix2jpg : Convert pix to jpg
|
||||||
|
http://code.google.com/p/puremediaserver
|
||||||
|
Copyright (c) 2012 Santi Noreña
|
||||||
|
|
||||||
|
based on:
|
||||||
|
GEM - Graphics Environment for Multimedia
|
||||||
|
Copyright (C) 1997-2000 Mark Danks, Günter Geiger,
|
||||||
|
Copyright (c) 2001-2010 IOhannes m zmölnig
|
||||||
|
Copyright (c) 2003-2007 James Tittle II,
|
||||||
|
Copyright (c) 2003-2008 Chris Clepper et al.
|
||||||
|
|
||||||
|
This program is free software; you can redistribute it and/or
|
||||||
|
modify it under the terms of the GNU General Public License
|
||||||
|
as published by the Free Software Foundation; either version 2
|
||||||
|
of the License, or (at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program; if not, write to the Free Software
|
||||||
|
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||||
|
|
||||||
|
In the official GEM distribution, the GNU General Public License is
|
||||||
|
in the file GnuGPL.LICENSE
|
||||||
|
|
770
externals/pix2jpg/Makefile
vendored
Normal file
770
externals/pix2jpg/Makefile
vendored
Normal file
|
@ -0,0 +1,770 @@
|
||||||
|
# Makefile.in generated by automake 1.11.3 from Makefile.am.
|
||||||
|
# extra/pix2jpg/Makefile. Generated from Makefile.in by configure.
|
||||||
|
|
||||||
|
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
|
||||||
|
# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
|
||||||
|
# Foundation, Inc.
|
||||||
|
# This Makefile.in is free software; the Free Software Foundation
|
||||||
|
# gives unlimited permission to copy and/or distribute it,
|
||||||
|
# with or without modifications, as long as this notice is preserved.
|
||||||
|
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||||
|
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||||
|
# PARTICULAR PURPOSE.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
pkgdatadir = $(datadir)/Gem
|
||||||
|
pkgincludedir = $(includedir)/Gem
|
||||||
|
pkglibdir = $(libdir)/Gem
|
||||||
|
pkglibexecdir = $(libexecdir)/Gem
|
||||||
|
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
|
||||||
|
install_sh_DATA = $(install_sh) -c -m 644
|
||||||
|
install_sh_PROGRAM = $(install_sh) -c
|
||||||
|
install_sh_SCRIPT = $(install_sh) -c
|
||||||
|
INSTALL_HEADER = $(INSTALL_DATA)
|
||||||
|
transform = $(program_transform_name)
|
||||||
|
NORMAL_INSTALL = :
|
||||||
|
PRE_INSTALL = :
|
||||||
|
POST_INSTALL = :
|
||||||
|
NORMAL_UNINSTALL = :
|
||||||
|
PRE_UNINSTALL = :
|
||||||
|
POST_UNINSTALL = :
|
||||||
|
build_triplet = i686-pc-linux-gnu
|
||||||
|
host_triplet = i686-pc-linux-gnu
|
||||||
|
#am__append_1 = -no-undefined
|
||||||
|
subdir = extra/pix2jpg
|
||||||
|
DIST_COMMON = $(dist_extra_DATA) $(srcdir)/Makefile.am \
|
||||||
|
$(srcdir)/Makefile.in
|
||||||
|
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||||
|
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_gl.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_check_glu.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_check_glut.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_compiler_vendor.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_pthread.m4 $(top_srcdir)/m4/gem.m4 \
|
||||||
|
$(top_srcdir)/m4/iem_ftgl.m4 $(top_srcdir)/m4/iem_opengl.m4 \
|
||||||
|
$(top_srcdir)/m4/iem_operatingsystem.m4 \
|
||||||
|
$(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/libtool.m4 \
|
||||||
|
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
|
||||||
|
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
|
||||||
|
$(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac
|
||||||
|
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||||
|
$(ACLOCAL_M4)
|
||||||
|
mkinstalldirs = $(install_sh) -d
|
||||||
|
CONFIG_HEADER = $(top_builddir)/src/config.h
|
||||||
|
CONFIG_CLEAN_FILES =
|
||||||
|
CONFIG_CLEAN_VPATH_FILES =
|
||||||
|
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
|
||||||
|
am__vpath_adj = case $$p in \
|
||||||
|
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
|
||||||
|
*) f=$$p;; \
|
||||||
|
esac;
|
||||||
|
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
|
||||||
|
am__install_max = 40
|
||||||
|
am__nobase_strip_setup = \
|
||||||
|
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
|
||||||
|
am__nobase_strip = \
|
||||||
|
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
|
||||||
|
am__nobase_list = $(am__nobase_strip_setup); \
|
||||||
|
for p in $$list; do echo "$$p $$p"; done | \
|
||||||
|
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
|
||||||
|
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
|
||||||
|
if (++n[$$2] == $(am__install_max)) \
|
||||||
|
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
|
||||||
|
END { for (dir in files) print dir, files[dir] }'
|
||||||
|
am__base_list = \
|
||||||
|
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
|
||||||
|
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
|
||||||
|
am__uninstall_files_from_dir = { \
|
||||||
|
test -z "$$files" \
|
||||||
|
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|
||||||
|
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
|
||||||
|
$(am__cd) "$$dir" && rm -f $$files; }; \
|
||||||
|
}
|
||||||
|
am__installdirs = "$(DESTDIR)$(extradir)" "$(DESTDIR)$(extradir)"
|
||||||
|
LTLIBRARIES = $(extra_LTLIBRARIES)
|
||||||
|
pix2jpg_la_DEPENDENCIES =
|
||||||
|
am_pix2jpg_la_OBJECTS = pix2jpg_la-pix2jpg.lo
|
||||||
|
pix2jpg_la_OBJECTS = $(am_pix2jpg_la_OBJECTS)
|
||||||
|
pix2jpg_la_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
|
||||||
|
$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(pix2jpg_la_CXXFLAGS) \
|
||||||
|
$(CXXFLAGS) $(pix2jpg_la_LDFLAGS) $(LDFLAGS) -o $@
|
||||||
|
DEFAULT_INCLUDES = -I. -I$(top_builddir)/src
|
||||||
|
depcomp = $(SHELL) $(top_srcdir)/depcomp
|
||||||
|
am__depfiles_maybe = depfiles
|
||||||
|
am__mv = mv -f
|
||||||
|
CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||||
|
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
|
||||||
|
LTCXXCOMPILE = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||||
|
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
|
||||||
|
CXXLD = $(CXX)
|
||||||
|
CXXLINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=link $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) \
|
||||||
|
$(LDFLAGS) -o $@
|
||||||
|
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
|
||||||
|
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||||
|
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||||
|
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||||
|
CCLD = $(CC)
|
||||||
|
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
|
||||||
|
$(LDFLAGS) -o $@
|
||||||
|
SOURCES = $(pix2jpg_la_SOURCES)
|
||||||
|
DIST_SOURCES = $(pix2jpg_la_SOURCES)
|
||||||
|
DATA = $(dist_extra_DATA)
|
||||||
|
ETAGS = etags
|
||||||
|
CTAGS = ctags
|
||||||
|
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||||
|
ACLOCAL = ${SHELL} /home/santi/PMS/git/Gem/missing --run aclocal-1.11
|
||||||
|
AGL_CFLAGS =
|
||||||
|
AGL_LIBS =
|
||||||
|
AMTAR = $${TAR-tar}
|
||||||
|
AR = ar
|
||||||
|
AS = as
|
||||||
|
AUTOCONF = ${SHELL} /home/santi/PMS/git/Gem/missing --run autoconf
|
||||||
|
AUTOHEADER = ${SHELL} /home/santi/PMS/git/Gem/missing --run autoheader
|
||||||
|
AUTOMAKE = ${SHELL} /home/santi/PMS/git/Gem/missing --run automake-1.11
|
||||||
|
AWK = gawk
|
||||||
|
CC = gcc
|
||||||
|
CCDEPMODE = depmode=gcc3
|
||||||
|
CFLAGS = -g -O2
|
||||||
|
CPP = gcc -E
|
||||||
|
CPPFLAGS =
|
||||||
|
CXX = g++
|
||||||
|
CXXCPP = g++ -E
|
||||||
|
CXXDEPMODE = depmode=gcc3
|
||||||
|
CXXFLAGS = -g -O2 -freg-struct-return -O3 -falign-loops -falign-functions -falign-jumps -funroll-loops -ffast-math -mmmx
|
||||||
|
CYGPATH_W = echo
|
||||||
|
DEFINES =
|
||||||
|
DEFS = -DHAVE_CONFIG_H
|
||||||
|
DEPDIR = .deps
|
||||||
|
DLLTOOL = dlltool
|
||||||
|
DSYMUTIL =
|
||||||
|
DUMPBIN =
|
||||||
|
ECHO_C =
|
||||||
|
ECHO_N = -n
|
||||||
|
ECHO_T =
|
||||||
|
EGREP = /bin/grep -E
|
||||||
|
EXEEXT =
|
||||||
|
EXT = pd_linux
|
||||||
|
FGREP = /bin/grep -F
|
||||||
|
GEM_ARCH_CXXFLAGS =
|
||||||
|
GEM_ARCH_LDFLAGS =
|
||||||
|
GEM_CFLAGS =
|
||||||
|
GEM_CPPFLAGS = -DGEM_INTERNAL -DGLEW_BUILD
|
||||||
|
GEM_CXXFLAGS =
|
||||||
|
GEM_DEFAULT_WINDOW = gemglxwindow
|
||||||
|
GEM_EXTERNAL_CFLAGS =
|
||||||
|
GEM_EXTERNAL_CPPFLAGS =
|
||||||
|
GEM_EXTERNAL_LIBS =
|
||||||
|
GEM_FRAMEWORK_AGL =
|
||||||
|
GEM_FRAMEWORK_CARBON =
|
||||||
|
GEM_FRAMEWORK_COCOA =
|
||||||
|
GEM_FRAMEWORK_QUICKTIME =
|
||||||
|
GEM_LIBS =
|
||||||
|
GEM_LIB_ASSIMP_CFLAGS =
|
||||||
|
GEM_LIB_ASSIMP_LIBS =
|
||||||
|
GEM_LIB_AVIFILE_CFLAGS = -I/usr/include/avifile-0.7
|
||||||
|
GEM_LIB_AVIFILE_LIBS = -laviplay
|
||||||
|
GEM_LIB_FTGL_CFLAGS = -I/usr/include/freetype2 -I/usr/include/FTGL
|
||||||
|
GEM_LIB_FTGL_LIBS = -lftgl
|
||||||
|
GEM_LIB_GLEW_CFLAGS =
|
||||||
|
GEM_LIB_GLEW_LIBS =
|
||||||
|
GEM_LIB_GMERLIN_AVDEC_CFLAGS =
|
||||||
|
GEM_LIB_GMERLIN_AVDEC_LIBS = -lgmerlin_avdec -lgavl
|
||||||
|
GEM_LIB_IMAGEMAGICK___CFLAGS = -fopenmp -I/usr/include/ImageMagick
|
||||||
|
GEM_LIB_IMAGEMAGICK___LIBS = -lMagick++ -lMagickCore
|
||||||
|
GEM_LIB_JPEG_CFLAGS =
|
||||||
|
GEM_LIB_JPEG_LIBS = -ljpeg
|
||||||
|
GEM_LIB_LIBDC1394_2_CFLAGS =
|
||||||
|
GEM_LIB_LIBDC1394_2_LIBS =
|
||||||
|
GEM_LIB_LIBDV_CFLAGS =
|
||||||
|
GEM_LIB_LIBDV_LIBS = -ldv -lm
|
||||||
|
GEM_LIB_LIBIEC61883_CFLAGS =
|
||||||
|
GEM_LIB_LIBIEC61883_LIBS =
|
||||||
|
GEM_LIB_LIBMPEG3_CFLAGS =
|
||||||
|
GEM_LIB_LIBMPEG3_LIBS =
|
||||||
|
GEM_LIB_LIBQUICKTIME_CFLAGS = -I/usr/include/lqt
|
||||||
|
GEM_LIB_LIBQUICKTIME_LIBS = -lquicktime -lpthread -lm -lz -ldl
|
||||||
|
GEM_LIB_LIBRAW1394_CFLAGS =
|
||||||
|
GEM_LIB_LIBRAW1394_LIBS = -lraw1394
|
||||||
|
GEM_LIB_LIBUNICAP_CFLAGS =
|
||||||
|
GEM_LIB_LIBUNICAP_LIBS =
|
||||||
|
GEM_LIB_LIBV4L1_CFLAGS =
|
||||||
|
GEM_LIB_LIBV4L1_LIBS =
|
||||||
|
GEM_LIB_LIBV4L2_CFLAGS =
|
||||||
|
GEM_LIB_LIBV4L2_LIBS =
|
||||||
|
GEM_LIB_LIBVLC_CFLAGS =
|
||||||
|
GEM_LIB_LIBVLC_LIBS =
|
||||||
|
GEM_LIB_LQT_CFLAGS =
|
||||||
|
GEM_LIB_LQT_LIBS =
|
||||||
|
GEM_LIB_MAGICKCORE_CFLAGS = -fopenmp -I/usr/include/ImageMagick
|
||||||
|
GEM_LIB_MAGICKCORE_LIBS = -lMagickCore
|
||||||
|
GEM_LIB_MPEG_CFLAGS =
|
||||||
|
GEM_LIB_MPEG_LIBS =
|
||||||
|
GEM_LIB_SDL_CFLAGS = -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/SDL
|
||||||
|
GEM_LIB_SDL_LIBS = -lSDL
|
||||||
|
GEM_LIB_TIFF_CFLAGS =
|
||||||
|
GEM_LIB_TIFF_LIBS = -ltiff
|
||||||
|
GEM_LIB_VFW32_CFLAGS =
|
||||||
|
GEM_LIB_VFW32_LIBS =
|
||||||
|
GEM_PTHREAD_CFLAGS =
|
||||||
|
GEM_PTHREAD_LIBS =
|
||||||
|
GEM_RTE = Pure Data
|
||||||
|
GEM_RTE_CFLAGS = -DPD
|
||||||
|
GEM_RTE_EXTENSION = pd_linux
|
||||||
|
GEM_RTE_LIBS =
|
||||||
|
GEM_TARGETS =
|
||||||
|
GLUT_CFLAGS = -pthread
|
||||||
|
GLUT_LIBS = -lglut -lSM -lICE -lXmu -lXi -lGLU -lGL -lm
|
||||||
|
GLU_CFLAGS = -pthread
|
||||||
|
GLU_LIBS = -lGLU -lGL -lm
|
||||||
|
GLX_CFLAGS =
|
||||||
|
GLX_LIBS =
|
||||||
|
GL_CFLAGS = -pthread
|
||||||
|
GL_LIBS = -lGL -lm
|
||||||
|
GREP = /bin/grep
|
||||||
|
INCLUDES =
|
||||||
|
INSTALL = /usr/bin/install -c
|
||||||
|
INSTALL_DATA = ${INSTALL} -m 644
|
||||||
|
INSTALL_PROGRAM = ${INSTALL}
|
||||||
|
INSTALL_SCRIPT = ${INSTALL}
|
||||||
|
INSTALL_STRIP_PROGRAM = $(install_sh) -c -s
|
||||||
|
LD = /usr/bin/ld
|
||||||
|
LDFLAGS =
|
||||||
|
LIBOBJS =
|
||||||
|
LIBS = -lXxf86vm -ldl -lz -lm
|
||||||
|
LIBTOOL = $(SHELL) $(top_builddir)/libtool
|
||||||
|
LIPO =
|
||||||
|
LN_S = ln -s
|
||||||
|
LTLIBOBJS =
|
||||||
|
MAKEDEP_FLAGS = -MM
|
||||||
|
MAKEINFO = ${SHELL} /home/santi/PMS/git/Gem/missing --run makeinfo
|
||||||
|
MANIFEST_TOOL = :
|
||||||
|
MKDIR_P = /bin/mkdir -p
|
||||||
|
NM = /usr/bin/nm -B
|
||||||
|
NMEDIT =
|
||||||
|
OBJC = gcc
|
||||||
|
OBJCDEPMODE = depmode=gcc3
|
||||||
|
OBJCFLAGS =
|
||||||
|
OBJCXX = g++
|
||||||
|
OBJCXXFLAGS =
|
||||||
|
OBJDUMP = objdump
|
||||||
|
OBJEXT = o
|
||||||
|
OTOOL =
|
||||||
|
OTOOL64 =
|
||||||
|
PACKAGE = Gem
|
||||||
|
PACKAGE_BUGREPORT = zmoelnig@iem.at
|
||||||
|
PACKAGE_NAME = Gem
|
||||||
|
PACKAGE_STRING = Gem 0.93
|
||||||
|
PACKAGE_TARNAME = Gem
|
||||||
|
PACKAGE_URL = http://gem.iem.at
|
||||||
|
PACKAGE_VERSION = 0.93
|
||||||
|
PATH_SEPARATOR = :
|
||||||
|
PKG_ASSIMP_CFLAGS =
|
||||||
|
PKG_ASSIMP_LIBS = -lassimp
|
||||||
|
PKG_AVIFILE_CFLAGS = -I/usr/include/avifile-0.7
|
||||||
|
PKG_AVIFILE_LIBS = -laviplay
|
||||||
|
PKG_CFLAGS = -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/SDL -fopenmp -I/usr/include/ImageMagick -fopenmp -I/usr/include/ImageMagick -I/usr/include/freetype2 -I/usr/include/FTGL -I/usr/include/avifile-0.7 -I/usr/include/lqt
|
||||||
|
PKG_CONFIG = /usr/bin/pkg-config
|
||||||
|
PKG_FTGL_CFLAGS = -I/usr/include/freetype2 -I/usr/include/FTGL
|
||||||
|
PKG_FTGL_LIBS = -lftgl
|
||||||
|
PKG_GLEW_CFLAGS =
|
||||||
|
PKG_GLEW_LIBS =
|
||||||
|
PKG_GMERLIN_AVDEC_CFLAGS =
|
||||||
|
PKG_GMERLIN_AVDEC_LIBS = -lgmerlin_avdec -lgavl
|
||||||
|
PKG_IMAGEMAGICK___CFLAGS = -fopenmp -I/usr/include/ImageMagick
|
||||||
|
PKG_IMAGEMAGICK___LIBS = -lMagick++ -lMagickCore
|
||||||
|
PKG_JPEG_CFLAGS =
|
||||||
|
PKG_JPEG_LIBS = -ljpeg
|
||||||
|
PKG_LIBDC1394_2_CFLAGS =
|
||||||
|
PKG_LIBDC1394_2_LIBS = -ldc1394
|
||||||
|
PKG_LIBDV_CFLAGS =
|
||||||
|
PKG_LIBDV_LIBS = -ldv -lm
|
||||||
|
PKG_LIBIEC61883_CFLAGS =
|
||||||
|
PKG_LIBIEC61883_LIBS = -liec61883
|
||||||
|
PKG_LIBMPEG3_CFLAGS =
|
||||||
|
PKG_LIBMPEG3_LIBS = -lmpeg3
|
||||||
|
PKG_LIBQUICKTIME_CFLAGS = -I/usr/include/lqt
|
||||||
|
PKG_LIBQUICKTIME_LIBS = -lquicktime -lpthread -lm -lz -ldl
|
||||||
|
PKG_LIBRAW1394_CFLAGS =
|
||||||
|
PKG_LIBRAW1394_LIBS = -lraw1394
|
||||||
|
PKG_LIBS = -lraw1394 -ldv -lm -lquicktime -lpthread -lm -lz -ldl -lgmerlin_avdec -lgavl -laviplay -lftgl -lMagickCore -lMagick++ -lMagickCore -lSDL
|
||||||
|
PKG_LIBUNICAP_CFLAGS =
|
||||||
|
PKG_LIBUNICAP_LIBS = -lunicap
|
||||||
|
PKG_LIBV4L1_CFLAGS =
|
||||||
|
PKG_LIBV4L1_LIBS = -lv4l1
|
||||||
|
PKG_LIBV4L2_CFLAGS =
|
||||||
|
PKG_LIBV4L2_LIBS = -lv4l2
|
||||||
|
PKG_LIBVLC_CFLAGS =
|
||||||
|
PKG_LIBVLC_LIBS = -lvlc
|
||||||
|
PKG_LQT_CFLAGS =
|
||||||
|
PKG_LQT_LIBS = -lquicktime
|
||||||
|
PKG_MAGICKCORE_CFLAGS = -fopenmp -I/usr/include/ImageMagick
|
||||||
|
PKG_MAGICKCORE_LIBS = -lMagickCore
|
||||||
|
PKG_MPEG_CFLAGS =
|
||||||
|
PKG_MPEG_LIBS = -lmpeg
|
||||||
|
PKG_SDL_CFLAGS = -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/include/SDL
|
||||||
|
PKG_SDL_LIBS = -lSDL
|
||||||
|
PKG_TIFF_CFLAGS =
|
||||||
|
PKG_TIFF_LIBS = -ltiff
|
||||||
|
PKG_VFW32_CFLAGS =
|
||||||
|
PKG_VFW32_LIBS = -lvfw32
|
||||||
|
PTHREAD_CC = gcc
|
||||||
|
PTHREAD_CFLAGS = -pthread
|
||||||
|
PTHREAD_LIBS =
|
||||||
|
RANLIB = ranlib
|
||||||
|
SED = /bin/sed
|
||||||
|
SET_MAKE =
|
||||||
|
SHELL = /bin/bash
|
||||||
|
STRIP = strip
|
||||||
|
VERSION = 0.93
|
||||||
|
XMKMF =
|
||||||
|
X_CFLAGS =
|
||||||
|
X_EXTRA_LIBS =
|
||||||
|
X_LIBS =
|
||||||
|
X_PRE_LIBS = -lSM -lICE
|
||||||
|
abs_builddir = /home/santi/PMS/git/Gem/extra/pix2jpg
|
||||||
|
abs_srcdir = /home/santi/PMS/git/Gem/extra/pix2jpg
|
||||||
|
abs_top_builddir = /home/santi/PMS/git/Gem
|
||||||
|
abs_top_srcdir = /home/santi/PMS/git/Gem
|
||||||
|
ac_ct_AR = ar
|
||||||
|
ac_ct_CC = gcc
|
||||||
|
ac_ct_CXX = g++
|
||||||
|
ac_ct_DUMPBIN =
|
||||||
|
ac_ct_OBJC = gcc
|
||||||
|
ac_ct_OBJCXX = g++
|
||||||
|
am__include = include
|
||||||
|
am__leading_dot = .
|
||||||
|
am__quote =
|
||||||
|
am__tar = $${TAR-tar} chof - "$$tardir"
|
||||||
|
am__untar = $${TAR-tar} xf -
|
||||||
|
ax_pthread_config =
|
||||||
|
bindir = ${exec_prefix}/bin
|
||||||
|
build = i686-pc-linux-gnu
|
||||||
|
build_alias =
|
||||||
|
build_cpu = i686
|
||||||
|
build_os = linux-gnu
|
||||||
|
build_vendor = pc
|
||||||
|
builddir = .
|
||||||
|
datadir = ${datarootdir}
|
||||||
|
datarootdir = ${prefix}/share
|
||||||
|
docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
|
||||||
|
dvidir = ${docdir}
|
||||||
|
exec_prefix = ${prefix}
|
||||||
|
host = i686-pc-linux-gnu
|
||||||
|
host_alias =
|
||||||
|
host_cpu = i686
|
||||||
|
host_os = linux-gnu
|
||||||
|
host_vendor = pc
|
||||||
|
htmldir = ${docdir}
|
||||||
|
includedir = ${prefix}/include
|
||||||
|
infodir = ${datarootdir}/info
|
||||||
|
install_sh = ${SHELL} /home/santi/PMS/git/Gem/install-sh
|
||||||
|
libdir = ${exec_prefix}/lib/pd/extra
|
||||||
|
libexecdir = ${exec_prefix}/libexec
|
||||||
|
localedir = ${datarootdir}/locale
|
||||||
|
localstatedir = ${prefix}/var
|
||||||
|
mandir = ${datarootdir}/man
|
||||||
|
mkdir_p = /bin/mkdir -p
|
||||||
|
oldincludedir = /usr/include
|
||||||
|
pdfdir = ${docdir}
|
||||||
|
prefix = /usr/local
|
||||||
|
program_transform_name = s,x,x,
|
||||||
|
psdir = ${docdir}
|
||||||
|
sbindir = ${exec_prefix}/sbin
|
||||||
|
sharedstatedir = ${prefix}/com
|
||||||
|
srcdir = .
|
||||||
|
subdirs = extra plugins/videoAVT plugins/videoHALCON plugins/videoPYLON
|
||||||
|
sysconfdir = ${prefix}/etc
|
||||||
|
target_alias =
|
||||||
|
top_build_prefix = ../../
|
||||||
|
top_builddir = ../..
|
||||||
|
top_srcdir = ../..
|
||||||
|
AUTOMAKE_OPTIONS = foreign
|
||||||
|
ACLOCAL_AMFLAGS = -I $(top_srcdir)/src/m4
|
||||||
|
AM_CPPFLAGS = -I$(top_srcdir)/src -I/usr/include/ImageMagick
|
||||||
|
EXTRA_DIST =
|
||||||
|
extradir = $(libdir)/pix2jpg
|
||||||
|
extra_LTLIBRARIES = pix2jpg.la
|
||||||
|
dist_extra_DATA = LICENSE.txt pix2jpg-help.pd
|
||||||
|
|
||||||
|
# RTE flags
|
||||||
|
|
||||||
|
# special flags for building externals
|
||||||
|
pix2jpg_la_CXXFLAGS = -DPD -g -O2 \
|
||||||
|
-fstack-protector --param=ssp-buffer-size=4 -Wformat \
|
||||||
|
-Wformat-security -pthread .
|
||||||
|
pix2jpg_la_LDFLAGS = -L/usr/lib -Wl,-Bsymbolic-functions -Wl,-z,relro \
|
||||||
|
-L/usr/lib/X11 -module -avoid-version -shared -shrext \
|
||||||
|
.pd_linux $(am__append_1)
|
||||||
|
pix2jpg_la_LIBADD = -L/usr/lib -lMagick++ -lMagickWand \
|
||||||
|
-lMagickCore -llcms -ltiff -lfreetype -ljpeg -llqr-1 \
|
||||||
|
-lglib-2.0 -lfontconfig -lXext -lSM -lICE -lX11 -lXt -lbz2 -lz \
|
||||||
|
-lm -lgomp -lpthread -lltdl -L$(top_builddir) \
|
||||||
|
$(am__empty)
|
||||||
|
|
||||||
|
### SOURCES
|
||||||
|
pix2jpg_la_SOURCES = \
|
||||||
|
pix2jpg.cpp \
|
||||||
|
pix2jpg.h
|
||||||
|
|
||||||
|
all: all-am
|
||||||
|
|
||||||
|
.SUFFIXES:
|
||||||
|
.SUFFIXES: .cpp .lo .o .obj
|
||||||
|
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
|
||||||
|
@for dep in $?; do \
|
||||||
|
case '$(am__configure_deps)' in \
|
||||||
|
*$$dep*) \
|
||||||
|
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
|
||||||
|
&& { if test -f $@; then exit 0; else break; fi; }; \
|
||||||
|
exit 1;; \
|
||||||
|
esac; \
|
||||||
|
done; \
|
||||||
|
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign extra/pix2jpg/Makefile'; \
|
||||||
|
$(am__cd) $(top_srcdir) && \
|
||||||
|
$(AUTOMAKE) --foreign extra/pix2jpg/Makefile
|
||||||
|
.PRECIOUS: Makefile
|
||||||
|
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||||
|
@case '$?' in \
|
||||||
|
*config.status*) \
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
|
||||||
|
*) \
|
||||||
|
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
|
||||||
|
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
|
||||||
|
esac;
|
||||||
|
|
||||||
|
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||||
|
|
||||||
|
$(top_srcdir)/configure: $(am__configure_deps)
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||||
|
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||||
|
$(am__aclocal_m4_deps):
|
||||||
|
install-extraLTLIBRARIES: $(extra_LTLIBRARIES)
|
||||||
|
@$(NORMAL_INSTALL)
|
||||||
|
test -z "$(extradir)" || $(MKDIR_P) "$(DESTDIR)$(extradir)"
|
||||||
|
@list='$(extra_LTLIBRARIES)'; test -n "$(extradir)" || list=; \
|
||||||
|
list2=; for p in $$list; do \
|
||||||
|
if test -f $$p; then \
|
||||||
|
list2="$$list2 $$p"; \
|
||||||
|
else :; fi; \
|
||||||
|
done; \
|
||||||
|
test -z "$$list2" || { \
|
||||||
|
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(extradir)'"; \
|
||||||
|
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(extradir)"; \
|
||||||
|
}
|
||||||
|
|
||||||
|
uninstall-extraLTLIBRARIES:
|
||||||
|
@$(NORMAL_UNINSTALL)
|
||||||
|
@list='$(extra_LTLIBRARIES)'; test -n "$(extradir)" || list=; \
|
||||||
|
for p in $$list; do \
|
||||||
|
$(am__strip_dir) \
|
||||||
|
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(extradir)/$$f'"; \
|
||||||
|
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(extradir)/$$f"; \
|
||||||
|
done
|
||||||
|
|
||||||
|
clean-extraLTLIBRARIES:
|
||||||
|
-test -z "$(extra_LTLIBRARIES)" || rm -f $(extra_LTLIBRARIES)
|
||||||
|
@list='$(extra_LTLIBRARIES)'; for p in $$list; do \
|
||||||
|
dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
|
||||||
|
test "$$dir" != "$$p" || dir=.; \
|
||||||
|
echo "rm -f \"$${dir}/so_locations\""; \
|
||||||
|
rm -f "$${dir}/so_locations"; \
|
||||||
|
done
|
||||||
|
pix2jpg.la: $(pix2jpg_la_OBJECTS) $(pix2jpg_la_DEPENDENCIES) $(EXTRA_pix2jpg_la_DEPENDENCIES)
|
||||||
|
$(pix2jpg_la_LINK) -rpath $(extradir) $(pix2jpg_la_OBJECTS) $(pix2jpg_la_LIBADD) $(LIBS)
|
||||||
|
|
||||||
|
mostlyclean-compile:
|
||||||
|
-rm -f *.$(OBJEXT)
|
||||||
|
|
||||||
|
distclean-compile:
|
||||||
|
-rm -f *.tab.c
|
||||||
|
|
||||||
|
include ./$(DEPDIR)/pix2jpg_la-pix2jpg.Plo
|
||||||
|
|
||||||
|
.cpp.o:
|
||||||
|
$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
|
||||||
|
$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||||
|
# source='$<' object='$@' libtool=no \
|
||||||
|
# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
|
||||||
|
# $(CXXCOMPILE) -c -o $@ $<
|
||||||
|
|
||||||
|
.cpp.obj:
|
||||||
|
$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
|
||||||
|
$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||||
|
# source='$<' object='$@' libtool=no \
|
||||||
|
# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
|
||||||
|
# $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
|
||||||
|
|
||||||
|
.cpp.lo:
|
||||||
|
$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
|
||||||
|
$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
|
||||||
|
# source='$<' object='$@' libtool=yes \
|
||||||
|
# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
|
||||||
|
# $(LTCXXCOMPILE) -c -o $@ $<
|
||||||
|
|
||||||
|
pix2jpg_la-pix2jpg.lo: pix2jpg.cpp
|
||||||
|
$(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pix2jpg_la_CXXFLAGS) $(CXXFLAGS) -MT pix2jpg_la-pix2jpg.lo -MD -MP -MF $(DEPDIR)/pix2jpg_la-pix2jpg.Tpo -c -o pix2jpg_la-pix2jpg.lo `test -f 'pix2jpg.cpp' || echo '$(srcdir)/'`pix2jpg.cpp
|
||||||
|
$(am__mv) $(DEPDIR)/pix2jpg_la-pix2jpg.Tpo $(DEPDIR)/pix2jpg_la-pix2jpg.Plo
|
||||||
|
# source='pix2jpg.cpp' object='pix2jpg_la-pix2jpg.lo' libtool=yes \
|
||||||
|
# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
|
||||||
|
# $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pix2jpg_la_CXXFLAGS) $(CXXFLAGS) -c -o pix2jpg_la-pix2jpg.lo `test -f 'pix2jpg.cpp' || echo '$(srcdir)/'`pix2jpg.cpp
|
||||||
|
|
||||||
|
mostlyclean-libtool:
|
||||||
|
-rm -f *.lo
|
||||||
|
|
||||||
|
clean-libtool:
|
||||||
|
-rm -rf .libs _libs
|
||||||
|
install-dist_extraDATA: $(dist_extra_DATA)
|
||||||
|
@$(NORMAL_INSTALL)
|
||||||
|
test -z "$(extradir)" || $(MKDIR_P) "$(DESTDIR)$(extradir)"
|
||||||
|
@list='$(dist_extra_DATA)'; test -n "$(extradir)" || list=; \
|
||||||
|
for p in $$list; do \
|
||||||
|
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
|
||||||
|
echo "$$d$$p"; \
|
||||||
|
done | $(am__base_list) | \
|
||||||
|
while read files; do \
|
||||||
|
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(extradir)'"; \
|
||||||
|
$(INSTALL_DATA) $$files "$(DESTDIR)$(extradir)" || exit $$?; \
|
||||||
|
done
|
||||||
|
|
||||||
|
uninstall-dist_extraDATA:
|
||||||
|
@$(NORMAL_UNINSTALL)
|
||||||
|
@list='$(dist_extra_DATA)'; test -n "$(extradir)" || list=; \
|
||||||
|
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
|
||||||
|
dir='$(DESTDIR)$(extradir)'; $(am__uninstall_files_from_dir)
|
||||||
|
|
||||||
|
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
|
||||||
|
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||||
|
unique=`for i in $$list; do \
|
||||||
|
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||||
|
done | \
|
||||||
|
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||||
|
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||||
|
mkid -fID $$unique
|
||||||
|
tags: TAGS
|
||||||
|
|
||||||
|
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||||
|
$(TAGS_FILES) $(LISP)
|
||||||
|
set x; \
|
||||||
|
here=`pwd`; \
|
||||||
|
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||||
|
unique=`for i in $$list; do \
|
||||||
|
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||||
|
done | \
|
||||||
|
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||||
|
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||||
|
shift; \
|
||||||
|
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
|
||||||
|
test -n "$$unique" || unique=$$empty_fix; \
|
||||||
|
if test $$# -gt 0; then \
|
||||||
|
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||||
|
"$$@" $$unique; \
|
||||||
|
else \
|
||||||
|
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||||
|
$$unique; \
|
||||||
|
fi; \
|
||||||
|
fi
|
||||||
|
ctags: CTAGS
|
||||||
|
CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||||
|
$(TAGS_FILES) $(LISP)
|
||||||
|
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||||
|
unique=`for i in $$list; do \
|
||||||
|
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||||
|
done | \
|
||||||
|
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||||
|
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||||
|
test -z "$(CTAGS_ARGS)$$unique" \
|
||||||
|
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
|
||||||
|
$$unique
|
||||||
|
|
||||||
|
GTAGS:
|
||||||
|
here=`$(am__cd) $(top_builddir) && pwd` \
|
||||||
|
&& $(am__cd) $(top_srcdir) \
|
||||||
|
&& gtags -i $(GTAGS_ARGS) "$$here"
|
||||||
|
|
||||||
|
distclean-tags:
|
||||||
|
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
|
||||||
|
|
||||||
|
distdir: $(DISTFILES)
|
||||||
|
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||||
|
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||||
|
list='$(DISTFILES)'; \
|
||||||
|
dist_files=`for file in $$list; do echo $$file; done | \
|
||||||
|
sed -e "s|^$$srcdirstrip/||;t" \
|
||||||
|
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
|
||||||
|
case $$dist_files in \
|
||||||
|
*/*) $(MKDIR_P) `echo "$$dist_files" | \
|
||||||
|
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
|
||||||
|
sort -u` ;; \
|
||||||
|
esac; \
|
||||||
|
for file in $$dist_files; do \
|
||||||
|
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
|
||||||
|
if test -d $$d/$$file; then \
|
||||||
|
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
|
||||||
|
if test -d "$(distdir)/$$file"; then \
|
||||||
|
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||||
|
fi; \
|
||||||
|
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
|
||||||
|
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
|
||||||
|
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||||
|
fi; \
|
||||||
|
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
|
||||||
|
else \
|
||||||
|
test -f "$(distdir)/$$file" \
|
||||||
|
|| cp -p $$d/$$file "$(distdir)/$$file" \
|
||||||
|
|| exit 1; \
|
||||||
|
fi; \
|
||||||
|
done
|
||||||
|
check-am: all-am
|
||||||
|
check: check-am
|
||||||
|
all-am: Makefile $(LTLIBRARIES) $(DATA) all-local
|
||||||
|
installdirs:
|
||||||
|
for dir in "$(DESTDIR)$(extradir)" "$(DESTDIR)$(extradir)"; do \
|
||||||
|
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
|
||||||
|
done
|
||||||
|
install: install-am
|
||||||
|
install-exec: install-exec-am
|
||||||
|
install-data: install-data-am
|
||||||
|
uninstall: uninstall-am
|
||||||
|
|
||||||
|
install-am: all-am
|
||||||
|
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
|
||||||
|
|
||||||
|
installcheck: installcheck-am
|
||||||
|
install-strip:
|
||||||
|
if test -z '$(STRIP)'; then \
|
||||||
|
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||||
|
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||||
|
install; \
|
||||||
|
else \
|
||||||
|
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||||
|
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||||
|
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
|
||||||
|
fi
|
||||||
|
mostlyclean-generic:
|
||||||
|
|
||||||
|
clean-generic:
|
||||||
|
|
||||||
|
distclean-generic:
|
||||||
|
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||||
|
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
|
||||||
|
|
||||||
|
maintainer-clean-generic:
|
||||||
|
@echo "This command is intended for maintainers to use"
|
||||||
|
@echo "it deletes files that may require special tools to rebuild."
|
||||||
|
clean: clean-am
|
||||||
|
|
||||||
|
clean-am: clean-extraLTLIBRARIES clean-generic clean-libtool \
|
||||||
|
clean-local mostlyclean-am
|
||||||
|
|
||||||
|
distclean: distclean-am
|
||||||
|
-rm -rf ./$(DEPDIR)
|
||||||
|
-rm -f Makefile
|
||||||
|
distclean-am: clean-am distclean-compile distclean-generic \
|
||||||
|
distclean-tags
|
||||||
|
|
||||||
|
dvi: dvi-am
|
||||||
|
|
||||||
|
dvi-am:
|
||||||
|
|
||||||
|
html: html-am
|
||||||
|
|
||||||
|
html-am:
|
||||||
|
|
||||||
|
info: info-am
|
||||||
|
|
||||||
|
info-am:
|
||||||
|
|
||||||
|
install-data-am: install-dist_extraDATA install-extraLTLIBRARIES
|
||||||
|
|
||||||
|
install-dvi: install-dvi-am
|
||||||
|
|
||||||
|
install-dvi-am:
|
||||||
|
|
||||||
|
install-exec-am:
|
||||||
|
|
||||||
|
install-html: install-html-am
|
||||||
|
|
||||||
|
install-html-am:
|
||||||
|
|
||||||
|
install-info: install-info-am
|
||||||
|
|
||||||
|
install-info-am:
|
||||||
|
|
||||||
|
install-man:
|
||||||
|
|
||||||
|
install-pdf: install-pdf-am
|
||||||
|
|
||||||
|
install-pdf-am:
|
||||||
|
|
||||||
|
install-ps: install-ps-am
|
||||||
|
|
||||||
|
install-ps-am:
|
||||||
|
|
||||||
|
installcheck-am:
|
||||||
|
|
||||||
|
maintainer-clean: maintainer-clean-am
|
||||||
|
-rm -rf ./$(DEPDIR)
|
||||||
|
-rm -f Makefile
|
||||||
|
maintainer-clean-am: distclean-am maintainer-clean-generic
|
||||||
|
|
||||||
|
mostlyclean: mostlyclean-am
|
||||||
|
|
||||||
|
mostlyclean-am: mostlyclean-compile mostlyclean-generic \
|
||||||
|
mostlyclean-libtool
|
||||||
|
|
||||||
|
pdf: pdf-am
|
||||||
|
|
||||||
|
pdf-am:
|
||||||
|
|
||||||
|
ps: ps-am
|
||||||
|
|
||||||
|
ps-am:
|
||||||
|
|
||||||
|
uninstall-am: uninstall-dist_extraDATA uninstall-extraLTLIBRARIES
|
||||||
|
|
||||||
|
.MAKE: install-am install-strip
|
||||||
|
|
||||||
|
.PHONY: CTAGS GTAGS all all-am all-local check check-am clean \
|
||||||
|
clean-extraLTLIBRARIES clean-generic clean-libtool clean-local \
|
||||||
|
ctags distclean distclean-compile distclean-generic \
|
||||||
|
distclean-libtool distclean-tags distdir dvi dvi-am html \
|
||||||
|
html-am info info-am install install-am install-data \
|
||||||
|
install-data-am install-dist_extraDATA install-dvi \
|
||||||
|
install-dvi-am install-exec install-exec-am \
|
||||||
|
install-extraLTLIBRARIES install-html install-html-am \
|
||||||
|
install-info install-info-am install-man install-pdf \
|
||||||
|
install-pdf-am install-ps install-ps-am install-strip \
|
||||||
|
installcheck installcheck-am installdirs maintainer-clean \
|
||||||
|
maintainer-clean-generic mostlyclean mostlyclean-compile \
|
||||||
|
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
|
||||||
|
tags uninstall uninstall-am uninstall-dist_extraDATA \
|
||||||
|
uninstall-extraLTLIBRARIES
|
||||||
|
|
||||||
|
|
||||||
|
# convenience symlinks
|
||||||
|
pix2jpg.pd_linux: pix2jpg.la
|
||||||
|
rm -f $@
|
||||||
|
test -f .libs/$@ && $(LN_S) .libs/$@ $@ || true
|
||||||
|
|
||||||
|
.PHONY: clean-conviencesymlink
|
||||||
|
|
||||||
|
clean-conviencesymlink:
|
||||||
|
rm -f pix2jpg.pd_linux
|
||||||
|
|
||||||
|
all-local:: pix2jpg.pd_linux
|
||||||
|
|
||||||
|
clean-local:: clean-conviencesymlink
|
||||||
|
|
||||||
|
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||||
|
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||||
|
.NOEXPORT:
|
56
externals/pix2jpg/Makefile.am
vendored
Normal file
56
externals/pix2jpg/Makefile.am
vendored
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
AUTOMAKE_OPTIONS = foreign
|
||||||
|
ACLOCAL_AMFLAGS = -I $(top_srcdir)/src/m4
|
||||||
|
AM_CPPFLAGS = -I$(top_srcdir)/src -I/usr/include/ImageMagick
|
||||||
|
EXTRA_DIST =
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
extradir=$(libdir)/pix2jpg
|
||||||
|
|
||||||
|
extra_LTLIBRARIES = pix2jpg.la
|
||||||
|
|
||||||
|
dist_extra_DATA = LICENSE.txt
|
||||||
|
dist_extra_DATA += pix2jpg-help.pd
|
||||||
|
|
||||||
|
|
||||||
|
## some default flags
|
||||||
|
pix2jpg_la_CXXFLAGS =
|
||||||
|
pix2jpg_la_LDFLAGS = -L/usr/lib -Wl,-Bsymbolic-functions -Wl,-z,relro -L/usr/lib/X11 -module -avoid-version -shared -shrext .@GEM_RTE_EXTENSION@
|
||||||
|
if WINDOWS
|
||||||
|
pix2jpg_la_LDFLAGS += -no-undefined
|
||||||
|
endif
|
||||||
|
pix2jpg_la_LIBADD =
|
||||||
|
|
||||||
|
# RTE flags
|
||||||
|
pix2jpg_la_CXXFLAGS += @GEM_RTE_CFLAGS@ @GEM_ARCH_CXXFLAGS@
|
||||||
|
pix2jpg_la_LIBADD += @GEM_RTE_LIBS@
|
||||||
|
|
||||||
|
pix2jpg_la_LDFLAGS += @GEM_ARCH_LDFLAGS@
|
||||||
|
|
||||||
|
# special flags for building externals
|
||||||
|
pix2jpg_la_CXXFLAGS += -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -pthread .@GEM_EXTERNAL_CFLAGS@
|
||||||
|
pix2jpg_la_LIBADD += -L/usr/lib -lMagick++ -lMagickWand -lMagickCore -llcms -ltiff -lfreetype -ljpeg -llqr-1 -lglib-2.0 -lfontconfig -lXext -lSM -lICE -lX11 -lXt -lbz2 -lz -lm -lgomp -lpthread -lltdl -L$(top_builddir) @GEM_EXTERNAL_LIBS@
|
||||||
|
|
||||||
|
|
||||||
|
# convenience symlinks
|
||||||
|
## uha, this is ugly
|
||||||
|
pix2jpg.@GEM_RTE_EXTENSION@: pix2jpg.la
|
||||||
|
rm -f $@
|
||||||
|
test -f .libs/$@ && $(LN_S) .libs/$@ $@ || true
|
||||||
|
|
||||||
|
.PHONY: clean-conviencesymlink
|
||||||
|
|
||||||
|
clean-conviencesymlink:
|
||||||
|
rm -f pix2jpg.@GEM_RTE_EXTENSION@
|
||||||
|
|
||||||
|
|
||||||
|
all-local:: pix2jpg.@GEM_RTE_EXTENSION@
|
||||||
|
|
||||||
|
clean-local:: clean-conviencesymlink
|
||||||
|
|
||||||
|
|
||||||
|
### SOURCES
|
||||||
|
pix2jpg_la_SOURCES = \
|
||||||
|
pix2jpg.cpp \
|
||||||
|
pix2jpg.h
|
||||||
|
|
770
externals/pix2jpg/Makefile.in
vendored
Normal file
770
externals/pix2jpg/Makefile.in
vendored
Normal file
|
@ -0,0 +1,770 @@
|
||||||
|
# Makefile.in generated by automake 1.11.3 from Makefile.am.
|
||||||
|
# @configure_input@
|
||||||
|
|
||||||
|
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
|
||||||
|
# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
|
||||||
|
# Foundation, Inc.
|
||||||
|
# This Makefile.in is free software; the Free Software Foundation
|
||||||
|
# gives unlimited permission to copy and/or distribute it,
|
||||||
|
# with or without modifications, as long as this notice is preserved.
|
||||||
|
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
||||||
|
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||||
|
# PARTICULAR PURPOSE.
|
||||||
|
|
||||||
|
@SET_MAKE@
|
||||||
|
|
||||||
|
|
||||||
|
VPATH = @srcdir@
|
||||||
|
pkgdatadir = $(datadir)/@PACKAGE@
|
||||||
|
pkgincludedir = $(includedir)/@PACKAGE@
|
||||||
|
pkglibdir = $(libdir)/@PACKAGE@
|
||||||
|
pkglibexecdir = $(libexecdir)/@PACKAGE@
|
||||||
|
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
|
||||||
|
install_sh_DATA = $(install_sh) -c -m 644
|
||||||
|
install_sh_PROGRAM = $(install_sh) -c
|
||||||
|
install_sh_SCRIPT = $(install_sh) -c
|
||||||
|
INSTALL_HEADER = $(INSTALL_DATA)
|
||||||
|
transform = $(program_transform_name)
|
||||||
|
NORMAL_INSTALL = :
|
||||||
|
PRE_INSTALL = :
|
||||||
|
POST_INSTALL = :
|
||||||
|
NORMAL_UNINSTALL = :
|
||||||
|
PRE_UNINSTALL = :
|
||||||
|
POST_UNINSTALL = :
|
||||||
|
build_triplet = @build@
|
||||||
|
host_triplet = @host@
|
||||||
|
@WINDOWS_TRUE@am__append_1 = -no-undefined
|
||||||
|
subdir = extra/pix2jpg
|
||||||
|
DIST_COMMON = $(dist_extra_DATA) $(srcdir)/Makefile.am \
|
||||||
|
$(srcdir)/Makefile.in
|
||||||
|
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||||
|
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_gl.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_check_glu.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_check_glut.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_compiler_vendor.m4 \
|
||||||
|
$(top_srcdir)/m4/ax_pthread.m4 $(top_srcdir)/m4/gem.m4 \
|
||||||
|
$(top_srcdir)/m4/iem_ftgl.m4 $(top_srcdir)/m4/iem_opengl.m4 \
|
||||||
|
$(top_srcdir)/m4/iem_operatingsystem.m4 \
|
||||||
|
$(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/libtool.m4 \
|
||||||
|
$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
|
||||||
|
$(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
|
||||||
|
$(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac
|
||||||
|
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||||
|
$(ACLOCAL_M4)
|
||||||
|
mkinstalldirs = $(install_sh) -d
|
||||||
|
CONFIG_HEADER = $(top_builddir)/src/config.h
|
||||||
|
CONFIG_CLEAN_FILES =
|
||||||
|
CONFIG_CLEAN_VPATH_FILES =
|
||||||
|
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
|
||||||
|
am__vpath_adj = case $$p in \
|
||||||
|
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
|
||||||
|
*) f=$$p;; \
|
||||||
|
esac;
|
||||||
|
am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
|
||||||
|
am__install_max = 40
|
||||||
|
am__nobase_strip_setup = \
|
||||||
|
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
|
||||||
|
am__nobase_strip = \
|
||||||
|
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
|
||||||
|
am__nobase_list = $(am__nobase_strip_setup); \
|
||||||
|
for p in $$list; do echo "$$p $$p"; done | \
|
||||||
|
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
|
||||||
|
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
|
||||||
|
if (++n[$$2] == $(am__install_max)) \
|
||||||
|
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
|
||||||
|
END { for (dir in files) print dir, files[dir] }'
|
||||||
|
am__base_list = \
|
||||||
|
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
|
||||||
|
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
|
||||||
|
am__uninstall_files_from_dir = { \
|
||||||
|
test -z "$$files" \
|
||||||
|
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|
||||||
|
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
|
||||||
|
$(am__cd) "$$dir" && rm -f $$files; }; \
|
||||||
|
}
|
||||||
|
am__installdirs = "$(DESTDIR)$(extradir)" "$(DESTDIR)$(extradir)"
|
||||||
|
LTLIBRARIES = $(extra_LTLIBRARIES)
|
||||||
|
pix2jpg_la_DEPENDENCIES =
|
||||||
|
am_pix2jpg_la_OBJECTS = pix2jpg_la-pix2jpg.lo
|
||||||
|
pix2jpg_la_OBJECTS = $(am_pix2jpg_la_OBJECTS)
|
||||||
|
pix2jpg_la_LINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) \
|
||||||
|
$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(pix2jpg_la_CXXFLAGS) \
|
||||||
|
$(CXXFLAGS) $(pix2jpg_la_LDFLAGS) $(LDFLAGS) -o $@
|
||||||
|
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src
|
||||||
|
depcomp = $(SHELL) $(top_srcdir)/depcomp
|
||||||
|
am__depfiles_maybe = depfiles
|
||||||
|
am__mv = mv -f
|
||||||
|
CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||||
|
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
|
||||||
|
LTCXXCOMPILE = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||||
|
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
|
||||||
|
CXXLD = $(CXX)
|
||||||
|
CXXLINK = $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=link $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) \
|
||||||
|
$(LDFLAGS) -o $@
|
||||||
|
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
|
||||||
|
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||||
|
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
|
||||||
|
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
|
||||||
|
CCLD = $(CC)
|
||||||
|
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
|
||||||
|
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
|
||||||
|
$(LDFLAGS) -o $@
|
||||||
|
SOURCES = $(pix2jpg_la_SOURCES)
|
||||||
|
DIST_SOURCES = $(pix2jpg_la_SOURCES)
|
||||||
|
DATA = $(dist_extra_DATA)
|
||||||
|
ETAGS = etags
|
||||||
|
CTAGS = ctags
|
||||||
|
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
|
||||||
|
ACLOCAL = @ACLOCAL@
|
||||||
|
AGL_CFLAGS = @AGL_CFLAGS@
|
||||||
|
AGL_LIBS = @AGL_LIBS@
|
||||||
|
AMTAR = @AMTAR@
|
||||||
|
AR = @AR@
|
||||||
|
AS = @AS@
|
||||||
|
AUTOCONF = @AUTOCONF@
|
||||||
|
AUTOHEADER = @AUTOHEADER@
|
||||||
|
AUTOMAKE = @AUTOMAKE@
|
||||||
|
AWK = @AWK@
|
||||||
|
CC = @CC@
|
||||||
|
CCDEPMODE = @CCDEPMODE@
|
||||||
|
CFLAGS = @CFLAGS@
|
||||||
|
CPP = @CPP@
|
||||||
|
CPPFLAGS = @CPPFLAGS@
|
||||||
|
CXX = @CXX@
|
||||||
|
CXXCPP = @CXXCPP@
|
||||||
|
CXXDEPMODE = @CXXDEPMODE@
|
||||||
|
CXXFLAGS = @CXXFLAGS@
|
||||||
|
CYGPATH_W = @CYGPATH_W@
|
||||||
|
DEFINES = @DEFINES@
|
||||||
|
DEFS = @DEFS@
|
||||||
|
DEPDIR = @DEPDIR@
|
||||||
|
DLLTOOL = @DLLTOOL@
|
||||||
|
DSYMUTIL = @DSYMUTIL@
|
||||||
|
DUMPBIN = @DUMPBIN@
|
||||||
|
ECHO_C = @ECHO_C@
|
||||||
|
ECHO_N = @ECHO_N@
|
||||||
|
ECHO_T = @ECHO_T@
|
||||||
|
EGREP = @EGREP@
|
||||||
|
EXEEXT = @EXEEXT@
|
||||||
|
EXT = @EXT@
|
||||||
|
FGREP = @FGREP@
|
||||||
|
GEM_ARCH_CXXFLAGS = @GEM_ARCH_CXXFLAGS@
|
||||||
|
GEM_ARCH_LDFLAGS = @GEM_ARCH_LDFLAGS@
|
||||||
|
GEM_CFLAGS = @GEM_CFLAGS@
|
||||||
|
GEM_CPPFLAGS = @GEM_CPPFLAGS@
|
||||||
|
GEM_CXXFLAGS = @GEM_CXXFLAGS@
|
||||||
|
GEM_DEFAULT_WINDOW = @GEM_DEFAULT_WINDOW@
|
||||||
|
GEM_EXTERNAL_CFLAGS = @GEM_EXTERNAL_CFLAGS@
|
||||||
|
GEM_EXTERNAL_CPPFLAGS = @GEM_EXTERNAL_CPPFLAGS@
|
||||||
|
GEM_EXTERNAL_LIBS = @GEM_EXTERNAL_LIBS@
|
||||||
|
GEM_FRAMEWORK_AGL = @GEM_FRAMEWORK_AGL@
|
||||||
|
GEM_FRAMEWORK_CARBON = @GEM_FRAMEWORK_CARBON@
|
||||||
|
GEM_FRAMEWORK_COCOA = @GEM_FRAMEWORK_COCOA@
|
||||||
|
GEM_FRAMEWORK_QUICKTIME = @GEM_FRAMEWORK_QUICKTIME@
|
||||||
|
GEM_LIBS = @GEM_LIBS@
|
||||||
|
GEM_LIB_ASSIMP_CFLAGS = @GEM_LIB_ASSIMP_CFLAGS@
|
||||||
|
GEM_LIB_ASSIMP_LIBS = @GEM_LIB_ASSIMP_LIBS@
|
||||||
|
GEM_LIB_AVIFILE_CFLAGS = @GEM_LIB_AVIFILE_CFLAGS@
|
||||||
|
GEM_LIB_AVIFILE_LIBS = @GEM_LIB_AVIFILE_LIBS@
|
||||||
|
GEM_LIB_FTGL_CFLAGS = @GEM_LIB_FTGL_CFLAGS@
|
||||||
|
GEM_LIB_FTGL_LIBS = @GEM_LIB_FTGL_LIBS@
|
||||||
|
GEM_LIB_GLEW_CFLAGS = @GEM_LIB_GLEW_CFLAGS@
|
||||||
|
GEM_LIB_GLEW_LIBS = @GEM_LIB_GLEW_LIBS@
|
||||||
|
GEM_LIB_GMERLIN_AVDEC_CFLAGS = @GEM_LIB_GMERLIN_AVDEC_CFLAGS@
|
||||||
|
GEM_LIB_GMERLIN_AVDEC_LIBS = @GEM_LIB_GMERLIN_AVDEC_LIBS@
|
||||||
|
GEM_LIB_IMAGEMAGICK___CFLAGS = @GEM_LIB_IMAGEMAGICK___CFLAGS@
|
||||||
|
GEM_LIB_IMAGEMAGICK___LIBS = @GEM_LIB_IMAGEMAGICK___LIBS@
|
||||||
|
GEM_LIB_JPEG_CFLAGS = @GEM_LIB_JPEG_CFLAGS@
|
||||||
|
GEM_LIB_JPEG_LIBS = @GEM_LIB_JPEG_LIBS@
|
||||||
|
GEM_LIB_LIBDC1394_2_CFLAGS = @GEM_LIB_LIBDC1394_2_CFLAGS@
|
||||||
|
GEM_LIB_LIBDC1394_2_LIBS = @GEM_LIB_LIBDC1394_2_LIBS@
|
||||||
|
GEM_LIB_LIBDV_CFLAGS = @GEM_LIB_LIBDV_CFLAGS@
|
||||||
|
GEM_LIB_LIBDV_LIBS = @GEM_LIB_LIBDV_LIBS@
|
||||||
|
GEM_LIB_LIBIEC61883_CFLAGS = @GEM_LIB_LIBIEC61883_CFLAGS@
|
||||||
|
GEM_LIB_LIBIEC61883_LIBS = @GEM_LIB_LIBIEC61883_LIBS@
|
||||||
|
GEM_LIB_LIBMPEG3_CFLAGS = @GEM_LIB_LIBMPEG3_CFLAGS@
|
||||||
|
GEM_LIB_LIBMPEG3_LIBS = @GEM_LIB_LIBMPEG3_LIBS@
|
||||||
|
GEM_LIB_LIBQUICKTIME_CFLAGS = @GEM_LIB_LIBQUICKTIME_CFLAGS@
|
||||||
|
GEM_LIB_LIBQUICKTIME_LIBS = @GEM_LIB_LIBQUICKTIME_LIBS@
|
||||||
|
GEM_LIB_LIBRAW1394_CFLAGS = @GEM_LIB_LIBRAW1394_CFLAGS@
|
||||||
|
GEM_LIB_LIBRAW1394_LIBS = @GEM_LIB_LIBRAW1394_LIBS@
|
||||||
|
GEM_LIB_LIBUNICAP_CFLAGS = @GEM_LIB_LIBUNICAP_CFLAGS@
|
||||||
|
GEM_LIB_LIBUNICAP_LIBS = @GEM_LIB_LIBUNICAP_LIBS@
|
||||||
|
GEM_LIB_LIBV4L1_CFLAGS = @GEM_LIB_LIBV4L1_CFLAGS@
|
||||||
|
GEM_LIB_LIBV4L1_LIBS = @GEM_LIB_LIBV4L1_LIBS@
|
||||||
|
GEM_LIB_LIBV4L2_CFLAGS = @GEM_LIB_LIBV4L2_CFLAGS@
|
||||||
|
GEM_LIB_LIBV4L2_LIBS = @GEM_LIB_LIBV4L2_LIBS@
|
||||||
|
GEM_LIB_LIBVLC_CFLAGS = @GEM_LIB_LIBVLC_CFLAGS@
|
||||||
|
GEM_LIB_LIBVLC_LIBS = @GEM_LIB_LIBVLC_LIBS@
|
||||||
|
GEM_LIB_LQT_CFLAGS = @GEM_LIB_LQT_CFLAGS@
|
||||||
|
GEM_LIB_LQT_LIBS = @GEM_LIB_LQT_LIBS@
|
||||||
|
GEM_LIB_MAGICKCORE_CFLAGS = @GEM_LIB_MAGICKCORE_CFLAGS@
|
||||||
|
GEM_LIB_MAGICKCORE_LIBS = @GEM_LIB_MAGICKCORE_LIBS@
|
||||||
|
GEM_LIB_MPEG_CFLAGS = @GEM_LIB_MPEG_CFLAGS@
|
||||||
|
GEM_LIB_MPEG_LIBS = @GEM_LIB_MPEG_LIBS@
|
||||||
|
GEM_LIB_SDL_CFLAGS = @GEM_LIB_SDL_CFLAGS@
|
||||||
|
GEM_LIB_SDL_LIBS = @GEM_LIB_SDL_LIBS@
|
||||||
|
GEM_LIB_TIFF_CFLAGS = @GEM_LIB_TIFF_CFLAGS@
|
||||||
|
GEM_LIB_TIFF_LIBS = @GEM_LIB_TIFF_LIBS@
|
||||||
|
GEM_LIB_VFW32_CFLAGS = @GEM_LIB_VFW32_CFLAGS@
|
||||||
|
GEM_LIB_VFW32_LIBS = @GEM_LIB_VFW32_LIBS@
|
||||||
|
GEM_PTHREAD_CFLAGS = @GEM_PTHREAD_CFLAGS@
|
||||||
|
GEM_PTHREAD_LIBS = @GEM_PTHREAD_LIBS@
|
||||||
|
GEM_RTE = @GEM_RTE@
|
||||||
|
GEM_RTE_CFLAGS = @GEM_RTE_CFLAGS@
|
||||||
|
GEM_RTE_EXTENSION = @GEM_RTE_EXTENSION@
|
||||||
|
GEM_RTE_LIBS = @GEM_RTE_LIBS@
|
||||||
|
GEM_TARGETS = @GEM_TARGETS@
|
||||||
|
GLUT_CFLAGS = @GLUT_CFLAGS@
|
||||||
|
GLUT_LIBS = @GLUT_LIBS@
|
||||||
|
GLU_CFLAGS = @GLU_CFLAGS@
|
||||||
|
GLU_LIBS = @GLU_LIBS@
|
||||||
|
GLX_CFLAGS = @GLX_CFLAGS@
|
||||||
|
GLX_LIBS = @GLX_LIBS@
|
||||||
|
GL_CFLAGS = @GL_CFLAGS@
|
||||||
|
GL_LIBS = @GL_LIBS@
|
||||||
|
GREP = @GREP@
|
||||||
|
INCLUDES = @INCLUDES@
|
||||||
|
INSTALL = @INSTALL@
|
||||||
|
INSTALL_DATA = @INSTALL_DATA@
|
||||||
|
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||||
|
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||||
|
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
|
||||||
|
LD = @LD@
|
||||||
|
LDFLAGS = @LDFLAGS@
|
||||||
|
LIBOBJS = @LIBOBJS@
|
||||||
|
LIBS = @LIBS@
|
||||||
|
LIBTOOL = @LIBTOOL@
|
||||||
|
LIPO = @LIPO@
|
||||||
|
LN_S = @LN_S@
|
||||||
|
LTLIBOBJS = @LTLIBOBJS@
|
||||||
|
MAKEDEP_FLAGS = @MAKEDEP_FLAGS@
|
||||||
|
MAKEINFO = @MAKEINFO@
|
||||||
|
MANIFEST_TOOL = @MANIFEST_TOOL@
|
||||||
|
MKDIR_P = @MKDIR_P@
|
||||||
|
NM = @NM@
|
||||||
|
NMEDIT = @NMEDIT@
|
||||||
|
OBJC = @OBJC@
|
||||||
|
OBJCDEPMODE = @OBJCDEPMODE@
|
||||||
|
OBJCFLAGS = @OBJCFLAGS@
|
||||||
|
OBJCXX = @OBJCXX@
|
||||||
|
OBJCXXFLAGS = @OBJCXXFLAGS@
|
||||||
|
OBJDUMP = @OBJDUMP@
|
||||||
|
OBJEXT = @OBJEXT@
|
||||||
|
OTOOL = @OTOOL@
|
||||||
|
OTOOL64 = @OTOOL64@
|
||||||
|
PACKAGE = @PACKAGE@
|
||||||
|
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
|
||||||
|
PACKAGE_NAME = @PACKAGE_NAME@
|
||||||
|
PACKAGE_STRING = @PACKAGE_STRING@
|
||||||
|
PACKAGE_TARNAME = @PACKAGE_TARNAME@
|
||||||
|
PACKAGE_URL = @PACKAGE_URL@
|
||||||
|
PACKAGE_VERSION = @PACKAGE_VERSION@
|
||||||
|
PATH_SEPARATOR = @PATH_SEPARATOR@
|
||||||
|
PKG_ASSIMP_CFLAGS = @PKG_ASSIMP_CFLAGS@
|
||||||
|
PKG_ASSIMP_LIBS = @PKG_ASSIMP_LIBS@
|
||||||
|
PKG_AVIFILE_CFLAGS = @PKG_AVIFILE_CFLAGS@
|
||||||
|
PKG_AVIFILE_LIBS = @PKG_AVIFILE_LIBS@
|
||||||
|
PKG_CFLAGS = @PKG_CFLAGS@
|
||||||
|
PKG_CONFIG = @PKG_CONFIG@
|
||||||
|
PKG_FTGL_CFLAGS = @PKG_FTGL_CFLAGS@
|
||||||
|
PKG_FTGL_LIBS = @PKG_FTGL_LIBS@
|
||||||
|
PKG_GLEW_CFLAGS = @PKG_GLEW_CFLAGS@
|
||||||
|
PKG_GLEW_LIBS = @PKG_GLEW_LIBS@
|
||||||
|
PKG_GMERLIN_AVDEC_CFLAGS = @PKG_GMERLIN_AVDEC_CFLAGS@
|
||||||
|
PKG_GMERLIN_AVDEC_LIBS = @PKG_GMERLIN_AVDEC_LIBS@
|
||||||
|
PKG_IMAGEMAGICK___CFLAGS = @PKG_IMAGEMAGICK___CFLAGS@
|
||||||
|
PKG_IMAGEMAGICK___LIBS = @PKG_IMAGEMAGICK___LIBS@
|
||||||
|
PKG_JPEG_CFLAGS = @PKG_JPEG_CFLAGS@
|
||||||
|
PKG_JPEG_LIBS = @PKG_JPEG_LIBS@
|
||||||
|
PKG_LIBDC1394_2_CFLAGS = @PKG_LIBDC1394_2_CFLAGS@
|
||||||
|
PKG_LIBDC1394_2_LIBS = @PKG_LIBDC1394_2_LIBS@
|
||||||
|
PKG_LIBDV_CFLAGS = @PKG_LIBDV_CFLAGS@
|
||||||
|
PKG_LIBDV_LIBS = @PKG_LIBDV_LIBS@
|
||||||
|
PKG_LIBIEC61883_CFLAGS = @PKG_LIBIEC61883_CFLAGS@
|
||||||
|
PKG_LIBIEC61883_LIBS = @PKG_LIBIEC61883_LIBS@
|
||||||
|
PKG_LIBMPEG3_CFLAGS = @PKG_LIBMPEG3_CFLAGS@
|
||||||
|
PKG_LIBMPEG3_LIBS = @PKG_LIBMPEG3_LIBS@
|
||||||
|
PKG_LIBQUICKTIME_CFLAGS = @PKG_LIBQUICKTIME_CFLAGS@
|
||||||
|
PKG_LIBQUICKTIME_LIBS = @PKG_LIBQUICKTIME_LIBS@
|
||||||
|
PKG_LIBRAW1394_CFLAGS = @PKG_LIBRAW1394_CFLAGS@
|
||||||
|
PKG_LIBRAW1394_LIBS = @PKG_LIBRAW1394_LIBS@
|
||||||
|
PKG_LIBS = @PKG_LIBS@
|
||||||
|
PKG_LIBUNICAP_CFLAGS = @PKG_LIBUNICAP_CFLAGS@
|
||||||
|
PKG_LIBUNICAP_LIBS = @PKG_LIBUNICAP_LIBS@
|
||||||
|
PKG_LIBV4L1_CFLAGS = @PKG_LIBV4L1_CFLAGS@
|
||||||
|
PKG_LIBV4L1_LIBS = @PKG_LIBV4L1_LIBS@
|
||||||
|
PKG_LIBV4L2_CFLAGS = @PKG_LIBV4L2_CFLAGS@
|
||||||
|
PKG_LIBV4L2_LIBS = @PKG_LIBV4L2_LIBS@
|
||||||
|
PKG_LIBVLC_CFLAGS = @PKG_LIBVLC_CFLAGS@
|
||||||
|
PKG_LIBVLC_LIBS = @PKG_LIBVLC_LIBS@
|
||||||
|
PKG_LQT_CFLAGS = @PKG_LQT_CFLAGS@
|
||||||
|
PKG_LQT_LIBS = @PKG_LQT_LIBS@
|
||||||
|
PKG_MAGICKCORE_CFLAGS = @PKG_MAGICKCORE_CFLAGS@
|
||||||
|
PKG_MAGICKCORE_LIBS = @PKG_MAGICKCORE_LIBS@
|
||||||
|
PKG_MPEG_CFLAGS = @PKG_MPEG_CFLAGS@
|
||||||
|
PKG_MPEG_LIBS = @PKG_MPEG_LIBS@
|
||||||
|
PKG_SDL_CFLAGS = @PKG_SDL_CFLAGS@
|
||||||
|
PKG_SDL_LIBS = @PKG_SDL_LIBS@
|
||||||
|
PKG_TIFF_CFLAGS = @PKG_TIFF_CFLAGS@
|
||||||
|
PKG_TIFF_LIBS = @PKG_TIFF_LIBS@
|
||||||
|
PKG_VFW32_CFLAGS = @PKG_VFW32_CFLAGS@
|
||||||
|
PKG_VFW32_LIBS = @PKG_VFW32_LIBS@
|
||||||
|
PTHREAD_CC = @PTHREAD_CC@
|
||||||
|
PTHREAD_CFLAGS = @PTHREAD_CFLAGS@
|
||||||
|
PTHREAD_LIBS = @PTHREAD_LIBS@
|
||||||
|
RANLIB = @RANLIB@
|
||||||
|
SED = @SED@
|
||||||
|
SET_MAKE = @SET_MAKE@
|
||||||
|
SHELL = @SHELL@
|
||||||
|
STRIP = @STRIP@
|
||||||
|
VERSION = @VERSION@
|
||||||
|
XMKMF = @XMKMF@
|
||||||
|
X_CFLAGS = @X_CFLAGS@
|
||||||
|
X_EXTRA_LIBS = @X_EXTRA_LIBS@
|
||||||
|
X_LIBS = @X_LIBS@
|
||||||
|
X_PRE_LIBS = @X_PRE_LIBS@
|
||||||
|
abs_builddir = @abs_builddir@
|
||||||
|
abs_srcdir = @abs_srcdir@
|
||||||
|
abs_top_builddir = @abs_top_builddir@
|
||||||
|
abs_top_srcdir = @abs_top_srcdir@
|
||||||
|
ac_ct_AR = @ac_ct_AR@
|
||||||
|
ac_ct_CC = @ac_ct_CC@
|
||||||
|
ac_ct_CXX = @ac_ct_CXX@
|
||||||
|
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
|
||||||
|
ac_ct_OBJC = @ac_ct_OBJC@
|
||||||
|
ac_ct_OBJCXX = @ac_ct_OBJCXX@
|
||||||
|
am__include = @am__include@
|
||||||
|
am__leading_dot = @am__leading_dot@
|
||||||
|
am__quote = @am__quote@
|
||||||
|
am__tar = @am__tar@
|
||||||
|
am__untar = @am__untar@
|
||||||
|
ax_pthread_config = @ax_pthread_config@
|
||||||
|
bindir = @bindir@
|
||||||
|
build = @build@
|
||||||
|
build_alias = @build_alias@
|
||||||
|
build_cpu = @build_cpu@
|
||||||
|
build_os = @build_os@
|
||||||
|
build_vendor = @build_vendor@
|
||||||
|
builddir = @builddir@
|
||||||
|
datadir = @datadir@
|
||||||
|
datarootdir = @datarootdir@
|
||||||
|
docdir = @docdir@
|
||||||
|
dvidir = @dvidir@
|
||||||
|
exec_prefix = @exec_prefix@
|
||||||
|
host = @host@
|
||||||
|
host_alias = @host_alias@
|
||||||
|
host_cpu = @host_cpu@
|
||||||
|
host_os = @host_os@
|
||||||
|
host_vendor = @host_vendor@
|
||||||
|
htmldir = @htmldir@
|
||||||
|
includedir = @includedir@
|
||||||
|
infodir = @infodir@
|
||||||
|
install_sh = @install_sh@
|
||||||
|
libdir = @libdir@
|
||||||
|
libexecdir = @libexecdir@
|
||||||
|
localedir = @localedir@
|
||||||
|
localstatedir = @localstatedir@
|
||||||
|
mandir = @mandir@
|
||||||
|
mkdir_p = @mkdir_p@
|
||||||
|
oldincludedir = @oldincludedir@
|
||||||
|
pdfdir = @pdfdir@
|
||||||
|
prefix = @prefix@
|
||||||
|
program_transform_name = @program_transform_name@
|
||||||
|
psdir = @psdir@
|
||||||
|
sbindir = @sbindir@
|
||||||
|
sharedstatedir = @sharedstatedir@
|
||||||
|
srcdir = @srcdir@
|
||||||
|
subdirs = @subdirs@
|
||||||
|
sysconfdir = @sysconfdir@
|
||||||
|
target_alias = @target_alias@
|
||||||
|
top_build_prefix = @top_build_prefix@
|
||||||
|
top_builddir = @top_builddir@
|
||||||
|
top_srcdir = @top_srcdir@
|
||||||
|
AUTOMAKE_OPTIONS = foreign
|
||||||
|
ACLOCAL_AMFLAGS = -I $(top_srcdir)/src/m4
|
||||||
|
AM_CPPFLAGS = -I$(top_srcdir)/src -I/usr/include/ImageMagick
|
||||||
|
EXTRA_DIST =
|
||||||
|
extradir = $(libdir)/pix2jpg
|
||||||
|
extra_LTLIBRARIES = pix2jpg.la
|
||||||
|
dist_extra_DATA = LICENSE.txt pix2jpg-help.pd
|
||||||
|
|
||||||
|
# RTE flags
|
||||||
|
|
||||||
|
# special flags for building externals
|
||||||
|
pix2jpg_la_CXXFLAGS = @GEM_RTE_CFLAGS@ @GEM_ARCH_CXXFLAGS@ -g -O2 \
|
||||||
|
-fstack-protector --param=ssp-buffer-size=4 -Wformat \
|
||||||
|
-Wformat-security -pthread .@GEM_EXTERNAL_CFLAGS@
|
||||||
|
pix2jpg_la_LDFLAGS = -L/usr/lib -Wl,-Bsymbolic-functions -Wl,-z,relro \
|
||||||
|
-L/usr/lib/X11 -module -avoid-version -shared -shrext \
|
||||||
|
.@GEM_RTE_EXTENSION@ $(am__append_1) @GEM_ARCH_LDFLAGS@
|
||||||
|
pix2jpg_la_LIBADD = @GEM_RTE_LIBS@ -L/usr/lib -lMagick++ -lMagickWand \
|
||||||
|
-lMagickCore -llcms -ltiff -lfreetype -ljpeg -llqr-1 \
|
||||||
|
-lglib-2.0 -lfontconfig -lXext -lSM -lICE -lX11 -lXt -lbz2 -lz \
|
||||||
|
-lm -lgomp -lpthread -lltdl -L$(top_builddir) \
|
||||||
|
@GEM_EXTERNAL_LIBS@ $(am__empty)
|
||||||
|
|
||||||
|
### SOURCES
|
||||||
|
pix2jpg_la_SOURCES = \
|
||||||
|
pix2jpg.cpp \
|
||||||
|
pix2jpg.h
|
||||||
|
|
||||||
|
all: all-am
|
||||||
|
|
||||||
|
.SUFFIXES:
|
||||||
|
.SUFFIXES: .cpp .lo .o .obj
|
||||||
|
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
|
||||||
|
@for dep in $?; do \
|
||||||
|
case '$(am__configure_deps)' in \
|
||||||
|
*$$dep*) \
|
||||||
|
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
|
||||||
|
&& { if test -f $@; then exit 0; else break; fi; }; \
|
||||||
|
exit 1;; \
|
||||||
|
esac; \
|
||||||
|
done; \
|
||||||
|
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign extra/pix2jpg/Makefile'; \
|
||||||
|
$(am__cd) $(top_srcdir) && \
|
||||||
|
$(AUTOMAKE) --foreign extra/pix2jpg/Makefile
|
||||||
|
.PRECIOUS: Makefile
|
||||||
|
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||||
|
@case '$?' in \
|
||||||
|
*config.status*) \
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
|
||||||
|
*) \
|
||||||
|
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
|
||||||
|
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
|
||||||
|
esac;
|
||||||
|
|
||||||
|
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||||
|
|
||||||
|
$(top_srcdir)/configure: $(am__configure_deps)
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||||
|
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
|
||||||
|
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
|
||||||
|
$(am__aclocal_m4_deps):
|
||||||
|
install-extraLTLIBRARIES: $(extra_LTLIBRARIES)
|
||||||
|
@$(NORMAL_INSTALL)
|
||||||
|
test -z "$(extradir)" || $(MKDIR_P) "$(DESTDIR)$(extradir)"
|
||||||
|
@list='$(extra_LTLIBRARIES)'; test -n "$(extradir)" || list=; \
|
||||||
|
list2=; for p in $$list; do \
|
||||||
|
if test -f $$p; then \
|
||||||
|
list2="$$list2 $$p"; \
|
||||||
|
else :; fi; \
|
||||||
|
done; \
|
||||||
|
test -z "$$list2" || { \
|
||||||
|
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(extradir)'"; \
|
||||||
|
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(extradir)"; \
|
||||||
|
}
|
||||||
|
|
||||||
|
uninstall-extraLTLIBRARIES:
|
||||||
|
@$(NORMAL_UNINSTALL)
|
||||||
|
@list='$(extra_LTLIBRARIES)'; test -n "$(extradir)" || list=; \
|
||||||
|
for p in $$list; do \
|
||||||
|
$(am__strip_dir) \
|
||||||
|
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(extradir)/$$f'"; \
|
||||||
|
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(extradir)/$$f"; \
|
||||||
|
done
|
||||||
|
|
||||||
|
clean-extraLTLIBRARIES:
|
||||||
|
-test -z "$(extra_LTLIBRARIES)" || rm -f $(extra_LTLIBRARIES)
|
||||||
|
@list='$(extra_LTLIBRARIES)'; for p in $$list; do \
|
||||||
|
dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
|
||||||
|
test "$$dir" != "$$p" || dir=.; \
|
||||||
|
echo "rm -f \"$${dir}/so_locations\""; \
|
||||||
|
rm -f "$${dir}/so_locations"; \
|
||||||
|
done
|
||||||
|
pix2jpg.la: $(pix2jpg_la_OBJECTS) $(pix2jpg_la_DEPENDENCIES) $(EXTRA_pix2jpg_la_DEPENDENCIES)
|
||||||
|
$(pix2jpg_la_LINK) -rpath $(extradir) $(pix2jpg_la_OBJECTS) $(pix2jpg_la_LIBADD) $(LIBS)
|
||||||
|
|
||||||
|
mostlyclean-compile:
|
||||||
|
-rm -f *.$(OBJEXT)
|
||||||
|
|
||||||
|
distclean-compile:
|
||||||
|
-rm -f *.tab.c
|
||||||
|
|
||||||
|
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pix2jpg_la-pix2jpg.Plo@am__quote@
|
||||||
|
|
||||||
|
.cpp.o:
|
||||||
|
@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
|
||||||
|
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||||
|
@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ $<
|
||||||
|
|
||||||
|
.cpp.obj:
|
||||||
|
@am__fastdepCXX_TRUE@ $(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
|
||||||
|
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||||
|
@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
|
||||||
|
|
||||||
|
.cpp.lo:
|
||||||
|
@am__fastdepCXX_TRUE@ $(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
|
||||||
|
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||||
|
@am__fastdepCXX_FALSE@ $(LTCXXCOMPILE) -c -o $@ $<
|
||||||
|
|
||||||
|
pix2jpg_la-pix2jpg.lo: pix2jpg.cpp
|
||||||
|
@am__fastdepCXX_TRUE@ $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pix2jpg_la_CXXFLAGS) $(CXXFLAGS) -MT pix2jpg_la-pix2jpg.lo -MD -MP -MF $(DEPDIR)/pix2jpg_la-pix2jpg.Tpo -c -o pix2jpg_la-pix2jpg.lo `test -f 'pix2jpg.cpp' || echo '$(srcdir)/'`pix2jpg.cpp
|
||||||
|
@am__fastdepCXX_TRUE@ $(am__mv) $(DEPDIR)/pix2jpg_la-pix2jpg.Tpo $(DEPDIR)/pix2jpg_la-pix2jpg.Plo
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='pix2jpg.cpp' object='pix2jpg_la-pix2jpg.lo' libtool=yes @AMDEPBACKSLASH@
|
||||||
|
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
|
||||||
|
@am__fastdepCXX_FALSE@ $(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pix2jpg_la_CXXFLAGS) $(CXXFLAGS) -c -o pix2jpg_la-pix2jpg.lo `test -f 'pix2jpg.cpp' || echo '$(srcdir)/'`pix2jpg.cpp
|
||||||
|
|
||||||
|
mostlyclean-libtool:
|
||||||
|
-rm -f *.lo
|
||||||
|
|
||||||
|
clean-libtool:
|
||||||
|
-rm -rf .libs _libs
|
||||||
|
install-dist_extraDATA: $(dist_extra_DATA)
|
||||||
|
@$(NORMAL_INSTALL)
|
||||||
|
test -z "$(extradir)" || $(MKDIR_P) "$(DESTDIR)$(extradir)"
|
||||||
|
@list='$(dist_extra_DATA)'; test -n "$(extradir)" || list=; \
|
||||||
|
for p in $$list; do \
|
||||||
|
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
|
||||||
|
echo "$$d$$p"; \
|
||||||
|
done | $(am__base_list) | \
|
||||||
|
while read files; do \
|
||||||
|
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(extradir)'"; \
|
||||||
|
$(INSTALL_DATA) $$files "$(DESTDIR)$(extradir)" || exit $$?; \
|
||||||
|
done
|
||||||
|
|
||||||
|
uninstall-dist_extraDATA:
|
||||||
|
@$(NORMAL_UNINSTALL)
|
||||||
|
@list='$(dist_extra_DATA)'; test -n "$(extradir)" || list=; \
|
||||||
|
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
|
||||||
|
dir='$(DESTDIR)$(extradir)'; $(am__uninstall_files_from_dir)
|
||||||
|
|
||||||
|
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
|
||||||
|
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||||
|
unique=`for i in $$list; do \
|
||||||
|
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||||
|
done | \
|
||||||
|
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||||
|
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||||
|
mkid -fID $$unique
|
||||||
|
tags: TAGS
|
||||||
|
|
||||||
|
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||||
|
$(TAGS_FILES) $(LISP)
|
||||||
|
set x; \
|
||||||
|
here=`pwd`; \
|
||||||
|
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||||
|
unique=`for i in $$list; do \
|
||||||
|
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||||
|
done | \
|
||||||
|
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||||
|
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||||
|
shift; \
|
||||||
|
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
|
||||||
|
test -n "$$unique" || unique=$$empty_fix; \
|
||||||
|
if test $$# -gt 0; then \
|
||||||
|
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||||
|
"$$@" $$unique; \
|
||||||
|
else \
|
||||||
|
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
|
||||||
|
$$unique; \
|
||||||
|
fi; \
|
||||||
|
fi
|
||||||
|
ctags: CTAGS
|
||||||
|
CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
|
||||||
|
$(TAGS_FILES) $(LISP)
|
||||||
|
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
|
||||||
|
unique=`for i in $$list; do \
|
||||||
|
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
|
||||||
|
done | \
|
||||||
|
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
|
||||||
|
END { if (nonempty) { for (i in files) print i; }; }'`; \
|
||||||
|
test -z "$(CTAGS_ARGS)$$unique" \
|
||||||
|
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
|
||||||
|
$$unique
|
||||||
|
|
||||||
|
GTAGS:
|
||||||
|
here=`$(am__cd) $(top_builddir) && pwd` \
|
||||||
|
&& $(am__cd) $(top_srcdir) \
|
||||||
|
&& gtags -i $(GTAGS_ARGS) "$$here"
|
||||||
|
|
||||||
|
distclean-tags:
|
||||||
|
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
|
||||||
|
|
||||||
|
distdir: $(DISTFILES)
|
||||||
|
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||||
|
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
|
||||||
|
list='$(DISTFILES)'; \
|
||||||
|
dist_files=`for file in $$list; do echo $$file; done | \
|
||||||
|
sed -e "s|^$$srcdirstrip/||;t" \
|
||||||
|
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
|
||||||
|
case $$dist_files in \
|
||||||
|
*/*) $(MKDIR_P) `echo "$$dist_files" | \
|
||||||
|
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
|
||||||
|
sort -u` ;; \
|
||||||
|
esac; \
|
||||||
|
for file in $$dist_files; do \
|
||||||
|
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
|
||||||
|
if test -d $$d/$$file; then \
|
||||||
|
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
|
||||||
|
if test -d "$(distdir)/$$file"; then \
|
||||||
|
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||||
|
fi; \
|
||||||
|
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
|
||||||
|
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
|
||||||
|
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
|
||||||
|
fi; \
|
||||||
|
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
|
||||||
|
else \
|
||||||
|
test -f "$(distdir)/$$file" \
|
||||||
|
|| cp -p $$d/$$file "$(distdir)/$$file" \
|
||||||
|
|| exit 1; \
|
||||||
|
fi; \
|
||||||
|
done
|
||||||
|
check-am: all-am
|
||||||
|
check: check-am
|
||||||
|
all-am: Makefile $(LTLIBRARIES) $(DATA) all-local
|
||||||
|
installdirs:
|
||||||
|
for dir in "$(DESTDIR)$(extradir)" "$(DESTDIR)$(extradir)"; do \
|
||||||
|
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
|
||||||
|
done
|
||||||
|
install: install-am
|
||||||
|
install-exec: install-exec-am
|
||||||
|
install-data: install-data-am
|
||||||
|
uninstall: uninstall-am
|
||||||
|
|
||||||
|
install-am: all-am
|
||||||
|
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
|
||||||
|
|
||||||
|
installcheck: installcheck-am
|
||||||
|
install-strip:
|
||||||
|
if test -z '$(STRIP)'; then \
|
||||||
|
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||||
|
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||||
|
install; \
|
||||||
|
else \
|
||||||
|
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
|
||||||
|
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
|
||||||
|
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
|
||||||
|
fi
|
||||||
|
mostlyclean-generic:
|
||||||
|
|
||||||
|
clean-generic:
|
||||||
|
|
||||||
|
distclean-generic:
|
||||||
|
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
|
||||||
|
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
|
||||||
|
|
||||||
|
maintainer-clean-generic:
|
||||||
|
@echo "This command is intended for maintainers to use"
|
||||||
|
@echo "it deletes files that may require special tools to rebuild."
|
||||||
|
clean: clean-am
|
||||||
|
|
||||||
|
clean-am: clean-extraLTLIBRARIES clean-generic clean-libtool \
|
||||||
|
clean-local mostlyclean-am
|
||||||
|
|
||||||
|
distclean: distclean-am
|
||||||
|
-rm -rf ./$(DEPDIR)
|
||||||
|
-rm -f Makefile
|
||||||
|
distclean-am: clean-am distclean-compile distclean-generic \
|
||||||
|
distclean-tags
|
||||||
|
|
||||||
|
dvi: dvi-am
|
||||||
|
|
||||||
|
dvi-am:
|
||||||
|
|
||||||
|
html: html-am
|
||||||
|
|
||||||
|
html-am:
|
||||||
|
|
||||||
|
info: info-am
|
||||||
|
|
||||||
|
info-am:
|
||||||
|
|
||||||
|
install-data-am: install-dist_extraDATA install-extraLTLIBRARIES
|
||||||
|
|
||||||
|
install-dvi: install-dvi-am
|
||||||
|
|
||||||
|
install-dvi-am:
|
||||||
|
|
||||||
|
install-exec-am:
|
||||||
|
|
||||||
|
install-html: install-html-am
|
||||||
|
|
||||||
|
install-html-am:
|
||||||
|
|
||||||
|
install-info: install-info-am
|
||||||
|
|
||||||
|
install-info-am:
|
||||||
|
|
||||||
|
install-man:
|
||||||
|
|
||||||
|
install-pdf: install-pdf-am
|
||||||
|
|
||||||
|
install-pdf-am:
|
||||||
|
|
||||||
|
install-ps: install-ps-am
|
||||||
|
|
||||||
|
install-ps-am:
|
||||||
|
|
||||||
|
installcheck-am:
|
||||||
|
|
||||||
|
maintainer-clean: maintainer-clean-am
|
||||||
|
-rm -rf ./$(DEPDIR)
|
||||||
|
-rm -f Makefile
|
||||||
|
maintainer-clean-am: distclean-am maintainer-clean-generic
|
||||||
|
|
||||||
|
mostlyclean: mostlyclean-am
|
||||||
|
|
||||||
|
mostlyclean-am: mostlyclean-compile mostlyclean-generic \
|
||||||
|
mostlyclean-libtool
|
||||||
|
|
||||||
|
pdf: pdf-am
|
||||||
|
|
||||||
|
pdf-am:
|
||||||
|
|
||||||
|
ps: ps-am
|
||||||
|
|
||||||
|
ps-am:
|
||||||
|
|
||||||
|
uninstall-am: uninstall-dist_extraDATA uninstall-extraLTLIBRARIES
|
||||||
|
|
||||||
|
.MAKE: install-am install-strip
|
||||||
|
|
||||||
|
.PHONY: CTAGS GTAGS all all-am all-local check check-am clean \
|
||||||
|
clean-extraLTLIBRARIES clean-generic clean-libtool clean-local \
|
||||||
|
ctags distclean distclean-compile distclean-generic \
|
||||||
|
distclean-libtool distclean-tags distdir dvi dvi-am html \
|
||||||
|
html-am info info-am install install-am install-data \
|
||||||
|
install-data-am install-dist_extraDATA install-dvi \
|
||||||
|
install-dvi-am install-exec install-exec-am \
|
||||||
|
install-extraLTLIBRARIES install-html install-html-am \
|
||||||
|
install-info install-info-am install-man install-pdf \
|
||||||
|
install-pdf-am install-ps install-ps-am install-strip \
|
||||||
|
installcheck installcheck-am installdirs maintainer-clean \
|
||||||
|
maintainer-clean-generic mostlyclean mostlyclean-compile \
|
||||||
|
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
|
||||||
|
tags uninstall uninstall-am uninstall-dist_extraDATA \
|
||||||
|
uninstall-extraLTLIBRARIES
|
||||||
|
|
||||||
|
|
||||||
|
# convenience symlinks
|
||||||
|
pix2jpg.@GEM_RTE_EXTENSION@: pix2jpg.la
|
||||||
|
rm -f $@
|
||||||
|
test -f .libs/$@ && $(LN_S) .libs/$@ $@ || true
|
||||||
|
|
||||||
|
.PHONY: clean-conviencesymlink
|
||||||
|
|
||||||
|
clean-conviencesymlink:
|
||||||
|
rm -f pix2jpg.@GEM_RTE_EXTENSION@
|
||||||
|
|
||||||
|
all-local:: pix2jpg.@GEM_RTE_EXTENSION@
|
||||||
|
|
||||||
|
clean-local:: clean-conviencesymlink
|
||||||
|
|
||||||
|
# Tell versions [3.59,3.63) of GNU make to not export all variables.
|
||||||
|
# Otherwise a system limit (for SysV at least) may be exceeded.
|
||||||
|
.NOEXPORT:
|
24
externals/pix2jpg/pix2jpg-help.pd
vendored
Normal file
24
externals/pix2jpg/pix2jpg-help.pd
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
#N canvas 690 208 450 300 10;
|
||||||
|
#X obj 270 167 pix_image;
|
||||||
|
#X msg 299 137 open img.jpg;
|
||||||
|
#X obj 270 103 gemhead;
|
||||||
|
#X obj 94 213 gemwin;
|
||||||
|
#X msg 53 147 create;
|
||||||
|
#X msg 270 64 1;
|
||||||
|
#X msg 121 145 destroy;
|
||||||
|
#X msg 308 63 0;
|
||||||
|
#X obj 270 196 pix_texture;
|
||||||
|
#X obj 270 222 rectangle 4 4;
|
||||||
|
#N canvas 25 162 450 300 gemwin 0;
|
||||||
|
#X restore 85 239 pd gemwin;
|
||||||
|
#X msg 41 181 1;
|
||||||
|
#X obj 191 203 pix2jpg;
|
||||||
|
#X connect 0 0 8 0;
|
||||||
|
#X connect 1 0 0 0;
|
||||||
|
#X connect 2 0 0 0;
|
||||||
|
#X connect 4 0 3 0;
|
||||||
|
#X connect 5 0 2 0;
|
||||||
|
#X connect 6 0 3 0;
|
||||||
|
#X connect 7 0 2 0;
|
||||||
|
#X connect 8 0 9 0;
|
||||||
|
#X connect 11 0 3 0;
|
152
externals/pix2jpg/pix2jpg.cpp
vendored
Normal file
152
externals/pix2jpg/pix2jpg.cpp
vendored
Normal file
|
@ -0,0 +1,152 @@
|
||||||
|
////////////////////////////////////////////////////////
|
||||||
|
// pix2jpg v0.01
|
||||||
|
// External for Gem and Pure Data to convert an image to jpg and send it
|
||||||
|
// via Unix Domain Sockets
|
||||||
|
// Compiled and tested in Ubuntu Precise
|
||||||
|
// (c) 2012 Santi Noreña. puremediaserver@gmail.com
|
||||||
|
//
|
||||||
|
// GEM - Graphics Environment for Multimedia
|
||||||
|
//
|
||||||
|
// zmoelnig@iem.kug.ac.at
|
||||||
|
//
|
||||||
|
// Implementation file
|
||||||
|
//
|
||||||
|
// Copyright (c) 1997-1999 Mark Danks.
|
||||||
|
// Copyright (c) Günther Geiger.
|
||||||
|
// Copyright (c) 2001-2011 IOhannes m zmölnig. forum::für::umläute. IEM. zmoelnig@iem.at
|
||||||
|
// Copyright (c) 2002 James Tittle & Chris Clepper
|
||||||
|
// For information on usage and redistribution, and for a DISCLAIMER OF ALL
|
||||||
|
// WARRANTIES, see the file, "GEM.LICENSE.TERMS" in this distribution.
|
||||||
|
//
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#include "pix2jpg.h"
|
||||||
|
#include <sys/socket.h>
|
||||||
|
#include <sys/un.h>
|
||||||
|
#include "m_pd.h"
|
||||||
|
//#include "s_stuff.h"
|
||||||
|
#define SOCK_PATH "/tmp/pmspipe"
|
||||||
|
|
||||||
|
CPPEXTERN_NEW_WITH_ONE_ARG(pix2jpg, t_symbol *, A_DEFSYM);
|
||||||
|
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
//
|
||||||
|
// pix2jpg
|
||||||
|
//
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
// Constructor
|
||||||
|
//
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
pix2jpg :: pix2jpg(t_symbol *s)
|
||||||
|
: m_banged(false),
|
||||||
|
m_automatic(false),
|
||||||
|
m_layer(0)
|
||||||
|
{
|
||||||
|
post("pix2jpg v0.01 Convert pix to jpeg and send to Unix Local Socket");
|
||||||
|
post("(c) 2012 Santi Noreña puremediaserver@gmail.com");
|
||||||
|
post("GPL License");
|
||||||
|
outlet1 = outlet_new(this->x_obj, 0); // Saca todos los canales mediante una lista
|
||||||
|
// Init the Unix Socket
|
||||||
|
socket_fd = socket(PF_UNIX, SOCK_STREAM, 0);
|
||||||
|
if(socket_fd < 0)
|
||||||
|
{
|
||||||
|
post("pix2jpg:create socket() failed\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
/* start with a clean address structure */
|
||||||
|
memset(&address, 0, sizeof(struct sockaddr_un));
|
||||||
|
address.sun_family = PF_UNIX;
|
||||||
|
strcpy(address.sun_path,SOCK_PATH);
|
||||||
|
if(connect(socket_fd,(struct sockaddr *) &address,sizeof(struct sockaddr_un)) != 0)
|
||||||
|
{
|
||||||
|
post("pix2jpg:connect() failed");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
// Destructor
|
||||||
|
//
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
pix2jpg :: ~pix2jpg()
|
||||||
|
{
|
||||||
|
outlet_free(outlet1);
|
||||||
|
}
|
||||||
|
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
// render
|
||||||
|
//
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
void pix2jpg :: processImage(imageStruct &image)
|
||||||
|
{
|
||||||
|
if (m_automatic || m_banged)
|
||||||
|
{
|
||||||
|
m_banged =false;
|
||||||
|
int counter = 0;
|
||||||
|
Image imagem(image.xsize, image.ysize, "RGBA", CharPixel, image.data);
|
||||||
|
imagem.resize("64x46");
|
||||||
|
// Write to BLOB in png format
|
||||||
|
Blob blob;
|
||||||
|
imagem.magick( "jpg" ); // Set JPEG output format
|
||||||
|
imagem.write( &blob );
|
||||||
|
// Enviamos al GUI x Unix Domain Sockets
|
||||||
|
int size = blob.length() +2;
|
||||||
|
char buffer[size];
|
||||||
|
memcpy(buffer+2, blob.data(), blob.length());
|
||||||
|
memcpy(buffer,&m_layer, 2);
|
||||||
|
write(socket_fd, buffer, size);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
// static member functions
|
||||||
|
//
|
||||||
|
/////////////////////////////////////////////////////////
|
||||||
|
void pix2jpg :: obj_setupCallback(t_class *classPtr)
|
||||||
|
{
|
||||||
|
class_addbang(classPtr, reinterpret_cast<t_method>(&pix2jpg::bangMessCallback));
|
||||||
|
class_addmethod(classPtr, reinterpret_cast<t_method>(&pix2jpg::startMessCallback),gensym("start"), A_NULL);
|
||||||
|
class_addmethod(classPtr, reinterpret_cast<t_method>(&pix2jpg::stopMessCallback),gensym("stop"), A_NULL);
|
||||||
|
class_addmethod(classPtr, reinterpret_cast<t_method>(&pix2jpg::layerimageMessCallback),gensym("layerimage"), A_FLOAT,A_NULL);
|
||||||
|
class_addmethod(classPtr, reinterpret_cast<t_method>(&pix2jpg::layernameMessCallback),gensym("layername"), A_GIMME,A_NULL);
|
||||||
|
}
|
||||||
|
void pix2jpg :: startMessCallback(void *data)
|
||||||
|
{
|
||||||
|
GetMyClass(data)->m_automatic=true;
|
||||||
|
}
|
||||||
|
void pix2jpg :: stopMessCallback(void *data)
|
||||||
|
{
|
||||||
|
GetMyClass(data)->m_automatic=false;
|
||||||
|
}
|
||||||
|
void pix2jpg :: bangMessCallback(void *data)
|
||||||
|
{
|
||||||
|
GetMyClass(data)->m_banged=true;
|
||||||
|
}
|
||||||
|
void pix2jpg :: layerimageMessCallback (void *data, t_float f)
|
||||||
|
{
|
||||||
|
GetMyClass(data)->m_layer=f;
|
||||||
|
printf("layer: %d", GetMyClass(data)->m_layer);
|
||||||
|
}
|
||||||
|
void pix2jpg :: layernameMessCallback(void *data, t_symbol *s, int argc, t_atom *argv)
|
||||||
|
{
|
||||||
|
/* int n, length;
|
||||||
|
t_symbol *c;
|
||||||
|
// check for correct number of arguments
|
||||||
|
n = atom_getint(argv++);
|
||||||
|
c = atom_getsymbol(argv++);
|
||||||
|
|
||||||
|
length = 2 + sizeof(c);
|
||||||
|
char *buffer;
|
||||||
|
post
|
||||||
|
memcpy(buffer+2, c, sizeof(c));
|
||||||
|
memcpy(buffer,&n, 2); */
|
||||||
|
t_binbuf *b = binbuf_new();
|
||||||
|
char *buf;
|
||||||
|
int length;
|
||||||
|
// t_atom at;
|
||||||
|
binbuf_add(b, argc, argv);
|
||||||
|
// SETSEMI(&at);
|
||||||
|
// binbuf_add(b, 1, &at);
|
||||||
|
binbuf_gettext(b, &buf, &length);
|
||||||
|
write(socket_fd, buf, length);
|
||||||
|
}
|
||||||
|
|
106
externals/pix2jpg/pix2jpg.h
vendored
Normal file
106
externals/pix2jpg/pix2jpg.h
vendored
Normal file
|
@ -0,0 +1,106 @@
|
||||||
|
/*-----------------------------------------------------------------
|
||||||
|
pix2jpg v0.01
|
||||||
|
External for Gem and Pure Data to convert an image to jpg and send it
|
||||||
|
via Unix Domain Sockets
|
||||||
|
Compiled and tested in Ubuntu Precise
|
||||||
|
(c) 2012 Santi Noreña. puremediaserver@gmail.com
|
||||||
|
|
||||||
|
GEM - Graphics Environment for Multimedia
|
||||||
|
Copyright (c) 1997-1999 Mark Danks. mark@danks.org
|
||||||
|
Copyright (c) Günther Geiger. geiger@epy.co.at
|
||||||
|
Copyright (c) 2001-2011 IOhannes m zmölnig. forum::für::umläute. IEM. zmoelnig@iem.at
|
||||||
|
For information on usage and redistribution, and for a DISCLAIMER OF ALL
|
||||||
|
WARRANTIES, see the file, "GEM.LICENSE.TERMS" in this distribution.
|
||||||
|
|
||||||
|
-----------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#ifndef _INCLUDE__GEM_PIXES_pix2jpg_H_
|
||||||
|
#define _INCLUDE__GEM_PIXES_pix2jpg_H_
|
||||||
|
|
||||||
|
#include "Base/GemPixObj.h"
|
||||||
|
#include "Base/GemBase.h"
|
||||||
|
#include "Gem/Manager.h"
|
||||||
|
#include "Gem/ImageIO.h"
|
||||||
|
#include "Gem/Image.h"
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <Magick++.h>
|
||||||
|
#include <sys/socket.h>
|
||||||
|
#include <sys/un.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
using namespace Magick;
|
||||||
|
/*-----------------------------------------------------------------
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
CLASS
|
||||||
|
pix2jpg
|
||||||
|
|
||||||
|
Convert a image to raw RGB and outputs in a list
|
||||||
|
|
||||||
|
KEYWORDS
|
||||||
|
pix
|
||||||
|
|
||||||
|
DESCRIPTION
|
||||||
|
|
||||||
|
"bang" - do write now
|
||||||
|
|
||||||
|
outlet : The list of raw data.
|
||||||
|
-----------------------------------------------------------------*/
|
||||||
|
class GEM_EXPORT pix2jpg : public GemPixObj
|
||||||
|
{
|
||||||
|
CPPEXTERN_HEADER(pix2jpg, GemPixObj);
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// Constructor
|
||||||
|
pix2jpg(t_symbol *s);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// Destructor
|
||||||
|
virtual ~pix2jpg();
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// Do the rendering
|
||||||
|
virtual void processImage(imageStruct&image);
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// Set the filename and filetype
|
||||||
|
// virtual void fileMess(int argc, t_atom *argv);
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// The original pix_writer
|
||||||
|
imageStruct *m_originalImage;
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// Manual writing
|
||||||
|
bool m_banged;
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// Automatic writing
|
||||||
|
bool m_automatic;
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// Layer to write
|
||||||
|
|
||||||
|
int m_layer;
|
||||||
|
|
||||||
|
t_outlet *outlet1; // outlet pointer
|
||||||
|
|
||||||
|
struct sockaddr_un address;
|
||||||
|
int socket_fd, nbytes;
|
||||||
|
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
//////////
|
||||||
|
// static member functions
|
||||||
|
static void startMessCallback(void *data);
|
||||||
|
static void stopMessCallback(void *data);
|
||||||
|
static void bangMessCallback(void *data);
|
||||||
|
static void layerimageMessCallback(void *data, t_float f);
|
||||||
|
void layernameMessCallback(void *data, t_symbol *s,int argc, t_atom *argv);
|
||||||
|
};
|
||||||
|
#endif // for header file
|
294
layer_audio.pd
Normal file
294
layer_audio.pd
Normal file
|
@ -0,0 +1,294 @@
|
||||||
|
#N canvas 339 118 1016 665 10;
|
||||||
|
#N canvas 347 96 1016 665 audio_player 0;
|
||||||
|
#X msg 239 357 open \$1;
|
||||||
|
#X msg 383 478 start;
|
||||||
|
#X msg 438 479 stop;
|
||||||
|
#X obj 384 568 oggread~;
|
||||||
|
#X msg 491 481 resume;
|
||||||
|
#X obj 239 185 inlet;
|
||||||
|
#X obj 334 185 inlet;
|
||||||
|
#X obj 239 304 spigot;
|
||||||
|
#X msg 334 260 1;
|
||||||
|
#X msg 379 261 0;
|
||||||
|
#X obj 436 377 / 25;
|
||||||
|
#X obj 436 346 spigot;
|
||||||
|
#X obj 436 406 int;
|
||||||
|
#X obj 436 186 r \$0-c5;
|
||||||
|
#X obj 365 619 *~ 0;
|
||||||
|
#X obj 422 619 *~ 0;
|
||||||
|
#X obj 541 563 dbtorms;
|
||||||
|
#X obj 484 563 dbtorms;
|
||||||
|
#X obj 414 733 dac~;
|
||||||
|
#X obj 365 690 gpan~;
|
||||||
|
#X obj 580 466 r \$0-c1;
|
||||||
|
#X obj 665 465 r \$0-c2;
|
||||||
|
#X text 578 449 Volumen;
|
||||||
|
#X text 677 449 Pan;
|
||||||
|
#X obj 665 505 * 0.00392157;
|
||||||
|
#X obj 334 226 select 1;
|
||||||
|
#X obj 436 434 select 0 1 2;
|
||||||
|
#X msg 214 511 seek \$1;
|
||||||
|
#X obj 214 446 r \$0-c8;
|
||||||
|
#X obj 580 502 * 0.0015308;
|
||||||
|
#X obj 214 477 * 0.01;
|
||||||
|
#X obj 465 621 s \$0-position;
|
||||||
|
#X connect 0 0 3 0;
|
||||||
|
#X connect 1 0 3 0;
|
||||||
|
#X connect 2 0 3 0;
|
||||||
|
#X connect 3 0 14 0;
|
||||||
|
#X connect 3 1 15 0;
|
||||||
|
#X connect 3 2 31 0;
|
||||||
|
#X connect 4 0 3 0;
|
||||||
|
#X connect 5 0 7 0;
|
||||||
|
#X connect 6 0 25 0;
|
||||||
|
#X connect 7 0 0 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 8 0 11 1;
|
||||||
|
#X connect 9 0 7 1;
|
||||||
|
#X connect 9 0 11 1;
|
||||||
|
#X connect 10 0 12 0;
|
||||||
|
#X connect 11 0 10 0;
|
||||||
|
#X connect 12 0 26 0;
|
||||||
|
#X connect 13 0 11 0;
|
||||||
|
#X connect 14 0 19 0;
|
||||||
|
#X connect 15 0 19 1;
|
||||||
|
#X connect 16 0 15 1;
|
||||||
|
#X connect 17 0 14 1;
|
||||||
|
#X connect 19 0 18 0;
|
||||||
|
#X connect 19 1 18 1;
|
||||||
|
#X connect 20 0 29 0;
|
||||||
|
#X connect 21 0 24 0;
|
||||||
|
#X connect 24 0 19 2;
|
||||||
|
#X connect 25 0 8 0;
|
||||||
|
#X connect 25 1 9 0;
|
||||||
|
#X connect 26 0 1 0;
|
||||||
|
#X connect 26 1 2 0;
|
||||||
|
#X connect 26 2 4 0;
|
||||||
|
#X connect 27 0 3 0;
|
||||||
|
#X connect 28 0 30 0;
|
||||||
|
#X connect 29 0 17 0;
|
||||||
|
#X connect 29 0 16 0;
|
||||||
|
#X connect 30 0 27 0;
|
||||||
|
#X connect 30 0 31 0;
|
||||||
|
#X restore 37 -34 pd audio_player;
|
||||||
|
#X obj 430 296 change;
|
||||||
|
#X obj 483 296 change;
|
||||||
|
#X obj 533 296 change;
|
||||||
|
#X obj 589 296 change;
|
||||||
|
#X obj 646 296 change;
|
||||||
|
#X obj 701 296 change;
|
||||||
|
#X obj 756 296 change;
|
||||||
|
#X obj 818 296 change;
|
||||||
|
#X obj 35 296 change;
|
||||||
|
#X obj 83 296 change;
|
||||||
|
#X obj 128 296 change;
|
||||||
|
#X obj 173 296 change;
|
||||||
|
#X obj 226 296 change;
|
||||||
|
#X obj 277 296 change;
|
||||||
|
#X obj 323 296 change;
|
||||||
|
#X obj 376 296 change;
|
||||||
|
#X obj 177 86 inlet;
|
||||||
|
#X obj 35 423 s \$0-c1;
|
||||||
|
#X obj 83 321 s \$0-c2;
|
||||||
|
#X obj 128 321 s \$0-c3;
|
||||||
|
#X obj 173 321 s \$0-c4;
|
||||||
|
#X obj 226 321 s \$0-c5;
|
||||||
|
#X obj 277 321 s \$0-c6;
|
||||||
|
#X obj 376 429 s \$0-c8;
|
||||||
|
#X obj 483 321 s \$0-c10;
|
||||||
|
#X obj 533 321 s \$0-c11;
|
||||||
|
#X obj 589 321 s \$0-c12;
|
||||||
|
#X obj 646 321 s \$0-c13;
|
||||||
|
#X obj 701 321 s \$0-c14;
|
||||||
|
#X obj 756 321 s \$0-c15;
|
||||||
|
#X obj 818 321 s \$0-c16;
|
||||||
|
#N canvas 1 104 1366 680 selector 0;
|
||||||
|
#X obj 669 -356 loadbang;
|
||||||
|
#X obj 221 455 outlet;
|
||||||
|
#X obj 591 -142 outlet;
|
||||||
|
#X obj 559 -423 / 25;
|
||||||
|
#X obj 280 -218 spigot;
|
||||||
|
#X msg 375 -295 1;
|
||||||
|
#X msg 413 -295 0;
|
||||||
|
#X msg 522 -268 1;
|
||||||
|
#X msg 562 -268 2;
|
||||||
|
#X msg 598 -268 3;
|
||||||
|
#X msg 632 -268 4;
|
||||||
|
#X obj 559 -353 select 1 2 3 4;
|
||||||
|
#X msg 666 -268 0;
|
||||||
|
#X msg 252 142 symbol \$1;
|
||||||
|
#X text 280 -296 folder;
|
||||||
|
#X obj 559 -383 int;
|
||||||
|
#X obj 332 -198 symbol;
|
||||||
|
#X obj 341 301 t l;
|
||||||
|
#X obj 253 413 list split 1;
|
||||||
|
#X obj 222 394 list split;
|
||||||
|
#X obj 252 166 t b a;
|
||||||
|
#X obj 330 217 symbol;
|
||||||
|
#X obj 216 195 t b b;
|
||||||
|
#X obj 252 222 t b b;
|
||||||
|
#X obj 222 354 list;
|
||||||
|
#X obj 252 302 list prepend;
|
||||||
|
#X obj 384 167 b;
|
||||||
|
#X msg 332 -130 symbol \$1;
|
||||||
|
#X obj 202 -124 b;
|
||||||
|
#X obj 361 -34 t l;
|
||||||
|
#X obj 224 -3 list;
|
||||||
|
#X obj 245 -37 list prepend;
|
||||||
|
#X obj 224 37 list split;
|
||||||
|
#X obj 252 62 list split 1;
|
||||||
|
#X obj 252 102 makefilename %s/*;
|
||||||
|
#X obj 81 307 int;
|
||||||
|
#X obj 118 302 + 1;
|
||||||
|
#X msg 20 267 0;
|
||||||
|
#X msg 115 224 0;
|
||||||
|
#X msg 149 224 1;
|
||||||
|
#X obj 81 267 metro 100;
|
||||||
|
#X obj 189 408 b;
|
||||||
|
#X obj 221 434 symbol;
|
||||||
|
#X obj 81 361 select 1;
|
||||||
|
#X obj 332 -158 makefilename %s/sound/*;
|
||||||
|
#X obj 280 -258 r \$0-c3;
|
||||||
|
#X obj 498 100 r \$0-c4;
|
||||||
|
#X text 531 -95 Tipo de media: 0 Off 1 Playback;
|
||||||
|
#X obj 559 -463 r \$0-c6;
|
||||||
|
#X obj 332 -238 r path;
|
||||||
|
#X obj 245 -77 folder_list;
|
||||||
|
#X obj 252 262 folder_list;
|
||||||
|
#X symbolatom 657 55 80 0 0 0 - - -;
|
||||||
|
#X symbolatom 676 308 80 0 0 0 - - -;
|
||||||
|
#X connect 0 0 12 0;
|
||||||
|
#X connect 3 0 15 0;
|
||||||
|
#X connect 4 0 32 1;
|
||||||
|
#X connect 4 0 28 0;
|
||||||
|
#X connect 5 0 4 1;
|
||||||
|
#X connect 6 0 4 1;
|
||||||
|
#X connect 7 0 2 0;
|
||||||
|
#X connect 8 0 2 0;
|
||||||
|
#X connect 9 0 2 0;
|
||||||
|
#X connect 10 0 2 0;
|
||||||
|
#X connect 11 0 7 0;
|
||||||
|
#X connect 11 0 5 0;
|
||||||
|
#X connect 11 0 16 0;
|
||||||
|
#X connect 11 1 8 0;
|
||||||
|
#X connect 11 1 6 0;
|
||||||
|
#X connect 11 2 9 0;
|
||||||
|
#X connect 11 2 6 0;
|
||||||
|
#X connect 11 3 6 0;
|
||||||
|
#X connect 11 3 10 0;
|
||||||
|
#X connect 11 4 6 0;
|
||||||
|
#X connect 11 4 12 0;
|
||||||
|
#X connect 12 0 2 0;
|
||||||
|
#X connect 13 0 20 0;
|
||||||
|
#X connect 15 0 11 0;
|
||||||
|
#X connect 16 0 44 0;
|
||||||
|
#X connect 17 0 25 1;
|
||||||
|
#X connect 18 0 42 1;
|
||||||
|
#X connect 19 1 18 0;
|
||||||
|
#X connect 20 0 22 0;
|
||||||
|
#X connect 20 0 39 0;
|
||||||
|
#X connect 20 1 21 0;
|
||||||
|
#X connect 21 0 51 1;
|
||||||
|
#X connect 22 0 24 0;
|
||||||
|
#X connect 22 1 23 0;
|
||||||
|
#X connect 23 0 51 0;
|
||||||
|
#X connect 23 1 25 1;
|
||||||
|
#X connect 24 0 19 0;
|
||||||
|
#X connect 25 0 17 0;
|
||||||
|
#X connect 25 0 24 1;
|
||||||
|
#X connect 26 0 24 0;
|
||||||
|
#X connect 26 0 39 0;
|
||||||
|
#X connect 27 0 28 0;
|
||||||
|
#X connect 27 0 50 1;
|
||||||
|
#X connect 28 0 31 1;
|
||||||
|
#X connect 28 0 30 0;
|
||||||
|
#X connect 28 0 50 0;
|
||||||
|
#X connect 29 0 31 1;
|
||||||
|
#X connect 30 0 32 0;
|
||||||
|
#X connect 31 0 29 0;
|
||||||
|
#X connect 31 0 30 1;
|
||||||
|
#X connect 32 1 33 0;
|
||||||
|
#X connect 33 0 34 0;
|
||||||
|
#X connect 33 0 52 0;
|
||||||
|
#X connect 34 0 13 0;
|
||||||
|
#X connect 35 0 36 0;
|
||||||
|
#X connect 35 0 43 0;
|
||||||
|
#X connect 36 0 35 1;
|
||||||
|
#X connect 37 0 35 1;
|
||||||
|
#X connect 38 0 40 0;
|
||||||
|
#X connect 39 0 40 0;
|
||||||
|
#X connect 40 0 35 0;
|
||||||
|
#X connect 41 0 42 0;
|
||||||
|
#X connect 42 0 1 0;
|
||||||
|
#X connect 42 0 53 0;
|
||||||
|
#X connect 43 0 38 0;
|
||||||
|
#X connect 43 0 37 0;
|
||||||
|
#X connect 43 0 41 0;
|
||||||
|
#X connect 44 0 27 0;
|
||||||
|
#X connect 45 0 4 0;
|
||||||
|
#X connect 46 0 19 1;
|
||||||
|
#X connect 46 0 26 0;
|
||||||
|
#X connect 48 0 3 0;
|
||||||
|
#X connect 49 0 16 0;
|
||||||
|
#X connect 50 0 31 0;
|
||||||
|
#X connect 51 0 25 0;
|
||||||
|
#X restore 37 -94 pd selector;
|
||||||
|
#X obj 177 111 list split 16;
|
||||||
|
#X obj 177 136 unpack f f f f f f f f f f f f f f f f;
|
||||||
|
#X obj 35 352 << 8;
|
||||||
|
#X obj 35 393 +;
|
||||||
|
#X obj 81 359 t b f;
|
||||||
|
#X obj 376 343 << 8;
|
||||||
|
#X obj 376 384 +;
|
||||||
|
#X obj 430 343 t b f;
|
||||||
|
#X text 185 -46 c1 Vol c2 pan c3 folder c4 file c5 playback c6 Control
|
||||||
|
c7 Volumen fino 8 Entry point Coarse 9 Entry point fine;
|
||||||
|
#X obj 5 49 outlet;
|
||||||
|
#X floatatom 163 425 5 0 0 0 - - -;
|
||||||
|
#X connect 1 0 40 0;
|
||||||
|
#X connect 2 0 25 0;
|
||||||
|
#X connect 3 0 26 0;
|
||||||
|
#X connect 4 0 27 0;
|
||||||
|
#X connect 5 0 28 0;
|
||||||
|
#X connect 6 0 29 0;
|
||||||
|
#X connect 7 0 30 0;
|
||||||
|
#X connect 8 0 31 0;
|
||||||
|
#X connect 9 0 35 0;
|
||||||
|
#X connect 9 0 43 0;
|
||||||
|
#X connect 10 0 19 0;
|
||||||
|
#X connect 11 0 20 0;
|
||||||
|
#X connect 12 0 21 0;
|
||||||
|
#X connect 13 0 22 0;
|
||||||
|
#X connect 14 0 23 0;
|
||||||
|
#X connect 15 0 37 0;
|
||||||
|
#X connect 16 0 38 0;
|
||||||
|
#X connect 17 0 33 0;
|
||||||
|
#X connect 32 0 0 0;
|
||||||
|
#X connect 32 0 42 0;
|
||||||
|
#X connect 32 1 0 1;
|
||||||
|
#X connect 33 0 34 0;
|
||||||
|
#X connect 34 0 9 0;
|
||||||
|
#X connect 34 1 10 0;
|
||||||
|
#X connect 34 2 11 0;
|
||||||
|
#X connect 34 3 12 0;
|
||||||
|
#X connect 34 4 13 0;
|
||||||
|
#X connect 34 5 14 0;
|
||||||
|
#X connect 34 6 15 0;
|
||||||
|
#X connect 34 7 16 0;
|
||||||
|
#X connect 34 8 1 0;
|
||||||
|
#X connect 34 9 2 0;
|
||||||
|
#X connect 34 10 3 0;
|
||||||
|
#X connect 34 11 4 0;
|
||||||
|
#X connect 34 12 5 0;
|
||||||
|
#X connect 34 13 6 0;
|
||||||
|
#X connect 34 14 7 0;
|
||||||
|
#X connect 34 15 8 0;
|
||||||
|
#X connect 35 0 36 0;
|
||||||
|
#X connect 36 0 18 0;
|
||||||
|
#X connect 37 0 36 0;
|
||||||
|
#X connect 37 1 36 1;
|
||||||
|
#X connect 38 0 39 0;
|
||||||
|
#X connect 39 0 24 0;
|
||||||
|
#X connect 40 0 39 0;
|
||||||
|
#X connect 40 1 39 1;
|
||||||
|
#X coords 0 665 1 664 0 0 0;
|
1616
libremediaserver.cpp
Normal file
1616
libremediaserver.cpp
Normal file
File diff suppressed because it is too large
Load diff
153
libremediaserver.h
Normal file
153
libremediaserver.h
Normal file
|
@ -0,0 +1,153 @@
|
||||||
|
/*
|
||||||
|
Libre Media Server - A Media Server Sotfware for stage and performing
|
||||||
|
Copyright (C) 2012-2013 Santiago Noreña libremediaserver@gmail.com
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef LIBREMEDIASERVER_H
|
||||||
|
#define LIBREMEDIASERVER_H
|
||||||
|
|
||||||
|
#include <QMainWindow>
|
||||||
|
#include "msex.h"
|
||||||
|
#include "ui_libremediaserver.h"
|
||||||
|
#include <QLocalServer>
|
||||||
|
#include <QLocalSocket>
|
||||||
|
|
||||||
|
class msex;
|
||||||
|
class QMenu;
|
||||||
|
class QProcess;
|
||||||
|
|
||||||
|
class libreMediaServer : public QMainWindow
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
libreMediaServer (QWidget *parent = 0);
|
||||||
|
virtual ~libreMediaServer();
|
||||||
|
|
||||||
|
Ui::PureMediaServer ui;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
QString m_pathmedia; // Path to Medias
|
||||||
|
msex *m_msex; // MSEx
|
||||||
|
QProcess *m_ola; // OLA daemon process
|
||||||
|
QProcess *m_pd_video; // Pure Data process for video
|
||||||
|
QProcess *m_pd_audio; // Pure Data process for audio
|
||||||
|
|
||||||
|
// Video Sockets
|
||||||
|
QTcpSocket *m_pd_write_video;
|
||||||
|
// Unix Local Sockets
|
||||||
|
// QLocalSocket *m_write_vid;
|
||||||
|
QLocalServer *m_server_vid;
|
||||||
|
QLocalSocket *m_read_vid;
|
||||||
|
|
||||||
|
// Audio TCP Sockets
|
||||||
|
QTcpSocket *m_pd_write_audio;
|
||||||
|
QTcpServer *m_pd_read_audio;
|
||||||
|
QTcpSocket *m_tcpsocket_audio;
|
||||||
|
|
||||||
|
QTimer *m_preview;
|
||||||
|
// void contextMenuEvent(QContextMenuEvent *event);
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
bool sendPacket(const char *buffer, int bufferLen);
|
||||||
|
void pdstart();
|
||||||
|
void errorsending();
|
||||||
|
bool sendPacket_audio(const char *buffer, int bufferLen);
|
||||||
|
void pdstart_audio();
|
||||||
|
void errorsending_audio();
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
|
||||||
|
void sendFrame();
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
|
||||||
|
void olastart(); // Init the OLA daemon
|
||||||
|
void on_ChangePath_clicked();// Change the path to medias
|
||||||
|
|
||||||
|
// Video
|
||||||
|
|
||||||
|
void on_updateButton_clicked(); // Init the CITP/MSEx protocol
|
||||||
|
void newPeer();
|
||||||
|
void newmessage();
|
||||||
|
void newconexion();
|
||||||
|
void on_window_stateChanged(int state);
|
||||||
|
void on_winpositionx_valueChanged();
|
||||||
|
void on_winpositiony_valueChanged();
|
||||||
|
void on_winsizex_valueChanged();
|
||||||
|
void on_winsizey_valueChanged();
|
||||||
|
void on_readDMX_stateChanged(int state);
|
||||||
|
void on_layer1Add_valueChanged();
|
||||||
|
void on_layer1Check_stateChanged (int state);
|
||||||
|
void on_layer2Add_valueChanged();
|
||||||
|
void on_layer2Check_stateChanged (int state);
|
||||||
|
void on_layer3Add_valueChanged();
|
||||||
|
void on_layer3Check_stateChanged (int state);
|
||||||
|
void on_layer4Add_valueChanged();
|
||||||
|
void on_layer4Check_stateChanged (int state);
|
||||||
|
void on_layer5Add_valueChanged();
|
||||||
|
void on_layer5Check_stateChanged (int state);
|
||||||
|
void on_layer6Add_valueChanged();
|
||||||
|
void on_layer6Check_stateChanged (int state);
|
||||||
|
void on_layer7Add_valueChanged();
|
||||||
|
void on_layer7Check_stateChanged (int state);
|
||||||
|
void on_layer8Add_valueChanged();
|
||||||
|
void on_layer8Check_stateChanged (int state);
|
||||||
|
void pdrestart();
|
||||||
|
void stdout();
|
||||||
|
void on_video_stateChanged(int state);
|
||||||
|
|
||||||
|
//Audio
|
||||||
|
|
||||||
|
void newPeer_audio();
|
||||||
|
void newmessage_audio();
|
||||||
|
void newconexion_audio();
|
||||||
|
void on_readDMX_audio_stateChanged(int state);
|
||||||
|
void on_layer1Add_audio_valueChanged();
|
||||||
|
void on_layer1Check_audio_stateChanged (int state);
|
||||||
|
void on_layer2Add_audio_valueChanged();
|
||||||
|
void on_layer2Check_audio_stateChanged (int state);
|
||||||
|
void on_layer3Add_audio_valueChanged();
|
||||||
|
void on_layer3Check_audio_stateChanged (int state);
|
||||||
|
void on_layer4Add_audio_valueChanged();
|
||||||
|
void on_layer4Check_audio_stateChanged (int state);
|
||||||
|
void on_layer5Add_audio_valueChanged();
|
||||||
|
void on_layer5Check_audio_stateChanged (int state);
|
||||||
|
void on_layer6Add_audio_valueChanged();
|
||||||
|
void on_layer6Check_audio_stateChanged (int state);
|
||||||
|
void on_layer7Add_audio_valueChanged();
|
||||||
|
void on_layer7Check_audio_stateChanged (int state);
|
||||||
|
void on_layer8Add_audio_valueChanged();
|
||||||
|
void on_layer8Check_audio_stateChanged (int state);
|
||||||
|
void pdrestart_audio();
|
||||||
|
void stdout_audio();
|
||||||
|
void on_audio_stateChanged(int state);
|
||||||
|
|
||||||
|
// File configuration
|
||||||
|
|
||||||
|
void open();
|
||||||
|
void save();
|
||||||
|
|
||||||
|
// Previews
|
||||||
|
|
||||||
|
void previewMaster();
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // LIBREMEDIASERVER_H
|
34
libremediaserver.pro
Normal file
34
libremediaserver.pro
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
TEMPLATE = app
|
||||||
|
TARGET = libremediaserver
|
||||||
|
QT += network script
|
||||||
|
CONFIG += debug
|
||||||
|
DESTDIR = ./debug
|
||||||
|
|
||||||
|
HEADERS += libremediaserver.h \
|
||||||
|
citp-lib.h \
|
||||||
|
PacketCreator.h \
|
||||||
|
PeerInformationSocket.h \
|
||||||
|
msex.h \
|
||||||
|
CITPDefines.h \
|
||||||
|
MSEXDefines.h
|
||||||
|
|
||||||
|
SOURCES += main.cpp \
|
||||||
|
libremediaserver.cpp \
|
||||||
|
citp-lib.cpp \
|
||||||
|
PacketCreator.cpp \
|
||||||
|
PeerInformationSocket.cpp \
|
||||||
|
msex.cpp
|
||||||
|
|
||||||
|
FORMS += \
|
||||||
|
libremediaserver.ui
|
||||||
|
|
||||||
|
#INCLUDEPATH += ./
|
||||||
|
|
||||||
|
LIBS += -L./debug
|
||||||
|
|
||||||
|
#win32:CONFIG(release, debug|release): LIBS += -L$$PWD/../debug/release/ -lcitp
|
||||||
|
#else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/../debug/debug/ -lcitp
|
||||||
|
#else:symbian: LIBS += -lcitp
|
||||||
|
#else:unix: LIBS += -L$$PWD/../debug/ -lcitp
|
||||||
|
#INCLUDEPATH += $$PWD/../debug
|
||||||
|
#DEPENDPATH += $$PWD/../debug
|
1151
libremediaserver.ui
Normal file
1151
libremediaserver.ui
Normal file
File diff suppressed because it is too large
Load diff
28
main.cpp
Normal file
28
main.cpp
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
/*
|
||||||
|
Libre Media Server - A Media Server Sotfware for stage and performing
|
||||||
|
Copyright (C) 2012-2013 Santiago Noreña libremediaserver@gmail.com
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <QApplication>
|
||||||
|
#include "libremediaserver.h"
|
||||||
|
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
QApplication app(argc, argv);
|
||||||
|
libreMediaServer libreMediaServer;
|
||||||
|
libreMediaServer.show();
|
||||||
|
return app.exec();
|
||||||
|
}
|
614
msex.cpp
Normal file
614
msex.cpp
Normal file
|
@ -0,0 +1,614 @@
|
||||||
|
/*
|
||||||
|
Pure Media Server - A Media Server Sotfware for stage and performing
|
||||||
|
Copyright (C) 2012-2013 Santiago Noreña puremediaserver@gmail.com
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "msex.h"
|
||||||
|
//#include "libremediaserver.h"
|
||||||
|
#include "MSEXDefines.h"
|
||||||
|
#include "PacketCreator.h"
|
||||||
|
#include "citp-lib.h"
|
||||||
|
|
||||||
|
#include <QtDebug>
|
||||||
|
#include <QTimer>
|
||||||
|
#include <QTcpServer>
|
||||||
|
#include <QTcpSocket>
|
||||||
|
#include <QDir>
|
||||||
|
#include <QDateTime>
|
||||||
|
|
||||||
|
msex::msex(QObject *parent)
|
||||||
|
: QObject(parent),
|
||||||
|
m_peerState(STATE),
|
||||||
|
m_peerName(NAME),
|
||||||
|
m_listeningPort(LISTENTCPPORT)
|
||||||
|
|
||||||
|
{
|
||||||
|
// Iniciamos la lista de estatus de layer
|
||||||
|
LayerStatus layermodel;
|
||||||
|
m_layers.clear();
|
||||||
|
int i;
|
||||||
|
for (i=0; i < LAYER_NUMBER; i++)
|
||||||
|
{
|
||||||
|
layermodel.LayerNumber = i;
|
||||||
|
layermodel.PhysicalOutput = 0x01;
|
||||||
|
layermodel.MediaLibraryNumber = 0x00;
|
||||||
|
layermodel.MediaNumber = i;
|
||||||
|
layermodel.Name = "medianame";
|
||||||
|
layermodel.MediaPosition = 0x1111;
|
||||||
|
layermodel.MediaLength = 0x2222;
|
||||||
|
layermodel.MediaFPS = 25;
|
||||||
|
m_layers.append(layermodel);
|
||||||
|
}
|
||||||
|
// Variables para el buffer de LSTA
|
||||||
|
m_bufferLen = 0x00;
|
||||||
|
m_buffer = NULL;
|
||||||
|
m_pathmedia.clear();
|
||||||
|
// Inicio del TCP Server
|
||||||
|
m_tcpServer = new QTcpServer(this);
|
||||||
|
Q_CHECK_PTR(m_tcpServer);
|
||||||
|
if (!m_tcpServer)
|
||||||
|
qWarning("error TCP Server no creado");
|
||||||
|
if (!m_tcpServer->listen(QHostAddress::Any, LISTENTCPPORT))
|
||||||
|
{
|
||||||
|
qWarning("error creando tcpServer");
|
||||||
|
}
|
||||||
|
connect(m_tcpServer, SIGNAL(newConnection()),
|
||||||
|
this, SLOT(newPeer()));
|
||||||
|
// Timer for frame preview
|
||||||
|
n_timer = new QTimer(this);
|
||||||
|
Q_CHECK_PTR(n_timer);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Propiedades de clase
|
||||||
|
|
||||||
|
msex::~msex()
|
||||||
|
{
|
||||||
|
if (m_tcpServer)
|
||||||
|
m_tcpServer->close();
|
||||||
|
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
QString msex::peerName() const
|
||||||
|
{
|
||||||
|
return m_peerName;
|
||||||
|
}
|
||||||
|
|
||||||
|
QString msex::peerState() const
|
||||||
|
{
|
||||||
|
return m_peerState;
|
||||||
|
}
|
||||||
|
|
||||||
|
QString msex::peerHost() const
|
||||||
|
{
|
||||||
|
return m_host.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
quint16 msex::peerListeningPort() const
|
||||||
|
{
|
||||||
|
return m_listeningPort;
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
bool msex::newPeer()
|
||||||
|
{
|
||||||
|
m_tcpSocket = m_tcpServer->nextPendingConnection();
|
||||||
|
connect(m_tcpSocket, SIGNAL(readyRead()),
|
||||||
|
this, SLOT(handleReadyRead()));
|
||||||
|
// Ahora tenemos que mandar un Sinf para MSEX 1.1 y 1.0
|
||||||
|
//Creamos un paquete SINf
|
||||||
|
int bufferLen = sizeof(struct CITP_MSEX_10_SINF);
|
||||||
|
unsigned char * buffer = PacketCreator::createSINFPacket(bufferLen);
|
||||||
|
if (!buffer)
|
||||||
|
{
|
||||||
|
qDebug() << "msex::new peer:createSINFPacket() failed";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
// Mandamos el paquete
|
||||||
|
if (!msex::sendPacket(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "msex::new peer: Send SInf Message failed";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
qDebug() << "msex::new peer: SInf Sent...";
|
||||||
|
return true;
|
||||||
|
/* Iniciamos el layer Status
|
||||||
|
// Creamos un paquete LSTA
|
||||||
|
m_bufferLen = sizeof(struct CITP_MSEX_12_LSta);
|
||||||
|
unsigned char *buffer2 = PacketCreator::createLSTAPacket(m_layers, m_bufferLen);
|
||||||
|
if (!buffer2)
|
||||||
|
{
|
||||||
|
qDebug() << "createLSTAPacket() failed";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
m_buffer = buffer2;
|
||||||
|
// Iniciamos el temporizador para mandar LSTA
|
||||||
|
// n_timer->start();
|
||||||
|
// qDebug("Start sending LSta");
|
||||||
|
transmitlsta();
|
||||||
|
return true;*/
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
bool msex::transmitlsta()
|
||||||
|
{
|
||||||
|
if (!msex::sendPacket(m_buffer, m_bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "msex::LSta Message failed";
|
||||||
|
qDebug() << "Peer disconnected?";
|
||||||
|
n_timer->stop();
|
||||||
|
m_tcpSocket->close();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}*/
|
||||||
|
|
||||||
|
// Lectura de paquetes
|
||||||
|
|
||||||
|
void msex::handleReadyRead()
|
||||||
|
{
|
||||||
|
while(m_tcpSocket->bytesAvailable())
|
||||||
|
{
|
||||||
|
QByteArray peekArray = m_tcpSocket->peek(12);
|
||||||
|
if (12 != peekArray.size())
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (peekArray[0] != 'C' &&
|
||||||
|
peekArray[1] != 'I' &&
|
||||||
|
peekArray[2] != 'T' &&
|
||||||
|
peekArray[3] != 'P')
|
||||||
|
{
|
||||||
|
// remove the first byte and try again
|
||||||
|
QByteArray b = m_tcpSocket->read(1);
|
||||||
|
qDebug() << "Discarding byte:" << b[0];
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
quint32 messageSize = 0;
|
||||||
|
messageSize = peekArray[11];
|
||||||
|
messageSize <<= 8;
|
||||||
|
messageSize |= peekArray[10];
|
||||||
|
messageSize <<= 8;
|
||||||
|
messageSize |= peekArray[9];
|
||||||
|
messageSize <<= 8;
|
||||||
|
messageSize |= peekArray[8];
|
||||||
|
if (messageSize > m_tcpSocket->bytesAvailable())
|
||||||
|
{
|
||||||
|
qDebug() << "Not enough bytes available, only have:" << m_tcpSocket->bytesAvailable();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
QByteArray byteArray = m_tcpSocket->read(messageSize);
|
||||||
|
parsePacket(byteArray);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Mandar paquetes
|
||||||
|
|
||||||
|
bool msex::sendPacket(const unsigned char *buffer, int bufferLen)
|
||||||
|
{
|
||||||
|
if (!m_tcpSocket)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (QAbstractSocket::ConnectedState != m_tcpSocket->state())
|
||||||
|
{
|
||||||
|
qDebug() << "msex::sendPacket() - Socket not connected";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (bufferLen != m_tcpSocket->write((const char*)buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "msex::sendPacket() write failed:" << m_tcpSocket->error();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
delete buffer;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Overload Send Packet
|
||||||
|
|
||||||
|
bool msex::sendPacket(const char *buffer, int bufferLen)
|
||||||
|
{
|
||||||
|
if (!m_tcpSocket)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (QAbstractSocket::ConnectedState != m_tcpSocket->state())
|
||||||
|
{
|
||||||
|
qDebug() << "msex::sendPacket() - Socket not connected";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (bufferLen != m_tcpSocket->write(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "msex::sendPacket() write failed:" << m_tcpSocket->error();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Determina qué tipo de paquete es
|
||||||
|
void msex::parsePacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_Header *citpHeader = (struct CITP_Header*)data;
|
||||||
|
|
||||||
|
// CITP header
|
||||||
|
if (citpHeader->Cookie != COOKIE_CITP)
|
||||||
|
{
|
||||||
|
qDebug() << "parsePacket: invalid Cookie" << citpHeader->Cookie;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
if (citpHeader->VersionMajor != 0x01)
|
||||||
|
{
|
||||||
|
qDebug() << "parsePacket: invalid VersionMajor:" << citpHeader->VersionMajor;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (citpHeader->VersionMinor != 0x00)
|
||||||
|
{
|
||||||
|
qDebug() << "parsePacket: invalid VersionMinor:" << citpHeader->VersionMinor;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
switch (citpHeader->ContentType)
|
||||||
|
{
|
||||||
|
case COOKIE_PINF:
|
||||||
|
qDebug() << "parsePacket: got COOKIE_PINF packet on TCP Socket...";
|
||||||
|
parsePINFPacket(byteArray);
|
||||||
|
break;
|
||||||
|
case COOKIE_MSEX:
|
||||||
|
parseMSEXPacket(byteArray);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
qDebug() << "parsePacket: unknown ContentType:" << citpHeader->ContentType;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//Process PINF Packets
|
||||||
|
void msex::parsePINFPacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_PINF_Header *pinfHeader = (struct CITP_PINF_Header*)data;
|
||||||
|
switch (pinfHeader->ContentType)
|
||||||
|
{
|
||||||
|
case COOKIE_PINF_PNAM:
|
||||||
|
{
|
||||||
|
int offset = sizeof(struct CITP_PINF_Header);
|
||||||
|
int size = byteArray.size();
|
||||||
|
char * name = new char[size];
|
||||||
|
memcpy(name,(data+offset),size);
|
||||||
|
QString namei = name;
|
||||||
|
qDebug() << "Ploc arrives. NAME:" << namei;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Procesa paquete MSEX
|
||||||
|
void msex::parseMSEXPacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_MSEX_Header *msexHeader = (struct CITP_MSEX_Header*)data;
|
||||||
|
switch (msexHeader->ContentType)
|
||||||
|
{
|
||||||
|
case COOKIE_MSEX_CINF:
|
||||||
|
parseCINFPacket(byteArray);
|
||||||
|
break;
|
||||||
|
/* case COOKIE_MSEX_NACK:
|
||||||
|
parseNACKPacket(byteArray);
|
||||||
|
break;*/
|
||||||
|
case COOKIE_MSEX_GELI:
|
||||||
|
parseGELIPacket(byteArray);
|
||||||
|
break;
|
||||||
|
case COOKIE_MSEX_GEIN:
|
||||||
|
parseGEINPacket(byteArray);
|
||||||
|
break;
|
||||||
|
case COOKIE_MSEX_GELT:
|
||||||
|
parseGELTPacket();
|
||||||
|
break;
|
||||||
|
case COOKIE_MSEX_GETH:
|
||||||
|
parseGETHPacket(byteArray);
|
||||||
|
break;
|
||||||
|
case COOKIE_MSEX_GVSR:
|
||||||
|
parseGVSRPacket();
|
||||||
|
break;
|
||||||
|
case COOKIE_MSEX_RQST:
|
||||||
|
parseRQSTPacket(byteArray);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
qDebug() << "parseMSEXPacket: unknown ContentType:" << msexHeader->ContentType ;
|
||||||
|
msex::sendNACK(msexHeader->ContentType);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::parseCINFPacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_MSEX_CInf *cinf = (struct CITP_MSEX_CInf*)data;
|
||||||
|
int size = 2 * cinf->SupportedMSEXVersionsCount;
|
||||||
|
unsigned short * versions = new unsigned short[size];
|
||||||
|
memcpy(versions, &cinf->SupportedMSEXVersions, size);
|
||||||
|
for (int i=0; i < cinf->SupportedMSEXVersionsCount;i++){
|
||||||
|
qDebug() << "CInf arrives. Suported Versions: " <<versions[i];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::parseGELIPacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_MSEX_11_GELI *geliPacket = (struct CITP_MSEX_11_GELI*)data;
|
||||||
|
if (geliPacket->LibraryType != 0x01)
|
||||||
|
{
|
||||||
|
qDebug() << "parseGELIPacket:Not library type supported, only MEDIA now 0x01";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Creamos un paquete ELin
|
||||||
|
int bufferLen = sizeof(struct CITP_MSEX_ELIn);
|
||||||
|
unsigned char * buffer = PacketCreator::createELINPacket(m_media, bufferLen);
|
||||||
|
if (!buffer)
|
||||||
|
{
|
||||||
|
qDebug() << "parseGELIPacket:createELINPacket() failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Mandamos el paquete
|
||||||
|
if (!msex::sendPacket(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "parseGELIPacket: Send ELin Message failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
qDebug() << "parseGELIPacket finish ok. ELin Sent...";
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::parseGEINPacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_MSEX_10_GEIn *geinPacket = (struct CITP_MSEX_10_GEIn*)data;
|
||||||
|
qDebug() << "GEIn arrives: Elemet count:" << geinPacket->ElementCount << "Libray Id:" << geinPacket->LibraryId << "Library Type:" << geinPacket->LibraryType;
|
||||||
|
int bufferLen = sizeof (struct CITP_MSEX_10_MEIn);
|
||||||
|
if (!(geinPacket->LibraryId < m_media.size())) {
|
||||||
|
qDebug() << "Library ID exceeds size list";
|
||||||
|
/*unsigned char * buffer = PacketCreator::createMEINPacket(m_media.at(geinPacket->LibraryId),bufferLen);
|
||||||
|
if (!buffer)
|
||||||
|
{
|
||||||
|
qDebug() << "parseGEINPacket:createMEINPacket() failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Mandamos el paquete
|
||||||
|
if (!msex::sendPacket(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "parseGEINPacket: Send MEIn Message failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
qDebug() << "parseGEINPacket finish ok. MEIn Sent...";*/
|
||||||
|
}
|
||||||
|
|
||||||
|
else {
|
||||||
|
unsigned char * buffer = PacketCreator::createMEINPacket(m_media.at(geinPacket->LibraryId),bufferLen);
|
||||||
|
if (!buffer)
|
||||||
|
{
|
||||||
|
qDebug() << "parseGEINPacket:createMEINPacket() failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Mandamos el paquete
|
||||||
|
if (!msex::sendPacket(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "parseGEINPacket: Send MEIn Message failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::parseGELTPacket()
|
||||||
|
{
|
||||||
|
// const char *data = byteArray.constData();
|
||||||
|
// struct CITP_MSEX_12_GELT *geltPacket = (struct CITP_MSEX_12_GELT*)data;
|
||||||
|
qDebug() << "parseGELTPacket: GELT arrives...";
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::parseGETHPacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_MSEX_10_GETh *gethPacket = (struct CITP_MSEX_10_GETh*)data;
|
||||||
|
qDebug() << "GETh arrives. Format:"<< gethPacket->ThumbnailFormat<<"Width:"<<gethPacket->ThumbnailWidth<<"Height:"<<gethPacket->ThumbnailHeight;
|
||||||
|
qDebug() << "Library Number:"<<gethPacket->LibraryNumber<<"Element COunt:"<<gethPacket->ElementCount<<"ElementNumber:"<<gethPacket->ElementNumber;
|
||||||
|
int bufferLen = sizeof (struct CITP_MSEX_10_ETHN);
|
||||||
|
if (!(gethPacket->LibraryNumber < m_media.size())) {
|
||||||
|
qDebug() << "Library ID exceeds size list";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
MediaLibrary mediai = m_media.at(gethPacket->LibraryNumber);
|
||||||
|
if (mediai.m_ElementCount <= gethPacket->ElementNumber){
|
||||||
|
qDebug() << "Element Number is greater than the elements in library";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
unsigned char * buffer = PacketCreator::createETHNPacket(m_pathmedia, mediai, gethPacket->ElementNumber, bufferLen);
|
||||||
|
if (!buffer)
|
||||||
|
{
|
||||||
|
qDebug() << "parseGETHPacket:createETHNPacket() failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Mandamos el paquete
|
||||||
|
if (!msex::sendPacket(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "parseGETHPacket: Send ETHN Message failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::parseGVSRPacket()
|
||||||
|
{
|
||||||
|
int bufferLen;
|
||||||
|
// Create a VSrc message
|
||||||
|
const char * buffer = PacketCreator::createVSRCPacket(bufferLen);
|
||||||
|
if (!buffer)
|
||||||
|
{
|
||||||
|
qDebug() << "parseGVSRacket:createVSRCPacket() failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Mandamos el paquete
|
||||||
|
if (!msex::sendPacket(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "parseGVSRPacket: Send VRSC Message failed";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
delete buffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::parseRQSTPacket(const QByteArray &byteArray)
|
||||||
|
{
|
||||||
|
const char *data = byteArray.constData();
|
||||||
|
struct CITP_MSEX_RqSt *Packet = (struct CITP_MSEX_RqSt*)data;
|
||||||
|
// Here we need start the streaming MagicQ 88x64 RGB8 1 FPS
|
||||||
|
// Iniciamos el timer
|
||||||
|
if (!n_timer->isActive()) {
|
||||||
|
n_timer->setInterval(1000 * Packet->fps);
|
||||||
|
n_timer->start();
|
||||||
|
connect(n_timer, SIGNAL(timeout()), this, SLOT(sendFrame()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool msex::sendNACK(quint32 header)
|
||||||
|
{
|
||||||
|
int bufferLen;
|
||||||
|
unsigned char *buffer = PacketCreator::createNACKPacket(header, bufferLen);
|
||||||
|
if (!buffer)
|
||||||
|
{
|
||||||
|
qDebug() << "createNACKPacket() failed";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!sendPacket(buffer, bufferLen))
|
||||||
|
{
|
||||||
|
qDebug() << "sendNACK failed";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Fin de mensajes MSEX
|
||||||
|
|
||||||
|
bool msex::updatemedia()
|
||||||
|
{
|
||||||
|
qDebug()<<"Actualizando biblioteca de medias en " << m_pathmedia;
|
||||||
|
QDir dir;
|
||||||
|
dir.cd(m_pathmedia);
|
||||||
|
m_media.clear();
|
||||||
|
// Miramos cuantas librerías tenemos en /video
|
||||||
|
if (!dir.cd("video"))
|
||||||
|
{ qWarning("Cannot cd to the video directory");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
dir.setFilter(QDir::Dirs | QDir::NoSymLinks | QDir::NoDotAndDotDot);
|
||||||
|
QFileInfoList filelist = dir.entryInfoList();
|
||||||
|
dir.setFilter(QDir::Files);
|
||||||
|
QFileInfo fileInfo;
|
||||||
|
struct MediaLibrary mediai;
|
||||||
|
int i;
|
||||||
|
for (i = 0; i < filelist.size(); ++i) {
|
||||||
|
fileInfo = filelist.at(i);
|
||||||
|
QString name = fileInfo.baseName();
|
||||||
|
dir.cd(fileInfo.baseName());
|
||||||
|
mediai.m_Id = i;
|
||||||
|
mediai.m_DMXRangeMax = i;
|
||||||
|
mediai.m_DMXRangeMin = i;
|
||||||
|
mediai.m_Name = name;
|
||||||
|
// mediai.m_LibraryCount = 0; msex 1.2
|
||||||
|
mediai.m_ElementCount = dir.count();
|
||||||
|
mediai.m_MediaInformation = getMediaInformation(dir);
|
||||||
|
dir.cdUp();
|
||||||
|
m_media.append(mediai);
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
// Miramos las librerías en /imagenes
|
||||||
|
i++;
|
||||||
|
dir.cd(m_pathmedia);
|
||||||
|
if (!dir.cd("image"))
|
||||||
|
{
|
||||||
|
qWarning("Can not find images dir");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
mediai.m_Id = i;
|
||||||
|
mediai.m_DMXRangeMax = i;
|
||||||
|
mediai.m_DMXRangeMin = i;
|
||||||
|
mediai.m_Name = "Images";
|
||||||
|
// mediai.m_LibraryCount = 0; msex 1.2
|
||||||
|
mediai.m_ElementCount = dir.count();
|
||||||
|
mediai.m_MediaInformation = getMediaInformation(dir);
|
||||||
|
dir.cdUp();
|
||||||
|
m_media.append(mediai);
|
||||||
|
|
||||||
|
// Creamos una vacía
|
||||||
|
i++;
|
||||||
|
mediai.m_Id = i;
|
||||||
|
mediai.m_DMXRangeMax = i;
|
||||||
|
mediai.m_DMXRangeMin = i;
|
||||||
|
mediai.m_Name = "empty";
|
||||||
|
// mediai.m_LibraryCount = 0; msex 1.2
|
||||||
|
mediai.m_ElementCount = 0x00;
|
||||||
|
// mediai.m_MediaInformation = NULL;
|
||||||
|
m_media.append(mediai);
|
||||||
|
*/
|
||||||
|
// Lanzar aquí la creación de thumbs?
|
||||||
|
|
||||||
|
// Mandamos las señal ELup (Msex 1.2)
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
QList<MediaInformation> msex::getMediaInformation(QDir dir)
|
||||||
|
{
|
||||||
|
QList<MediaInformation> mediaList;
|
||||||
|
MediaInformation mediainf;
|
||||||
|
dir.setFilter(QDir::Files);
|
||||||
|
QFileInfoList filelist = dir.entryInfoList();
|
||||||
|
QFileInfo fileInfo;
|
||||||
|
for (int i = 0; i < filelist.size(); ++i) {
|
||||||
|
fileInfo = filelist.at(i);
|
||||||
|
QDateTime date = fileInfo.created();
|
||||||
|
mediainf.Number = i;
|
||||||
|
mediainf.DMXRangeMin = i;
|
||||||
|
mediainf.DMXRangeMax = i;
|
||||||
|
mediainf.MediaName = fileInfo.baseName();
|
||||||
|
// mediainf.MediaVersionTimestamp = date.toMSecsSinceEpoch();
|
||||||
|
mediainf.MediaWidth = 320;
|
||||||
|
mediainf.MediaHeight = 200;
|
||||||
|
mediainf.MediaLength = 1000;
|
||||||
|
mediainf.MediaFPS = 25;
|
||||||
|
mediaList.append(mediainf);
|
||||||
|
}
|
||||||
|
return mediaList;
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::setpath(QString path)
|
||||||
|
{
|
||||||
|
//m_pathmedia = NULL;
|
||||||
|
m_pathmedia.clear();
|
||||||
|
m_pathmedia.append(path);
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::startCitp(quint32 ipadd)
|
||||||
|
{
|
||||||
|
m_citp = new CITPLib(this);
|
||||||
|
Q_CHECK_PTR(m_citp);
|
||||||
|
if (!m_citp->createPeerInformationSocket(NAME, STATE, ipadd))
|
||||||
|
{
|
||||||
|
qDebug()<<("CreatePeerInformationSocket failed");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void msex::sendFrame()
|
||||||
|
{
|
||||||
|
emit frameRequest();
|
||||||
|
}
|
109
msex.h
Normal file
109
msex.h
Normal file
|
@ -0,0 +1,109 @@
|
||||||
|
/*
|
||||||
|
Libre Media Server - A Media Server Sotfware for stage and performing
|
||||||
|
Copyright (C) 2012-2013 Santiago Noreña
|
||||||
|
belfegor <AT> gmail <DOT> com
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* This class do all the MSEX work */
|
||||||
|
|
||||||
|
#ifndef MSEX_H
|
||||||
|
#define MSEX_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include <QHostAddress>
|
||||||
|
|
||||||
|
#include "MSEXDefines.h"
|
||||||
|
|
||||||
|
class QTimer;
|
||||||
|
class QTcpSocket;
|
||||||
|
class QTcpServer;
|
||||||
|
class QDir;
|
||||||
|
class CITPLib;
|
||||||
|
|
||||||
|
class msex : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
msex(QObject *parent);
|
||||||
|
virtual ~msex();
|
||||||
|
// virtual QString peerName() const;
|
||||||
|
// virtual QString peerState() const;
|
||||||
|
// virtual QString peerHost() const;
|
||||||
|
// virtual quint16 peerListeningPort() const;
|
||||||
|
// void previewLayer1();
|
||||||
|
|
||||||
|
bool CreateMSEXSocket();
|
||||||
|
bool updatemedia();
|
||||||
|
virtual void setpath(QString path); // path to media dir
|
||||||
|
void startCitp(quint32 ipadd); // Start the Peer Informatio Socket
|
||||||
|
bool sendPacket(const unsigned char *buffer, int bufferLen);
|
||||||
|
|
||||||
|
QTimer *n_timer; // Frame Request
|
||||||
|
QList<LayerStatus> m_layers;
|
||||||
|
QList<MediaLibrary> m_media;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
CITPLib *m_citp; // CITP Peer. PLOc and frame transmit
|
||||||
|
QString m_pathmedia;
|
||||||
|
unsigned char * m_buffer;
|
||||||
|
int m_bufferLen;
|
||||||
|
QString m_peerState;
|
||||||
|
QString m_peerName;
|
||||||
|
QHostAddress m_host;
|
||||||
|
quint16 m_listeningPort;
|
||||||
|
QTcpServer *m_tcpServer;
|
||||||
|
QTcpSocket *m_tcpSocket;
|
||||||
|
|
||||||
|
bool sendPacket(const char *buffer, int bufferLen);
|
||||||
|
bool sendNACK(quint32 header);
|
||||||
|
|
||||||
|
// Procesado de paquetes MSEX
|
||||||
|
void parsePacket(const QByteArray &byteArray);
|
||||||
|
void parsePINFPacket(const QByteArray &byteArray);
|
||||||
|
void parseMSEXPacket(const QByteArray &bytearray);
|
||||||
|
void parseCINFPacket(const QByteArray &byteArray);
|
||||||
|
void parseNACKPacket(const QByteArray &byteArray);
|
||||||
|
void parseGELIPacket(const QByteArray &byteArray);
|
||||||
|
void parseGEINPacket(const QByteArray &byteArray);
|
||||||
|
void parseGLEIPacket(const QByteArray &byteArray);
|
||||||
|
void parseGELTPacket();
|
||||||
|
void parseGETHPacket(const QByteArray &byteArray);
|
||||||
|
void parseGVSRPacket();
|
||||||
|
void parseGELNPacket(const QByteArray &byteArray);
|
||||||
|
void parseRQSTPacket(const QByteArray &byteArray);
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
QList<MediaInformation> getMediaInformation(QDir dir);
|
||||||
|
|
||||||
|
public slots:
|
||||||
|
|
||||||
|
protected slots:
|
||||||
|
|
||||||
|
void handleReadyRead();
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
|
||||||
|
bool newPeer();
|
||||||
|
void sendFrame(); // Slot temporizado para mandar una señal a libremediaserver::sendframe() para mandar un frame
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void frameRequest();
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // MEDIASERVER_H
|
242
pms-audio.pd
Normal file
242
pms-audio.pd
Normal file
|
@ -0,0 +1,242 @@
|
||||||
|
#N canvas 475 220 838 622 10;
|
||||||
|
#N canvas 341 118 1016 665 dmx 0;
|
||||||
|
#X obj -7 437 list split;
|
||||||
|
#X obj 99 444 list split;
|
||||||
|
#X obj 50 385 - 1;
|
||||||
|
#X obj 156 386 - 1;
|
||||||
|
#X msg 613 211 close;
|
||||||
|
#X obj 202 447 list split;
|
||||||
|
#X obj 259 390 - 1;
|
||||||
|
#X obj 308 446 list split;
|
||||||
|
#X obj 365 367 - 1;
|
||||||
|
#X obj 469 251 ola2pd;
|
||||||
|
#X msg 391 201 universe \$1;
|
||||||
|
#X msg 560 208 open;
|
||||||
|
#X obj 21 520 outlet;
|
||||||
|
#X obj 127 523 outlet;
|
||||||
|
#X obj 230 523 outlet;
|
||||||
|
#X obj 336 524 outlet;
|
||||||
|
#X obj 434 457 list split;
|
||||||
|
#X obj 491 378 - 1;
|
||||||
|
#X obj 462 535 outlet;
|
||||||
|
#X obj 558 448 list split;
|
||||||
|
#X obj 615 369 - 1;
|
||||||
|
#X obj 586 526 outlet;
|
||||||
|
#X obj 675 449 list split;
|
||||||
|
#X obj 744 353 - 1;
|
||||||
|
#X obj 703 527 outlet;
|
||||||
|
#X obj 800 445 list split;
|
||||||
|
#X obj 857 366 - 1;
|
||||||
|
#X obj 828 523 outlet;
|
||||||
|
#X obj -7 379 spigot;
|
||||||
|
#X obj 95 402 spigot;
|
||||||
|
#X obj 204 397 spigot;
|
||||||
|
#X obj 314 393 spigot;
|
||||||
|
#X obj 421 395 spigot;
|
||||||
|
#X obj 556 405 spigot;
|
||||||
|
#X obj 672 407 spigot;
|
||||||
|
#X obj 798 394 spigot;
|
||||||
|
#X obj 64 236 r layer1;
|
||||||
|
#X obj 389 152 r universe;
|
||||||
|
#X obj 143 241 r layer2;
|
||||||
|
#X obj 557 124 r ola;
|
||||||
|
#X obj 224 240 r layer3;
|
||||||
|
#X obj 309 240 r layer4;
|
||||||
|
#X obj 484 312 r layer5;
|
||||||
|
#X obj 635 291 r layer6;
|
||||||
|
#X obj 727 294 r layer7;
|
||||||
|
#X obj 833 281 r layer8;
|
||||||
|
#X obj 21 479 list split 32;
|
||||||
|
#X obj 127 482 list split 32;
|
||||||
|
#X obj 230 482 list split 32;
|
||||||
|
#X obj 336 483 list split 32;
|
||||||
|
#X obj 462 494 list split 32;
|
||||||
|
#X obj 586 485 list split 32;
|
||||||
|
#X obj 703 486 list split 32;
|
||||||
|
#X obj 828 482 list split 32;
|
||||||
|
#X floatatom 319 191 5 0 0 0 - - -;
|
||||||
|
#X floatatom 655 182 5 0 0 0 - - -;
|
||||||
|
#X obj 522 204 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
|
||||||
|
-1 -1;
|
||||||
|
#X obj 690 221 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
|
||||||
|
-1 -1;
|
||||||
|
#X obj 560 178 select 1;
|
||||||
|
#X obj 420 326 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
|
||||||
|
-1 -1;
|
||||||
|
#X floatatom 2 572 5 0 0 0 - - -;
|
||||||
|
#X connect 0 1 46 0;
|
||||||
|
#X connect 1 1 47 0;
|
||||||
|
#X connect 2 0 0 1;
|
||||||
|
#X connect 3 0 1 1;
|
||||||
|
#X connect 4 0 9 0;
|
||||||
|
#X connect 5 1 48 0;
|
||||||
|
#X connect 6 0 5 1;
|
||||||
|
#X connect 7 1 49 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 9 0 28 0;
|
||||||
|
#X connect 9 0 29 0;
|
||||||
|
#X connect 9 0 30 0;
|
||||||
|
#X connect 9 0 31 0;
|
||||||
|
#X connect 9 0 32 0;
|
||||||
|
#X connect 9 0 33 0;
|
||||||
|
#X connect 9 0 34 0;
|
||||||
|
#X connect 9 0 35 0;
|
||||||
|
#X connect 9 0 59 0;
|
||||||
|
#X connect 10 0 9 0;
|
||||||
|
#X connect 11 0 9 0;
|
||||||
|
#X connect 16 1 50 0;
|
||||||
|
#X connect 17 0 16 1;
|
||||||
|
#X connect 19 1 51 0;
|
||||||
|
#X connect 20 0 19 1;
|
||||||
|
#X connect 22 1 52 0;
|
||||||
|
#X connect 23 0 22 1;
|
||||||
|
#X connect 25 1 53 0;
|
||||||
|
#X connect 26 0 25 1;
|
||||||
|
#X connect 28 0 0 0;
|
||||||
|
#X connect 29 0 1 0;
|
||||||
|
#X connect 30 0 5 0;
|
||||||
|
#X connect 31 0 7 0;
|
||||||
|
#X connect 32 0 16 0;
|
||||||
|
#X connect 33 0 19 0;
|
||||||
|
#X connect 34 0 22 0;
|
||||||
|
#X connect 35 0 25 0;
|
||||||
|
#X connect 36 0 2 0;
|
||||||
|
#X connect 36 0 28 1;
|
||||||
|
#X connect 37 0 10 0;
|
||||||
|
#X connect 37 0 54 0;
|
||||||
|
#X connect 38 0 29 1;
|
||||||
|
#X connect 38 0 3 0;
|
||||||
|
#X connect 39 0 55 0;
|
||||||
|
#X connect 39 0 58 0;
|
||||||
|
#X connect 40 0 30 0;
|
||||||
|
#X connect 40 0 6 0;
|
||||||
|
#X connect 41 0 31 0;
|
||||||
|
#X connect 41 0 8 0;
|
||||||
|
#X connect 42 0 32 1;
|
||||||
|
#X connect 42 0 17 0;
|
||||||
|
#X connect 43 0 33 1;
|
||||||
|
#X connect 43 0 20 0;
|
||||||
|
#X connect 44 0 34 1;
|
||||||
|
#X connect 44 0 23 0;
|
||||||
|
#X connect 45 0 26 0;
|
||||||
|
#X connect 45 0 35 1;
|
||||||
|
#X connect 46 0 12 0;
|
||||||
|
#X connect 46 0 60 0;
|
||||||
|
#X connect 47 0 13 0;
|
||||||
|
#X connect 48 0 14 0;
|
||||||
|
#X connect 49 0 15 0;
|
||||||
|
#X connect 50 0 18 0;
|
||||||
|
#X connect 51 0 21 0;
|
||||||
|
#X connect 52 0 24 0;
|
||||||
|
#X connect 53 0 27 0;
|
||||||
|
#X connect 58 0 11 0;
|
||||||
|
#X connect 58 0 56 0;
|
||||||
|
#X connect 58 1 4 0;
|
||||||
|
#X connect 58 1 57 0;
|
||||||
|
#X coords 0 665 1 664 1 1 0;
|
||||||
|
#X restore -23 245 pd dmx;
|
||||||
|
#X obj -249 348 layer_audio;
|
||||||
|
#X msg 433 64 \; pd dsp 1;
|
||||||
|
#X msg 509 64 \; pd dsp 0;
|
||||||
|
#X obj 431 -3 loadbang;
|
||||||
|
#X msg -249 380 send 1 \$1;
|
||||||
|
#X obj -16 560 netsend;
|
||||||
|
#X msg -136 387 send 2 \$1;
|
||||||
|
#X msg -22 390 send 3 \$1;
|
||||||
|
#X msg 75 392 send 4 \$1;
|
||||||
|
#X msg 163 389 send 5 \$1;
|
||||||
|
#X msg 255 393 send 6 \$1;
|
||||||
|
#X msg 354 395 send 7 \$1;
|
||||||
|
#X msg 448 395 send 8 \$1;
|
||||||
|
#X obj 373 459 loadbang;
|
||||||
|
#X obj 373 481 delay 50;
|
||||||
|
#X msg 373 503 send 0;
|
||||||
|
#X msg 203 482 connect localhost 9198;
|
||||||
|
#X obj 81 -30 netreceive 9197;
|
||||||
|
#X obj -124 3 unpack f f s;
|
||||||
|
#X obj -220 158 float;
|
||||||
|
#X obj -221 187 s layer1;
|
||||||
|
#X obj -153 155 float;
|
||||||
|
#X obj -80 151 float;
|
||||||
|
#X obj 0 155 float;
|
||||||
|
#X obj 84 151 float;
|
||||||
|
#X obj 156 149 float;
|
||||||
|
#X obj 232 147 float;
|
||||||
|
#X obj 309 145 float;
|
||||||
|
#X obj 385 145 float;
|
||||||
|
#X obj 464 142 float;
|
||||||
|
#X obj -154 184 s layer2;
|
||||||
|
#X obj -81 180 s layer3;
|
||||||
|
#X obj -1 184 s layer4;
|
||||||
|
#X obj 83 180 s layer5;
|
||||||
|
#X obj 155 178 s layer6;
|
||||||
|
#X obj 231 176 s layer7;
|
||||||
|
#X obj 308 174 s layer8;
|
||||||
|
#X obj 384 174 s ola;
|
||||||
|
#X obj 463 171 s universe;
|
||||||
|
#X obj 184 28 s path;
|
||||||
|
#X obj -9 75 select 11 12 13 14 15 16 17 18 20 21;
|
||||||
|
#X obj -36 346 layer_audio;
|
||||||
|
#X obj 52 349 layer_audio;
|
||||||
|
#X obj 141 354 layer_audio;
|
||||||
|
#X obj -141 344 layer_audio;
|
||||||
|
#X obj 237 350 layer_audio;
|
||||||
|
#X obj 336 340 layer_audio;
|
||||||
|
#X obj 434 337 layer_audio;
|
||||||
|
#X obj 427 34 delay 500;
|
||||||
|
#X connect 0 0 1 0;
|
||||||
|
#X connect 0 1 45 0;
|
||||||
|
#X connect 0 2 42 0;
|
||||||
|
#X connect 0 3 43 0;
|
||||||
|
#X connect 0 4 44 0;
|
||||||
|
#X connect 0 5 46 0;
|
||||||
|
#X connect 0 6 47 0;
|
||||||
|
#X connect 0 7 48 0;
|
||||||
|
#X connect 4 0 49 0;
|
||||||
|
#X connect 5 0 6 0;
|
||||||
|
#X connect 7 0 6 0;
|
||||||
|
#X connect 8 0 6 0;
|
||||||
|
#X connect 9 0 6 0;
|
||||||
|
#X connect 10 0 6 0;
|
||||||
|
#X connect 11 0 6 0;
|
||||||
|
#X connect 12 0 6 0;
|
||||||
|
#X connect 13 0 6 0;
|
||||||
|
#X connect 14 0 15 0;
|
||||||
|
#X connect 14 0 17 0;
|
||||||
|
#X connect 15 0 16 0;
|
||||||
|
#X connect 16 0 6 0;
|
||||||
|
#X connect 17 0 6 0;
|
||||||
|
#X connect 18 0 19 0;
|
||||||
|
#X connect 19 0 41 0;
|
||||||
|
#X connect 19 1 20 1;
|
||||||
|
#X connect 19 1 22 1;
|
||||||
|
#X connect 19 1 23 1;
|
||||||
|
#X connect 19 1 24 1;
|
||||||
|
#X connect 19 1 25 1;
|
||||||
|
#X connect 19 1 26 1;
|
||||||
|
#X connect 19 1 27 1;
|
||||||
|
#X connect 19 1 28 1;
|
||||||
|
#X connect 19 1 29 1;
|
||||||
|
#X connect 19 1 30 1;
|
||||||
|
#X connect 19 2 40 0;
|
||||||
|
#X connect 20 0 21 0;
|
||||||
|
#X connect 22 0 31 0;
|
||||||
|
#X connect 23 0 32 0;
|
||||||
|
#X connect 24 0 33 0;
|
||||||
|
#X connect 25 0 34 0;
|
||||||
|
#X connect 26 0 35 0;
|
||||||
|
#X connect 27 0 36 0;
|
||||||
|
#X connect 28 0 37 0;
|
||||||
|
#X connect 29 0 38 0;
|
||||||
|
#X connect 30 0 39 0;
|
||||||
|
#X connect 41 0 20 0;
|
||||||
|
#X connect 41 1 22 0;
|
||||||
|
#X connect 41 2 23 0;
|
||||||
|
#X connect 41 3 24 0;
|
||||||
|
#X connect 41 4 25 0;
|
||||||
|
#X connect 41 5 26 0;
|
||||||
|
#X connect 41 6 27 0;
|
||||||
|
#X connect 41 7 28 0;
|
||||||
|
#X connect 41 8 29 0;
|
||||||
|
#X connect 41 9 30 0;
|
||||||
|
#X connect 49 0 2 0;
|
662
pms-video.pd
Normal file
662
pms-video.pd
Normal file
|
@ -0,0 +1,662 @@
|
||||||
|
#N canvas 773 508 611 318 10;
|
||||||
|
#N canvas 315 169 952 599 dmx 0;
|
||||||
|
#X obj -7 437 list split;
|
||||||
|
#X obj 99 444 list split;
|
||||||
|
#X obj 50 385 - 1;
|
||||||
|
#X obj 156 386 - 1;
|
||||||
|
#X msg 432 206 close;
|
||||||
|
#X obj 202 447 list split;
|
||||||
|
#X obj 259 390 - 1;
|
||||||
|
#X obj 308 446 list split;
|
||||||
|
#X obj 365 367 - 1;
|
||||||
|
#X msg 330 206 universe \$1;
|
||||||
|
#X msg 486 209 open;
|
||||||
|
#X obj 434 457 list split;
|
||||||
|
#X obj 491 378 - 1;
|
||||||
|
#X obj 558 448 list split;
|
||||||
|
#X obj 615 369 - 1;
|
||||||
|
#X obj 675 449 list split;
|
||||||
|
#X obj 732 370 - 1;
|
||||||
|
#X obj 800 445 list split;
|
||||||
|
#X obj 857 366 - 1;
|
||||||
|
#X obj -7 379 spigot;
|
||||||
|
#X obj 95 402 spigot;
|
||||||
|
#X obj 204 397 spigot;
|
||||||
|
#X obj 314 393 spigot;
|
||||||
|
#X obj 421 395 spigot;
|
||||||
|
#X obj 556 405 spigot;
|
||||||
|
#X obj 672 407 spigot;
|
||||||
|
#X obj 798 394 spigot;
|
||||||
|
#X obj 21 479 list split 49;
|
||||||
|
#X obj 127 482 list split 49;
|
||||||
|
#X obj 230 482 list split 49;
|
||||||
|
#X obj 336 483 list split 49;
|
||||||
|
#X obj 462 494 list split 49;
|
||||||
|
#X obj 586 485 list split 49;
|
||||||
|
#X obj 703 486 list split 49;
|
||||||
|
#X obj 828 482 list split 49;
|
||||||
|
#X obj 27 208 r layer1;
|
||||||
|
#X obj 100 204 r layer2;
|
||||||
|
#X obj 167 209 r layer3;
|
||||||
|
#X obj 233 202 r layer4;
|
||||||
|
#X obj 521 256 r layer5;
|
||||||
|
#X obj 606 281 r layer6;
|
||||||
|
#X obj 722 280 r layer7;
|
||||||
|
#X obj 858 278 r layer8;
|
||||||
|
#X obj 435 94 r ola;
|
||||||
|
#X obj 434 154 select 0;
|
||||||
|
#X obj 331 93 r universe;
|
||||||
|
#X obj 21 520 s dmx1;
|
||||||
|
#X obj 127 523 s dmx2;
|
||||||
|
#X obj 230 523 s dmx3;
|
||||||
|
#X obj 330 522 s dmx4;
|
||||||
|
#X obj 462 535 s dmx5;
|
||||||
|
#X obj 586 526 s dmx6;
|
||||||
|
#X obj 703 527 s dmx7;
|
||||||
|
#X obj 828 523 s dmx8;
|
||||||
|
#X obj 410 243 ola2pd;
|
||||||
|
#X connect 0 1 27 0;
|
||||||
|
#X connect 1 1 28 0;
|
||||||
|
#X connect 2 0 0 1;
|
||||||
|
#X connect 3 0 1 1;
|
||||||
|
#X connect 4 0 54 0;
|
||||||
|
#X connect 5 1 29 0;
|
||||||
|
#X connect 6 0 5 1;
|
||||||
|
#X connect 7 1 30 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 9 0 54 0;
|
||||||
|
#X connect 10 0 54 0;
|
||||||
|
#X connect 11 1 31 0;
|
||||||
|
#X connect 12 0 11 1;
|
||||||
|
#X connect 13 1 32 0;
|
||||||
|
#X connect 14 0 13 1;
|
||||||
|
#X connect 15 1 33 0;
|
||||||
|
#X connect 16 0 15 1;
|
||||||
|
#X connect 17 1 34 0;
|
||||||
|
#X connect 18 0 17 1;
|
||||||
|
#X connect 19 0 0 0;
|
||||||
|
#X connect 20 0 1 0;
|
||||||
|
#X connect 21 0 5 0;
|
||||||
|
#X connect 22 0 7 0;
|
||||||
|
#X connect 23 0 11 0;
|
||||||
|
#X connect 24 0 13 0;
|
||||||
|
#X connect 25 0 15 0;
|
||||||
|
#X connect 26 0 17 0;
|
||||||
|
#X connect 27 0 46 0;
|
||||||
|
#X connect 28 0 47 0;
|
||||||
|
#X connect 29 0 48 0;
|
||||||
|
#X connect 30 0 49 0;
|
||||||
|
#X connect 31 0 50 0;
|
||||||
|
#X connect 32 0 51 0;
|
||||||
|
#X connect 33 0 52 0;
|
||||||
|
#X connect 34 0 53 0;
|
||||||
|
#X connect 35 0 2 0;
|
||||||
|
#X connect 35 0 19 1;
|
||||||
|
#X connect 36 0 20 1;
|
||||||
|
#X connect 36 0 3 0;
|
||||||
|
#X connect 37 0 21 1;
|
||||||
|
#X connect 37 0 6 0;
|
||||||
|
#X connect 38 0 8 0;
|
||||||
|
#X connect 38 0 22 1;
|
||||||
|
#X connect 39 0 12 0;
|
||||||
|
#X connect 39 0 23 1;
|
||||||
|
#X connect 40 0 14 0;
|
||||||
|
#X connect 40 0 24 1;
|
||||||
|
#X connect 41 0 16 0;
|
||||||
|
#X connect 41 0 25 1;
|
||||||
|
#X connect 42 0 18 0;
|
||||||
|
#X connect 42 0 26 1;
|
||||||
|
#X connect 43 0 44 0;
|
||||||
|
#X connect 44 0 4 0;
|
||||||
|
#X connect 44 1 10 0;
|
||||||
|
#X connect 45 0 9 0;
|
||||||
|
#X connect 54 0 19 0;
|
||||||
|
#X connect 54 0 20 0;
|
||||||
|
#X connect 54 0 21 0;
|
||||||
|
#X connect 54 0 22 0;
|
||||||
|
#X connect 54 0 23 0;
|
||||||
|
#X connect 54 0 24 0;
|
||||||
|
#X connect 54 0 25 0;
|
||||||
|
#X connect 54 0 26 0;
|
||||||
|
#X coords 0 -1 1 1 10 10 1 10 10;
|
||||||
|
#X restore -346 -438 pd dmx;
|
||||||
|
#N canvas 67 201 240 272 fondo 0;
|
||||||
|
#X obj -452 -118 color 0 0 0;
|
||||||
|
#X obj -452 -150 alpha;
|
||||||
|
#X text -486 -209 Pantalla fondo Negra;
|
||||||
|
#X obj -452 -187 gemhead 5;
|
||||||
|
#X obj -451 -49 translateXYZ;
|
||||||
|
#X obj -352 -170 loadbang;
|
||||||
|
#X obj -451 3 rectangle 16 12;
|
||||||
|
#X msg -352 -110 -50;
|
||||||
|
#X connect 0 0 4 0;
|
||||||
|
#X connect 1 0 0 0;
|
||||||
|
#X connect 3 0 1 0;
|
||||||
|
#X connect 4 0 6 0;
|
||||||
|
#X connect 5 0 7 0;
|
||||||
|
#X connect 7 0 4 3;
|
||||||
|
#X restore -301 -438 pd fondo;
|
||||||
|
#N canvas 610 161 450 300 receive 0;
|
||||||
|
#X obj 71 -398 select 1;
|
||||||
|
#X obj 123 -358 select 2 3 4 5;
|
||||||
|
#X obj 22 -242 s winposx;
|
||||||
|
#X obj 101 -240 s winposy;
|
||||||
|
#X obj 170 -238 s winsizex;
|
||||||
|
#X obj 249 -238 s winsizey;
|
||||||
|
#X obj 22 -266 float;
|
||||||
|
#X obj 101 -268 float;
|
||||||
|
#X obj 170 -274 float;
|
||||||
|
#X obj 250 -270 float;
|
||||||
|
#X obj 342 -231 s layer1;
|
||||||
|
#X obj 677 -389 select 11 12 13 14 15 16 17 18;
|
||||||
|
#X obj 400 -228 s layer2;
|
||||||
|
#X obj 460 -226 s layer3;
|
||||||
|
#X obj 540 -223 s layer4;
|
||||||
|
#X obj 599 -223 s layer5;
|
||||||
|
#X obj 663 -221 s layer6;
|
||||||
|
#X obj 725 -224 s layer7;
|
||||||
|
#X obj 791 -226 s layer8;
|
||||||
|
#X obj 342 -266 float;
|
||||||
|
#X obj 396 -267 float;
|
||||||
|
#X obj 451 -266 float;
|
||||||
|
#X obj 540 -266 float;
|
||||||
|
#X obj 789 -263 float;
|
||||||
|
#X obj 592 -265 float;
|
||||||
|
#X obj 659 -269 float;
|
||||||
|
#X obj 721 -263 float;
|
||||||
|
#X obj 861 -252 float;
|
||||||
|
#X obj 861 -227 s ola;
|
||||||
|
#X obj 911 -252 float;
|
||||||
|
#X obj 911 -226 s universe;
|
||||||
|
#X obj 718 -415 s path;
|
||||||
|
#X obj -1 -351 float;
|
||||||
|
#X obj 452 -449 unpack f f s;
|
||||||
|
#X obj 452 -477 netreceive 9195;
|
||||||
|
#X obj 872 -324 select 20 21;
|
||||||
|
#X floatatom 604 -458 5 0 0 0 - - -;
|
||||||
|
#X obj 0 -316 s window;
|
||||||
|
#X connect 0 0 32 0;
|
||||||
|
#X connect 0 1 1 0;
|
||||||
|
#X connect 1 0 6 0;
|
||||||
|
#X connect 1 1 7 0;
|
||||||
|
#X connect 1 2 8 0;
|
||||||
|
#X connect 1 3 9 0;
|
||||||
|
#X connect 1 4 11 0;
|
||||||
|
#X connect 6 0 2 0;
|
||||||
|
#X connect 7 0 3 0;
|
||||||
|
#X connect 8 0 4 0;
|
||||||
|
#X connect 9 0 5 0;
|
||||||
|
#X connect 11 0 19 0;
|
||||||
|
#X connect 11 1 20 0;
|
||||||
|
#X connect 11 2 21 0;
|
||||||
|
#X connect 11 3 22 0;
|
||||||
|
#X connect 11 4 24 0;
|
||||||
|
#X connect 11 5 25 0;
|
||||||
|
#X connect 11 6 26 0;
|
||||||
|
#X connect 11 7 23 0;
|
||||||
|
#X connect 11 8 35 0;
|
||||||
|
#X connect 19 0 10 0;
|
||||||
|
#X connect 20 0 12 0;
|
||||||
|
#X connect 21 0 13 0;
|
||||||
|
#X connect 22 0 14 0;
|
||||||
|
#X connect 23 0 18 0;
|
||||||
|
#X connect 24 0 15 0;
|
||||||
|
#X connect 25 0 16 0;
|
||||||
|
#X connect 26 0 17 0;
|
||||||
|
#X connect 27 0 28 0;
|
||||||
|
#X connect 29 0 30 0;
|
||||||
|
#X connect 32 0 37 0;
|
||||||
|
#X connect 33 0 0 0;
|
||||||
|
#X connect 33 1 6 1;
|
||||||
|
#X connect 33 1 7 1;
|
||||||
|
#X connect 33 1 8 1;
|
||||||
|
#X connect 33 1 9 1;
|
||||||
|
#X connect 33 1 19 1;
|
||||||
|
#X connect 33 1 20 1;
|
||||||
|
#X connect 33 1 21 1;
|
||||||
|
#X connect 33 1 22 1;
|
||||||
|
#X connect 33 1 24 1;
|
||||||
|
#X connect 33 1 25 1;
|
||||||
|
#X connect 33 1 26 1;
|
||||||
|
#X connect 33 1 23 1;
|
||||||
|
#X connect 33 1 27 1;
|
||||||
|
#X connect 33 1 29 1;
|
||||||
|
#X connect 33 1 32 1;
|
||||||
|
#X connect 33 2 31 0;
|
||||||
|
#X connect 34 0 33 0;
|
||||||
|
#X connect 34 1 36 0;
|
||||||
|
#X connect 35 0 27 0;
|
||||||
|
#X connect 35 1 29 0;
|
||||||
|
#X restore -244 -438 pd receive;
|
||||||
|
#N canvas 1151 173 450 564 window 0;
|
||||||
|
#X msg 987 -347 color 0 0 0;
|
||||||
|
#X msg 117 -352 create;
|
||||||
|
#X msg 192 -352 destroy;
|
||||||
|
#X msg 721 -349 print;
|
||||||
|
#X msg 561 -352 border \$1;
|
||||||
|
#X msg 467 -352 fullscreen \$1;
|
||||||
|
#X msg 641 -350 topmost \$1;
|
||||||
|
#X msg 773 -349 cursor 0;
|
||||||
|
#X obj 698 -474 loadbang;
|
||||||
|
#X msg 918 -348 title PMS;
|
||||||
|
#X obj 368 -400 pack f f;
|
||||||
|
#X msg 368 -355 offset \$1 \$2;
|
||||||
|
#X obj 264 -401 pack f f;
|
||||||
|
#X msg 264 -354 dimen \$1 \$2;
|
||||||
|
#X obj 19 -349 s init;
|
||||||
|
#X msg 840 -348 profile 2;
|
||||||
|
#X obj 8 -425 select 1;
|
||||||
|
#X obj 76 -424 select 0;
|
||||||
|
#X obj 365 -473 r winposx;
|
||||||
|
#X obj 431 -472 r winposy;
|
||||||
|
#X obj 382 -434 t b;
|
||||||
|
#X obj 212 -474 r winsizex;
|
||||||
|
#X obj 288 -475 r winsizey;
|
||||||
|
#X obj 274 -433 t b;
|
||||||
|
#X msg 605 -427 0;
|
||||||
|
#X obj 122 -473 gemkeyboard;
|
||||||
|
#X obj 160 -425 select 9;
|
||||||
|
#X msg 117 -261 1;
|
||||||
|
#X obj 117 -293 delay 10;
|
||||||
|
#X obj 117 -323 t b;
|
||||||
|
#X obj 40 -467 r window;
|
||||||
|
#X floatatom 120 33 0 0 0 0 - - -;
|
||||||
|
#X obj 120 -55 cputime;
|
||||||
|
#X obj 120 -195 loadbang;
|
||||||
|
#X msg 120 -167 1;
|
||||||
|
#X floatatom 120 -139 0 0 0 0 - - -;
|
||||||
|
#X obj 120 -83 t b b;
|
||||||
|
#X obj 120 5 * 0.1;
|
||||||
|
#X obj 120 -26 int;
|
||||||
|
#X text 165 -139 <-- on/off;
|
||||||
|
#X obj 308 -220 gemwin 30;
|
||||||
|
#X obj 120 -111 metro 1000;
|
||||||
|
#X connect 0 0 40 0;
|
||||||
|
#X connect 1 0 29 0;
|
||||||
|
#X connect 1 0 40 0;
|
||||||
|
#X connect 2 0 40 0;
|
||||||
|
#X connect 3 0 40 0;
|
||||||
|
#X connect 4 0 40 0;
|
||||||
|
#X connect 5 0 40 0;
|
||||||
|
#X connect 6 0 40 0;
|
||||||
|
#X connect 7 0 40 0;
|
||||||
|
#X connect 8 0 0 0;
|
||||||
|
#X connect 8 0 9 0;
|
||||||
|
#X connect 8 0 24 0;
|
||||||
|
#X connect 8 0 7 0;
|
||||||
|
#X connect 8 0 15 0;
|
||||||
|
#X connect 9 0 40 0;
|
||||||
|
#X connect 10 0 11 0;
|
||||||
|
#X connect 11 0 40 0;
|
||||||
|
#X connect 12 0 13 0;
|
||||||
|
#X connect 13 0 40 0;
|
||||||
|
#X connect 15 0 40 0;
|
||||||
|
#X connect 16 0 1 0;
|
||||||
|
#X connect 16 0 14 0;
|
||||||
|
#X connect 17 0 2 0;
|
||||||
|
#X connect 18 0 10 0;
|
||||||
|
#X connect 19 0 10 1;
|
||||||
|
#X connect 19 0 20 0;
|
||||||
|
#X connect 20 0 10 0;
|
||||||
|
#X connect 21 0 12 0;
|
||||||
|
#X connect 22 0 12 1;
|
||||||
|
#X connect 22 0 23 0;
|
||||||
|
#X connect 23 0 12 0;
|
||||||
|
#X connect 24 0 6 0;
|
||||||
|
#X connect 24 0 4 0;
|
||||||
|
#X connect 25 0 26 0;
|
||||||
|
#X connect 26 0 2 0;
|
||||||
|
#X connect 27 0 40 0;
|
||||||
|
#X connect 28 0 27 0;
|
||||||
|
#X connect 29 0 28 0;
|
||||||
|
#X connect 30 0 16 0;
|
||||||
|
#X connect 30 0 17 0;
|
||||||
|
#X connect 32 0 38 0;
|
||||||
|
#X connect 33 0 34 0;
|
||||||
|
#X connect 34 0 35 0;
|
||||||
|
#X connect 35 0 41 0;
|
||||||
|
#X connect 36 0 32 0;
|
||||||
|
#X connect 36 1 32 1;
|
||||||
|
#X connect 37 0 31 0;
|
||||||
|
#X connect 38 0 37 0;
|
||||||
|
#X connect 41 0 36 0;
|
||||||
|
#X restore -175 -438 pd window;
|
||||||
|
#N canvas 621 159 450 300 layer_5 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -177 -80 r layer5;
|
||||||
|
#X obj -253 -81 r dmx5;
|
||||||
|
#X msg -253 10 5 \$1;
|
||||||
|
#X obj -253 32 print togui;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X msg -421 17 layerimage 15;
|
||||||
|
#X obj -50 -57 delay 400;
|
||||||
|
#X obj -43 122 s preview;
|
||||||
|
#X connect 0 0 6 0;
|
||||||
|
#X connect 0 1 8 0;
|
||||||
|
#X connect 1 0 8 1;
|
||||||
|
#X connect 2 0 8 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 4 0 3 0;
|
||||||
|
#X connect 4 0 0 1;
|
||||||
|
#X connect 5 0 0 0;
|
||||||
|
#X connect 6 0 7 0;
|
||||||
|
#X connect 8 0 10 0;
|
||||||
|
#X connect 9 0 15 0;
|
||||||
|
#X connect 10 0 13 0;
|
||||||
|
#X connect 10 0 16 0;
|
||||||
|
#X connect 11 0 10 1;
|
||||||
|
#X connect 12 0 10 1;
|
||||||
|
#X connect 13 0 11 0;
|
||||||
|
#X connect 14 0 16 0;
|
||||||
|
#X connect 15 0 12 0;
|
||||||
|
#X connect 15 0 14 0;
|
||||||
|
#X connect 15 0 16 0;
|
||||||
|
#X restore -166 -380 pd layer_5;
|
||||||
|
#X obj -298 -336 loadbang;
|
||||||
|
#X obj -407 -259 print togui;
|
||||||
|
#N canvas 1 101 450 300 layer_6 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -253 32 print togui;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X msg -421 17 layerimage 16;
|
||||||
|
#X obj -253 -81 r dmx6;
|
||||||
|
#X obj -177 -80 r layer6;
|
||||||
|
#X msg -253 10 6 \$1;
|
||||||
|
#X obj -48 -38 delay 500;
|
||||||
|
#X obj -44 132 s preview;
|
||||||
|
#X connect 0 0 14 0;
|
||||||
|
#X connect 0 1 5 0;
|
||||||
|
#X connect 1 0 5 1;
|
||||||
|
#X connect 2 0 5 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 5 0 7 0;
|
||||||
|
#X connect 6 0 15 0;
|
||||||
|
#X connect 7 0 10 0;
|
||||||
|
#X connect 7 0 16 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 9 0 7 1;
|
||||||
|
#X connect 10 0 8 0;
|
||||||
|
#X connect 11 0 16 0;
|
||||||
|
#X connect 12 0 0 0;
|
||||||
|
#X connect 13 0 3 0;
|
||||||
|
#X connect 13 0 0 1;
|
||||||
|
#X connect 14 0 4 0;
|
||||||
|
#X connect 15 0 9 0;
|
||||||
|
#X connect 15 0 11 0;
|
||||||
|
#X connect 15 0 16 0;
|
||||||
|
#X restore -95 -380 pd layer_6;
|
||||||
|
#N canvas 1 101 450 300 layer_7 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -253 32 print togui;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X msg -421 17 layerimage 17;
|
||||||
|
#X msg -253 10 7 \$1;
|
||||||
|
#X obj -253 -81 r dmx7;
|
||||||
|
#X obj -177 -80 r layer7;
|
||||||
|
#X obj -54 -37 delay 600;
|
||||||
|
#X obj -46 119 s preview;
|
||||||
|
#X connect 0 0 12 0;
|
||||||
|
#X connect 0 1 5 0;
|
||||||
|
#X connect 1 0 5 1;
|
||||||
|
#X connect 2 0 5 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 5 0 7 0;
|
||||||
|
#X connect 6 0 15 0;
|
||||||
|
#X connect 7 0 10 0;
|
||||||
|
#X connect 7 0 16 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 9 0 7 1;
|
||||||
|
#X connect 10 0 8 0;
|
||||||
|
#X connect 11 0 16 0;
|
||||||
|
#X connect 12 0 4 0;
|
||||||
|
#X connect 13 0 0 0;
|
||||||
|
#X connect 14 0 3 0;
|
||||||
|
#X connect 14 0 0 1;
|
||||||
|
#X connect 15 0 9 0;
|
||||||
|
#X connect 15 0 11 0;
|
||||||
|
#X connect 15 0 16 0;
|
||||||
|
#X restore -25 -379 pd layer_7;
|
||||||
|
#N canvas 1 117 450 300 layer_8 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -253 32 print togui;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X obj -253 -81 r dmx8;
|
||||||
|
#X obj -177 -80 r layer8;
|
||||||
|
#X msg -253 10 8 \$1;
|
||||||
|
#X msg -421 17 layerimage 18;
|
||||||
|
#X obj -57 -58 delay 700;
|
||||||
|
#X obj -78 108 s preview;
|
||||||
|
#X connect 0 0 13 0;
|
||||||
|
#X connect 0 1 5 0;
|
||||||
|
#X connect 1 0 5 1;
|
||||||
|
#X connect 2 0 5 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 5 0 7 0;
|
||||||
|
#X connect 6 0 15 0;
|
||||||
|
#X connect 7 0 10 0;
|
||||||
|
#X connect 7 0 16 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 9 0 7 1;
|
||||||
|
#X connect 10 0 8 0;
|
||||||
|
#X connect 11 0 0 0;
|
||||||
|
#X connect 12 0 3 0;
|
||||||
|
#X connect 12 0 0 1;
|
||||||
|
#X connect 13 0 4 0;
|
||||||
|
#X connect 14 0 16 0;
|
||||||
|
#X connect 15 0 9 0;
|
||||||
|
#X connect 15 0 14 0;
|
||||||
|
#X connect 15 0 16 0;
|
||||||
|
#X restore 46 -379 pd layer_8;
|
||||||
|
#N canvas 1 125 450 300 layer_4 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X obj -253 -81 r dmx4;
|
||||||
|
#X obj -253 32 print togui;
|
||||||
|
#X msg -253 10 4 \$1;
|
||||||
|
#X msg -421 17 layerimage 14;
|
||||||
|
#X obj -53 -70 delay 300;
|
||||||
|
#X obj -177 -80 r layer4;
|
||||||
|
#X obj -39 147 s preview;
|
||||||
|
#X connect 0 0 12 0;
|
||||||
|
#X connect 0 1 4 0;
|
||||||
|
#X connect 1 0 4 1;
|
||||||
|
#X connect 2 0 4 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 4 0 6 0;
|
||||||
|
#X connect 5 0 14 0;
|
||||||
|
#X connect 6 0 9 0;
|
||||||
|
#X connect 6 0 16 0;
|
||||||
|
#X connect 7 0 6 1;
|
||||||
|
#X connect 8 0 6 1;
|
||||||
|
#X connect 9 0 7 0;
|
||||||
|
#X connect 10 0 0 0;
|
||||||
|
#X connect 12 0 11 0;
|
||||||
|
#X connect 13 0 16 0;
|
||||||
|
#X connect 14 0 8 0;
|
||||||
|
#X connect 14 0 13 0;
|
||||||
|
#X connect 14 0 16 0;
|
||||||
|
#X connect 15 0 3 0;
|
||||||
|
#X connect 15 0 0 1;
|
||||||
|
#X restore -237 -380 pd layer_4;
|
||||||
|
#N canvas 1 101 450 300 layer_3 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -253 32 print togui;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X msg -295 86 layerimage 13;
|
||||||
|
#X obj -253 -81 r dmx3;
|
||||||
|
#X obj -177 -80 r layer3;
|
||||||
|
#X msg -253 10 3 \$1;
|
||||||
|
#X obj -51 -30 delay 200;
|
||||||
|
#X obj -82 141 s preview;
|
||||||
|
#X connect 0 0 14 0;
|
||||||
|
#X connect 0 1 5 0;
|
||||||
|
#X connect 1 0 5 1;
|
||||||
|
#X connect 2 0 5 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 5 0 7 0;
|
||||||
|
#X connect 6 0 15 0;
|
||||||
|
#X connect 7 0 10 0;
|
||||||
|
#X connect 7 0 16 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 9 0 7 1;
|
||||||
|
#X connect 10 0 8 0;
|
||||||
|
#X connect 11 0 16 0;
|
||||||
|
#X connect 12 0 0 0;
|
||||||
|
#X connect 13 0 3 0;
|
||||||
|
#X connect 13 0 0 1;
|
||||||
|
#X connect 14 0 4 0;
|
||||||
|
#X connect 15 0 9 0;
|
||||||
|
#X connect 15 0 11 0;
|
||||||
|
#X connect 15 0 16 0;
|
||||||
|
#X restore -306 -380 pd layer_3;
|
||||||
|
#N canvas 1 101 450 300 layer_2 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -253 32 print togui;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X msg -421 17 layerimage 12;
|
||||||
|
#X msg -253 10 2 \$1;
|
||||||
|
#X obj -253 -81 r dmx2;
|
||||||
|
#X obj -177 -80 r layer2;
|
||||||
|
#X obj -106 -96 delay 100;
|
||||||
|
#X obj -211 67 t b;
|
||||||
|
#X obj -93 156 s preview;
|
||||||
|
#X connect 0 0 12 0;
|
||||||
|
#X connect 0 1 5 0;
|
||||||
|
#X connect 1 0 5 1;
|
||||||
|
#X connect 2 0 5 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 5 0 7 0;
|
||||||
|
#X connect 6 0 15 0;
|
||||||
|
#X connect 7 0 10 0;
|
||||||
|
#X connect 7 0 17 0;
|
||||||
|
#X connect 8 0 7 1;
|
||||||
|
#X connect 9 0 7 1;
|
||||||
|
#X connect 10 0 8 0;
|
||||||
|
#X connect 11 0 16 0;
|
||||||
|
#X connect 11 0 17 0;
|
||||||
|
#X connect 12 0 4 0;
|
||||||
|
#X connect 13 0 0 0;
|
||||||
|
#X connect 14 0 3 0;
|
||||||
|
#X connect 14 0 0 1;
|
||||||
|
#X connect 15 0 9 0;
|
||||||
|
#X connect 15 0 11 0;
|
||||||
|
#X connect 16 0 17 0;
|
||||||
|
#X restore -374 -380 pd layer_2;
|
||||||
|
#N canvas 1 157 450 300 layer_1 0;
|
||||||
|
#X obj -253 -28 layer;
|
||||||
|
#X msg -132 -32 1;
|
||||||
|
#X msg -177 -33 0;
|
||||||
|
#X obj -177 -55 select 0;
|
||||||
|
#X obj -169 4 spigot;
|
||||||
|
#X obj -106 -124 r metro;
|
||||||
|
#X obj -169 34 spigot;
|
||||||
|
#X msg -111 34 0;
|
||||||
|
#X msg -107 3 1;
|
||||||
|
#X obj -169 56 t b;
|
||||||
|
#X obj -253 -81 r dmx1;
|
||||||
|
#X obj -177 -80 r layer1;
|
||||||
|
#X msg -253 10 1 \$1;
|
||||||
|
#X msg -258 69 layerimage 11;
|
||||||
|
#X obj -253 32 s textgui;
|
||||||
|
#X obj -29 148 s preview;
|
||||||
|
#X connect 0 0 12 0;
|
||||||
|
#X connect 0 1 4 0;
|
||||||
|
#X connect 1 0 4 1;
|
||||||
|
#X connect 2 0 4 1;
|
||||||
|
#X connect 3 0 2 0;
|
||||||
|
#X connect 3 1 1 0;
|
||||||
|
#X connect 4 0 6 0;
|
||||||
|
#X connect 5 0 8 0;
|
||||||
|
#X connect 5 0 13 0;
|
||||||
|
#X connect 5 0 15 0;
|
||||||
|
#X connect 6 0 9 0;
|
||||||
|
#X connect 6 0 15 0;
|
||||||
|
#X connect 7 0 6 1;
|
||||||
|
#X connect 8 0 6 1;
|
||||||
|
#X connect 9 0 7 0;
|
||||||
|
#X connect 10 0 0 0;
|
||||||
|
#X connect 11 0 3 0;
|
||||||
|
#X connect 11 0 0 1;
|
||||||
|
#X connect 12 0 14 0;
|
||||||
|
#X connect 13 0 15 0;
|
||||||
|
#X restore -442 -380 pd layer_1;
|
||||||
|
#X obj -298 -271 metro 1000;
|
||||||
|
#X obj -298 -237 s metro;
|
||||||
|
#X msg -298 -299 1;
|
||||||
|
#X obj -364 -297 r textgui;
|
||||||
|
#X obj -476 -294 r preview;
|
||||||
|
#X msg -407 -294 0;
|
||||||
|
#X text -384 -470 (c) 2012 Santi Noreña libremediaserver@gmail.com
|
||||||
|
GPL License;
|
||||||
|
#X obj -476 -236 pix2jpg;
|
||||||
|
#X connect 5 0 16 0;
|
||||||
|
#X connect 5 0 19 0;
|
||||||
|
#X connect 14 0 15 0;
|
||||||
|
#X connect 16 0 14 0;
|
||||||
|
#X connect 17 0 6 0;
|
||||||
|
#X connect 18 0 21 0;
|
||||||
|
#X connect 19 0 6 0;
|
||||||
|
#X coords 0 0 1 1 85 60 0;
|
5
scripts/extended_desktop.sh
Executable file
5
scripts/extended_desktop.sh
Executable file
|
@ -0,0 +1,5 @@
|
||||||
|
xrandr -q
|
||||||
|
xrandr --output LVDS --pos 1024x0
|
||||||
|
xrandr --output VGA-0 --mode 1024x768
|
||||||
|
xrandr --output LVDS --mode 1024x768
|
||||||
|
xrandr --output VGA-0 --right-of LVDS
|
28
scripts/install_precise.sh
Normal file
28
scripts/install_precise.sh
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
#!/bin/bash
|
||||||
|
##############################################################################
|
||||||
|
# Script de instalación de las dependencias de Libre Media Server
|
||||||
|
# en Ubuntu Precise 12.04.
|
||||||
|
# Necesita root para ejecutar
|
||||||
|
# (c) 2012 Santi Noreña
|
||||||
|
# GPL License
|
||||||
|
###############################################################################
|
||||||
|
# Comprobamos root
|
||||||
|
(( EUID )) && echo ‘You need to be root.’ && exit 1
|
||||||
|
# Instalamos OLA desde el repositorio del proyecto
|
||||||
|
# copia de seguridad de sources.list
|
||||||
|
cp /etc/apt/sources.list /etc/apt/sources.list.old
|
||||||
|
# Comprobamos que el repositorio no está en soucers.list
|
||||||
|
output=`grep apt.openlighting.org /etc/apt/sources.list | wc -l`
|
||||||
|
if [ "$output" -eq "0" ]; then
|
||||||
|
#Añadimos el repositorio ola a sources.list
|
||||||
|
echo "deb http://apt.openlighting.org/debian/ precise main" >> /etc/apt/sources.list
|
||||||
|
fi
|
||||||
|
apt-get update
|
||||||
|
apt-get -y install ola puredata tcl tk
|
||||||
|
if [ "$?" -eq "0" ]; then
|
||||||
|
echo "apt-get finish ok"
|
||||||
|
else "apt-get return errors!"
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
28
scripts/install_squeeze.sh
Executable file
28
scripts/install_squeeze.sh
Executable file
|
@ -0,0 +1,28 @@
|
||||||
|
#!/bin/bash
|
||||||
|
##############################################################################
|
||||||
|
# Script de instalación de las dependencias de Pure Media Server
|
||||||
|
# en Debian Squeeze.
|
||||||
|
# Necesita root para ejecutar
|
||||||
|
# (c) 2012 Santi Noreña
|
||||||
|
# GPL License
|
||||||
|
###############################################################################
|
||||||
|
# Comprobamos root
|
||||||
|
(( EUID )) && echo ‘You need to be root.’ && exit 1
|
||||||
|
# Instalamos OLA desde el repositorio del proyecto
|
||||||
|
# copia de seguridad de sources.list
|
||||||
|
cp /etc/apt/sources.list /etc/apt/sources.list.old
|
||||||
|
# Comprobamos que el repositorio no está en soucers.list
|
||||||
|
output=`grep apt.openlighting.org /etc/apt/sources.list | wc -l`
|
||||||
|
if [ "$output" -eq "0" ]; then
|
||||||
|
#Añadimos el repositorio ola a sources.list
|
||||||
|
echo "deb http://apt.openlighting.org/debian/ squeeze main" >> /etc/apt/sources.list
|
||||||
|
fi
|
||||||
|
apt-get update
|
||||||
|
apt-get -y install ola puredata tcl tk pd-zexy
|
||||||
|
if [ "$?" -eq "0" ]; then
|
||||||
|
echo "apt-get finish ok"
|
||||||
|
else "apt-get return errors!"
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
20
scripts/install_wheezy.sh
Executable file
20
scripts/install_wheezy.sh
Executable file
|
@ -0,0 +1,20 @@
|
||||||
|
#!/bin/bash
|
||||||
|
##############################################################################
|
||||||
|
# Script de instalación de las dependencias de Libre Media Server
|
||||||
|
# en Debian Wheezy.
|
||||||
|
# Necesita root para ejecutar
|
||||||
|
# (c) 2012 Santi Noreña
|
||||||
|
# GPL License
|
||||||
|
###############################################################################
|
||||||
|
# Comprobamos root
|
||||||
|
(( EUID )) && echo ‘You need to be root.’ && exit 1
|
||||||
|
#Instalamos el paquete suministrado con el release
|
||||||
|
dpkg -i ola_0.8.26-1_i386.deb
|
||||||
|
# Install Pure Data y OLA
|
||||||
|
# libav para generar thumbs
|
||||||
|
apt-get install puredata gem tcl tk libav-tools pd-pdogg pd-pan
|
||||||
|
if [ "$?" -eq "0" ]; then
|
||||||
|
echo "apt-get finish ok"
|
||||||
|
else "apt-get return errors!"
|
||||||
|
fi
|
||||||
|
apt-get -f install
|
37
scripts/make_thumbs.sh
Executable file
37
scripts/make_thumbs.sh
Executable file
|
@ -0,0 +1,37 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# make_thumbs v0.0.1
|
||||||
|
# Script que genera thumbnails de todas las películas en el directorio Media
|
||||||
|
# Copyright Santi Noreña 2012
|
||||||
|
# puremediaserver at gmail dot com
|
||||||
|
# GPL License
|
||||||
|
|
||||||
|
# Edit next line to path to your media
|
||||||
|
export MEDIA_DIR=/home/santi/PMS/svn/media/video
|
||||||
|
export E_XCD=86
|
||||||
|
|
||||||
|
cd $MEDIA_DIR ||{
|
||||||
|
echo "Can not change to directory." $MEDIA_DIR
|
||||||
|
exit $E_XCD;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
for folder in $(find -maxdepth 1 -type d); do
|
||||||
|
rm $folder/thumbs/*
|
||||||
|
mkdir $folder/thumbs
|
||||||
|
done
|
||||||
|
|
||||||
|
for file in $(find . -maxdepth 2 -mindepth 2 -type f ); do
|
||||||
|
avconv -i $file -f image2 -frames:v 1 -s 64x46 -vcodec mjpeg $file.jpg
|
||||||
|
done
|
||||||
|
|
||||||
|
for folder in $(find -maxdepth 1 -type d); do
|
||||||
|
mv $folder/*.jpg $folder/thumbs
|
||||||
|
done
|
||||||
|
|
||||||
|
# Crear una galería de mini imágenes
|
||||||
|
#for i in `ls *.jpg`;
|
||||||
|
#do
|
||||||
|
# convert -geometry 320x240 $i galleria-$i
|
||||||
|
#done
|
||||||
|
|
||||||
|
exit 0
|
2
scripts/single_desktop.sh
Executable file
2
scripts/single_desktop.sh
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
xrandr --output VGA-0 --off
|
||||||
|
|
28
text.txt
Normal file
28
text.txt
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
1, Mikel;
|
||||||
|
2, Gonzalo;
|
||||||
|
3, como técnicos;
|
||||||
|
4, soys muy malos;
|
||||||
|
5, pero como personas;
|
||||||
|
6, dejais mucho;
|
||||||
|
7, que desear;
|
||||||
|
8, sordetis;
|
||||||
|
9, de mierda;
|
||||||
|
10, mas texto;
|
||||||
|
11, mastexto;
|
||||||
|
12, mastexto;
|
||||||
|
13, mastexto;
|
||||||
|
14, mastexto;
|
||||||
|
15, edita esto;
|
||||||
|
16, texto;
|
||||||
|
17, Maistexto;
|
||||||
|
18, bbbbb;
|
||||||
|
19, aaaaaaa;
|
||||||
|
20, Pure;
|
||||||
|
21, Media;
|
||||||
|
22, Server;
|
||||||
|
23, mastexto2;
|
||||||
|
24, mastexto3;
|
||||||
|
25, mastexto4;
|
||||||
|
26, mastexto5;
|
||||||
|
27, mastexto6;
|
||||||
|
|
Loading…
Add table
Reference in a new issue