Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,14 @@ if (${CMAKE_CURRENT_SOURCE_DIR} STREQUAL ${CMAKE_SOURCE_DIR})

endif()

# enable folders for MSVC
set_property(GLOBAL PROPERTY USE_FOLDERS ON)

# source directories for vsgPoints library
add_subdirectory(src)

set(CMAKE_FOLDER applications)
add_subdirectory(applications)
unset(CMAKE_FOLDER)

vsg_add_feature_summary()
26 changes: 13 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ To enable efficient use of main and GPU memory, point data is segmented into bri

To enable handling of point data with very large world coordinates, the data is translated to a local origin with a vsg::MatrixTransform used to place the rendered points in their proper world coordinate system.

The vsgPoints project contains a vsgPoints library that applications may link to if they wish to add point cloud loading and scene graph creation capabilities to their applications, and a vsgpoints_example utility program.
The vsgPoints project contains a vsgPoints library that applications may link to if they wish to add point cloud loading and scene graph creation capabilities to their applications, and a vsgpoints utility program.

## System requirements/constraints

Expand Down Expand Up @@ -46,18 +46,18 @@ Unix in source build:
make -j 8
make install

# vsgpoints_example application usage
# vsgpoints application usage

To view .3dc or .asc point clouds, or .BIN (double x,y,z; uint8_t r, g, b) data :

~~~ sh
vsgpoints_example mydata.asc
vsgpoints mydata.asc
~~~~

To convert point cloud data to VulkanSceneGraph native format:

~~~ sh
vsgpoints_example mydata.BIN -o mydata.vsgb
vsgpoints mydata.BIN -o mydata.vsgb
~~~~

Once you have converted to native .vsgb format you can load the data in any VulkanSceneGraph application:
Expand All @@ -66,7 +66,7 @@ Once you have converted to native .vsgb format you can load the data in any Vulk
vsgviewer mydata.vsgb
~~~

vsgpoints_example supports generating scene graphs in three ways, the command line options for these are:
vsgpoints supports generating scene graphs in three ways, the command line options for these are:

| command line option | technique |
| --lod | using LOD's (the default) |
Expand All @@ -75,29 +75,29 @@ vsgpoints_example supports generating scene graphs in three ways, the command li

~~~ sh
# create vsg::LOD scene graph
vsgpoints_example mydata.BIN --lod
vsgpoints mydata.BIN --lod
# or just rely upon the default being vsg::LOD scene graph
vsgpoints_example mydata.BIN
vsgpoints mydata.BIN

# create a flat group of point bricks
vsgpoints_example mydata.BIN --flat
vsgpoints mydata.BIN --flat

# create a paged database, requires specification of output file
vsgpoints_example mydata.BIN -o paged.vsgb --plod
vsgpoints mydata.BIN -o paged.vsgb --plod
~~~

vsgpoints_example also supports generating points from meshed models, which can be enabled with --mesh
vsgpoints also supports generating points from meshed models, which can be enabled with --mesh

~~~ sh
# load a mesh model and convert to points as input rather than required loading of points data.
vsgpoints_example mymodel.gltf --mesh
vsgpoints mymodel.gltf --mesh
~~~

If you don't include an output filename using ~ -o filename.vsgb ~ then vsgpoints_example will automatically create a viewer to view the created scene graph, but if you output to a file no viewer will be created. If you still want the viewer to appear then add the -v option to force the viewer to be created.
If you don't include an output filename using ~ -o filename.vsgb ~ then vsgpoints will automatically create a viewer to view the created scene graph, but if you output to a file no viewer will be created. If you still want the viewer to appear then add the -v option to force the viewer to be created.

To alter the precision and point size you can use the -p size_in_metres and --ps multiplier to control the precision (defaults to 0.001) and point size (defaults to 4 x precision).

~~~ sh
# choose 5mm precision and ~50mm rendered point size (10 x 0.005)
vsgpoints_example mydata.3dc -p 0.005 --ps 10
vsgpoints mydata.3dc -p 0.005 --ps 10
~~~
2 changes: 1 addition & 1 deletion applications/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
add_subdirectory(vsgpoints_example)
add_subdirectory(vsgpoints)
15 changes: 15 additions & 0 deletions applications/vsgpoints/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
set(SOURCES
ConvertMeshToPoints.cpp
vsgpoints.cpp
)

add_executable(vsgpoints ${SOURCES})

target_link_libraries(vsgpoints vsg::vsg vsgPoints::vsgPoints)

if (vsgXchange_FOUND)
target_compile_definitions(vsgpoints PRIVATE vsgXchange_FOUND)
target_link_libraries(vsgpoints vsgXchange::vsgXchange)
endif()

install(TARGETS vsgpoints RUNTIME DESTINATION bin)
15 changes: 0 additions & 15 deletions applications/vsgpoints_example/CMakeLists.txt

This file was deleted.