Skip to content

Commit

Permalink
Introduce support to profile Physics system
Browse files Browse the repository at this point in the history
  • Loading branch information
diegoferigo committed Apr 6, 2021
1 parent 9030007 commit d0e1449
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions cpp/scenario/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ set(SCENARIO_PRIVATE_DEPENDENCIES "")

if(SCENARIO_USE_IGNITION)

option(ENABLE_PROFILER "Enable Ignition Profiler" OFF)
mark_as_advanced(ENABLE_PROFILER)

add_subdirectory(gazebo)
add_subdirectory(plugins)
add_subdirectory(controllers)
Expand Down
4 changes: 4 additions & 0 deletions cpp/scenario/plugins/Physics/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ target_link_libraries(PhysicsSystem
target_include_directories(PhysicsSystem PRIVATE
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>)

if(ENABLE_PROFILER)
target_compile_definitions(PhysicsSystem PRIVATE "IGN_PROFILER_ENABLE=1")
endif()

# ===================
# Install the targets
# ===================
Expand Down

0 comments on commit d0e1449

Please sign in to comment.