C / C++ Library

Code examples & open source classes
Esempi di codice & classi open source
(c) 2005 Matteo Lucarelli

This section contain some C++ classes and C functions of general interest, and/or coding examples, both for POSIX systems (GNU/Linux) and Windows. All code here is open source (under GNU General Public Licence).

Questa sezione contiene alcune classi C++ e funzioni C di interesse generale, e/o esemplificative di alcune tecniche di programmazione, sia per sistemi POSIX (GNU/Linux) che per Windows. Tutto il codice qui raccolto è open source (secondo la GNU General Public Licence).

: for Windows
: for Linux (& POSIX systems)

Image Analysis - Analisi e trattamento immagini

 

cvBlobFinder
  • Blob analysis class using OpenCV floodfill function. Works with Linux and Windows (perhaps on all platform upported by OpenCV).
  • Classe di blob analisi basata sulla funzione floofill della libreria OpenCV. Funziona sia per Linux che per Windows (in teoria su tutte le piattaforme supportate da OpenCV).

 

Networking - Comunicazione di rete

 

UdpLightMessaging
  • Datagram communication system based on UPD protocol, includes a parsing system for label/value content, but can transport arbitrary binary field too.
  • Sistema di comunicazione a pacchetti su protocollo UDP, include un sistema di parsing per il contenuto dei pacchetti tipo etichetta/valore, ma è possibile spedire anche dati binari arbitrari.

 

User interface - Interfacce

 

Fl_Synoptic
  • A Fl_Box derived class to realize a simple but powerful synoptical panel
  • Una classe derivata dalla Fl_Box per realizzare un leggero e potente pannello sinottico


UIshowexec
  • Execute a command (fork) showing the output in a fltk window.
  • Esegue un comando e ne mostra l'output in una finestra fltk


UIdisplay
  • fltk image display
  • Image display in fltk

 

Utility - Utilità

 

GetPrivateProfile
  • A simple C implementation of GetPrivateProfileInt and GetPrivateProfileString, the two Win API functions to retrive values from an ini file.
  • Una semplice implementazione in C delle due funzioni GetPrivateProfileInt e GetPrivateProfileString, disponibili nella API windows per ottenere valori da un file ini.

procutils
  • Some small functions to read and parse useful informations from /proc filesystem.
  • Alcune piccole funzioni per leggere informazioni utili dal filesystem /proc.


dynaList
  • Dynamic list management class.
  • Classe di gestione liste dinamiche.

wSerial
  • Buffered serial port management interface. That's only for Windows (under unix you have only to open a file!).
  • Interfaccia di gestione bufferizzata delle porte seriali. Solo per Windows (sotto unix si tratta solo di aprire un file!).

wInstanceControl
  • Uses named mutex to share a state across processes, useful to avoid multiple instances of the same program (that's why the name).
  • Utilizza un named-mutex per condividere uno stato tra processi differenti. Utile per evitare istanze multiple di uno stesso processo (da cui il nome).

deldir
  • Small function to delete not empty directories and files, only for windows (under unix you have "rm -rf")
  • Piccola funzione per cancellare directory non vuote e file, solo per windows (in unix è analoga a "rm -rf")

scandir
  • Small function to traverse (scan recursivly) directories and files
  • Piccola funzione per attraversare ricorsivamente file e cartelle

parseline
  • Small function to parse a command string in single words, useful with exec family functions
  • Piccola funzione per separare un comando in singole parole, utile con le funzioni della famiglia exec

keypress
  • Some code lines useful to execute a cycle until the enter key is pressed. Uses only select funtion on standard input. No external library is required.
  • Alcune linee di codice utili ad eseguire un ciclo finchè non viene premuto il tasto enter. Usa solo la funzione select sullo standard input. Non richiede librerie esterne.
 
matteolucarelli.net
©opyright info