You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| 3 | 0.7 | Add brightness field to modes, add SaveMode() |
15
+
| 4 | 0.9 | Add segments field to zones |
15
16
16
17
\* Denotes unreleased version, reflects status of current pipeline
17
18
@@ -42,24 +43,28 @@ Each packet starts with a header that indicates the packet is an OpenRGB SDK pac
42
43
43
44
The following IDs represent different SDK commands. Each ID packet has a certain format of data associated with it, which will be explained under each ID's section of this document. Gaps have been left in the ID values to allow for future expansion. The same ID values are often used for both request and response packets.
\* The NET_PACKET_ID_REQUEST_PROTOCOL_VERSION packet was not present in protocol version 0, but clients supporting protocol versions 1+ should always send this packet. If no response is received, it should be assumed that the server is using protocol 0.
63
68
64
69
# Packet-Specific Documentation
65
70
@@ -150,8 +155,22 @@ The Zone Data block represents one entry in the `RGBController::zones` vector.
150
155
| 4*| unsigned int | zone_matrix_height | 0 | Zone matrix_map height (*only if matrix_map exists) |
151
156
| 4*| unsigned int | zone_matrix_width | 0 | Zone matrix_map width (*only if matrix_map exists) |
152
157
| (zone_matrix_len - 8)*| unsigned int[zone_matrix_len - 8]| zone_matrix_data | 0 | Zone matrix_map data (*only if matrix_map exists) |
158
+
| 2 | unsigned short | num_segments | 4 | Number of segments in zone |
159
+
| Variable | Segment Data[num_segments]| segments | 4 | See [Segment Data](#segment-data) block format table. Repeat num_segments times |
153
160
154
-
## LED data
161
+
## Segment Data
162
+
163
+
The Segment Data block represents one entry in the `RGBController::zones::segments` vector. This data block was introduced in protocol version 4.
164
+
165
+
| Size | Format | Name | Protocol Version | Description |
| 2 | unsigned short | led_name_len | 0 | Length of LED name string, including null termination |
162
181
| led_name_len | char[led_name_len]| led_name | 0 | LED name string value, including null termination |
163
-
| 4 |unsignd int| led_value | 0 | LED value field value |
182
+
| 4 |unsigned int | led_value | 0 | LED value field value |
164
183
165
184
## NET_PACKET_ID_REQUEST_PROTOCOL_VERSION
166
185
@@ -170,7 +189,7 @@ The client uses this ID to request the server's highest supported protocol versi
170
189
171
190
### Response [Size: 4]
172
191
173
-
The server responds to this request with a single `unsigned int`, size 4, containing the server's highest supported protocol version.
192
+
The server responds to this request with a single `unsigned int`, size 4, containing the server's highest supported protocol version. If the server is using protocol version 0, it will not send a response. If no response is received, assume the server's highest supported protocol version is version 0.
174
193
175
194
## NET_PACKET_ID_SET_CLIENT_NAME
176
195
@@ -214,6 +233,41 @@ Calling this function will not actually update the controllers. Instead, the co
214
233
215
234
The client uses this ID to command the server to delete the given profile. It passes the name of the profile to delete as a null-terminated string. The size of the packet is the size of the string including the null terminator. In C, this is strlen() + 1. There is no response from the server for this packet.
216
235
236
+
## NET_PACKET_ID_REQUEST_PLUGIN_LIST
237
+
238
+
### Request [Size: 0]
239
+
240
+
The client uses this ID to request the server's plugin list. The request contains no data.
241
+
242
+
### Response [Size: Variable]
243
+
244
+
The server responds to this request with a data block. The format of the block is shown below.
0 commit comments