### CMake Configuration for Protobuf Source: https://github.com/cartavis/carta-protobuf/blob/dev/CMakeLists.txt Configures CMake to find Protobuf, specify proto file locations, and generate C++ code. Use this to integrate Protobuf-generated code into your C++ project. ```cmake SET(Protobuf_IMPORT_DIRS shared stream control request .) FIND_PACKAGE(Protobuf REQUIRED) INCLUDE_DIRECTORIES(${PROTOBUF_INCLUDE_DIR}) file(GLOB PROTO_FILES "shared/*.proto" "control/*.proto" "request/*.proto" "stream/*.proto" ) PROTOBUF_GENERATE_CPP(PROTO_SRC PROTO_HEADER ${PROTO_FILES}) ADD_LIBRARY(carta-protobuf ${PROTO_HEADER} ${PROTO_SRC}) ``` -------------------------------- ### Encode Tile Coordinates in JavaScript Source: https://github.com/cartavis/carta-protobuf/blob/dev/docs/src/data_cube_navigation.md A JavaScript function to encode tile layer, x, and y coordinates into a single 32-bit integer. This is used for efficient storage and transmission of tile information. ```javascript (x, y, layer) => (layer << 24) | (y << 12) | x; ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.