Skip to content

organize examples#13

Merged
stephen-derosa merged 1 commit into
mainfrom
sderosa/organize-examples
May 22, 2026
Merged

organize examples#13
stephen-derosa merged 1 commit into
mainfrom
sderosa/organize-examples

Conversation

@stephen-derosa
Copy link
Copy Markdown
Collaborator

No description provided.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR reorganizes and (re)introduces multiple LiveKit C++ examples into a clearer folder structure (e.g., logging_levels/basic_usage, hello_livekit/sender, ping_pong/ping) and updates the root build to include them via add_subdirectory(<src> <binary_dir>).

Changes:

  • Add new example implementations for simple_joystick, ping_pong, hello_livekit, and logging_levels.
  • Add per-example CMakeLists.txt files that build dedicated executables (and small support static libs where needed).
  • Update the top-level CMakeLists.txt to reference the new on-disk directory layout.

Reviewed changes

Copilot reviewed 1 out of 35 changed files in this pull request and generated no comments.

Show a summary per file
File Description
CMakeLists.txt Switches several examples to add_subdirectory(<nested path> <binary dir>) to match reorganized layout.
simple_joystick/sender/CMakeLists.txt Builds SimpleJoystickSender plus a small support static library.
simple_joystick/sender/main.cpp Sender example: connects to a room and sends joystick RPC commands based on keyboard input.
simple_joystick/sender/utils.h Declares CLI parsing helper for URL/token.
simple_joystick/sender/utils.cpp Implements CLI parsing with flags/positional/env fallbacks.
simple_joystick/sender/json_utils.h Declares joystick command struct + JSON serialize/deserialize helpers.
simple_joystick/sender/json_utils.cpp Implements JSON serialization/deserialization using nlohmann/json.
simple_joystick/receiver/CMakeLists.txt Builds SimpleJoystickReceiver plus a small support static library.
simple_joystick/receiver/main.cpp Receiver example: registers an RPC method and prints received joystick commands.
simple_joystick/receiver/utils.h Declares CLI parsing helper for URL/token.
simple_joystick/receiver/utils.cpp Implements CLI parsing with flags/positional/env fallbacks.
simple_joystick/receiver/json_utils.h Declares joystick command struct + JSON serialize/deserialize helpers.
simple_joystick/receiver/json_utils.cpp Implements JSON serialization/deserialization using nlohmann/json.
ping_pong/ping/CMakeLists.txt Builds PingPongPing plus a small support static library.
ping_pong/ping/main.cpp Ping participant: publishes “ping” frames, listens for “pong”, logs latency metrics.
ping_pong/ping/utils.h Common helpers (env, time, payload conversions) for ping participant.
ping_pong/ping/messages.h Defines ping/pong message structs and latency metrics struct.
ping_pong/ping/constants.h Shared constants for track names, identities, JSON keys, and timing.
ping_pong/ping/json_converters.h Declares JSON conversion functions for ping/pong messages.
ping_pong/ping/json_converters.cpp Implements JSON conversion for ping/pong messages using nlohmann/json.
ping_pong/pong/CMakeLists.txt Builds PingPongPong plus a small support static library.
ping_pong/pong/main.cpp Pong participant: listens for “ping” frames and responds on “pong”.
ping_pong/pong/utils.h Common helpers (env, time, payload conversions) for pong participant.
ping_pong/pong/messages.h Defines ping/pong message structs and latency metrics struct.
ping_pong/pong/constants.h Shared constants for track names, identities, JSON keys, and timing.
ping_pong/pong/json_converters.h Declares JSON conversion functions for ping/pong messages.
ping_pong/pong/json_converters.cpp Implements JSON conversion for ping/pong messages using nlohmann/json.
logging_levels/basic_usage/CMakeLists.txt Builds the LoggingLevelsBasicUsage executable.
logging_levels/basic_usage/main.cpp Demonstrates SDK log-level control and custom log callbacks.
logging_levels/custom_sinks/CMakeLists.txt Builds the LoggingLevelsCustomSinks executable.
logging_levels/custom_sinks/main.cpp Demonstrates custom log sinks (file, JSON, ROS2-stub) using setLogCallback.
hello_livekit/sender/CMakeLists.txt Builds the HelloLivekitSender executable.
hello_livekit/sender/main.cpp Publishes synthetic video and a data track.
hello_livekit/receiver/CMakeLists.txt Builds the HelloLivekitReceiver executable.
hello_livekit/receiver/main.cpp Subscribes to sender video + data track and logs frame counts.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@stephen-derosa stephen-derosa merged commit 839e38f into main May 22, 2026
9 checks passed
@stephen-derosa stephen-derosa deleted the sderosa/organize-examples branch May 22, 2026 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants