Skip to content

Blueicaro/Pascal-Librealsense

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pascal-LibreRealSense

License Pascal Lazarus Platform librealsense

A Free Pascal / Lazarus wrapper for the Intel RealSense SDK (librealsense), letting you use Intel RealSense depth cameras directly from Object Pascal applications.

💡 New to modern Free Pascal? Check out this excellent introduction article to get up to speed quickly.


Table of Contents


Features

  • ✅ Full Pascal binding for the Intel RealSense C API
  • ✅ Works with Lazarus (GUI and console applications)
  • ✅ Cross-platform: Windows and Linux
  • ✅ Easy-to-install Lazarus package (laz_realsense)
  • ✅ Includes ready-to-run examples to get you started fast
  • ✅ Clean, idiomatic Object Pascal — no external dependencies beyond librealsense

Requirements

Hardware

Software

Component Version Notes
Lazarus IDE 2.2 or later 64-bit recommended
Free Pascal Compiler (FPC) 3.2 or later Bundled with Lazarus
Intel librealsense 2.x Install separately

Operating System

  • Windows 10 / 11 (64-bit) — requires realsense2.dll accessible in your PATH or next to your executable
  • Linux — requires librealsense2.so installed (via apt or built from source)

Installation

1. Install Lazarus

If you don't have Lazarus yet, download the 64-bit installer from the official site and make sure to select the version matching your OS.

Lazarus 64 bits

2. Install librealsense

Download and install the Intel RealSense SDK for your platform from the librealsense releases page.

3. Clone or download this repository

git clone https://github.com/Blueicaro/Pascal-Librealsense.git

Or download the ZIP from the GitHub interface and extract it to a folder of your choice.

4. Open and compile the Lazarus package

In Lazarus, go to Package → Open Package File (.lpk)…

Open package

Navigate to the cloned repository and open:

Lazarus package / laz_realsense.lpk

Select package

Click Compile. Once compiled, you can close the package window.

Compile package

5. Add the package to your project

Create a new project (console or GUI application) or open an existing one.

Create project

Go to Project → Project Inspector and click Add to add a new requirement.

Project Inspector

Add requirement

Search for laz_realsense and select it.

Select laz_realsense

You're all set — start writing your Pascal code! 🎉

⚠️ Windows note: Make sure realsense2.dll is either in the same folder as your compiled executable or in a directory listed in your system PATH.


Examples

The examples/ folder contains several ready-to-run projects. To open one in Lazarus, go to Project → Open Project…

Open project

Navigate to the examples/ folder and pick one. If this is your first time, start with TestLib — it verifies that the library is correctly found and working.

Select project folder

Press Run (or F9) to build and execute the example.

Run project

Troubleshooting: library not found

If you see an error like the one below, your program cannot locate the RealSense library.

DLL error

Fix: Place realsense2.dll (Windows) or ensure librealsense2.so is installed (Linux) so your OS can find it — either next to the executable or in the system PATH.


Contributing

Contributions are very welcome! Here's how to get involved:

  1. Fork this repository and create a branch from main.
  2. Make your changes — whether it's fixing a bug, adding bindings, or improving documentation.
  3. Make sure the existing examples still compile and run correctly.
  4. Open a Pull Request with a clear description of what you changed and why.

If you find a bug or have a feature request, please open an issue — all feedback is appreciated.


License

This project is licensed under the Apache License, Version 2.0.

About

A Pascal wrapper for Intel Real Sense SDK

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages