How quangnguyenlong/pcprep works
Project Type and Purpose
• This project is a specialized tool for processing point clouds. Its core purpose is twofold:
– Providing a command-line executable (pcp) that processes point cloud data (e.g., tiling, subsampling, converting camera parameters to matrices)
– Offering a supporting library (pcprep) with lower-level functionalities for geometric operations, point cloud processing, and file handling (e.g., PLY, JSON via cJSON and miniply).
• In addition, there are example programs (in the “examples” directory) that demonstrate how to use the library for various functions, along with an auxiliary tool (trajectory-tool) for camera path generation with Unity.
File Structure
• Top-Level Components:
– Build configuration and scripts: Files like CMakeLists.txt, test.sh, and build scripts.
– Library/Fundamental components:
• “include” folder contains header files for cJSON, miniply, and the pcprep library (with modules such as aabb, canvas, mesh, pointcloud, vector types, etc).
• “src” folder mirrors the “include” components with source files providing the actual implementation.
– Executables:
• “pcp” folder contains the main command-line tool that likely leverages functions provided by the pcprep library.
– Examples:
• “examples” folder holds various sample applications (tiling, subsampling, cam2mat, screen_area, etc) that act as both demonstrations and utilities.
– Additional utilities:
• “trajectory-tool” folder, used with Unity for camera trajectory editing, and a build script (pcprep.sh) for VPCC integration.
• From the filenames (e.g., cam2mat.c, tiling.c, subsampling.c), each example tends to be a standalone executable built on the underlying library.
• External integration: The README mentions dependencies (e.g., libpng, OpenGL/GLFW/GLEW for desktop mode, etc.) which connects to how the build can optionally support GPU-enabled desktop operations.
• Main Components to Represent:
a. Build System & Dependencies:
– CMake and Make tools working as the underlying build and configuration system.
– External dependencies: libpng, optional libraries for desktop mode (libglfw3-dev, libglew-dev, libgl-dev), and libglm-dev for examples.
b. Core Library (pcprep):
– Represent individual modules: aabb, canvas, core, mesh, pointcloud, vector utility (vec3f, vec3u, vec3uc), and wrapper.
– Show that these modules are used for data processing and geometric operations.
c. JSON and File Format Handling:
– cJSON library module, both in “include” and “src”.
– miniply library and its respective modules for handling PLY files.
d. Command-line Tool (pcp):
– Stands as the front-facing executable that provides point cloud processing operations.
e. Examples (Tiling, Subsampling, Cam2mat, Screen_area, etc):
– Grouped together or shown as separate executables that illustrate the usage of the underlying functionality.
f. Additional Tools:
– “trajectory-tool”, which interacts with an external system (Unity) for synthetic trajectory generation.
• Relationships & Data Flow:
• Data input (e.g., a PLY file such as longdress0000.ply or JSON files for camera parameters) flowing into the pcp tool and examples.
• pcp and example executables calling the pcprep library internally to process the point clouds.
• The pcprep library using cJSON and miniply components for file parsing and point cloud data handling.
– Illustrate that build scripts and configuration files (like CMakeLists.txt) govern how the source, library, and executable components are compiled into deliverables.