writes a binary representation of arr into Effect-Buffer
| 186 | |
| 187 | // writes a binary representation of arr into Effect-Buffer |
| 188 | static void EffectsBuffer_WriteSIArray |
| 189 | ( |
| 190 | const SIValue *arr, // array |
| 191 | EffectsBuffer *buff // effect buffer |
| 192 | ) { |
| 193 | // format: |
| 194 | // number of elements |
| 195 | // elements |
| 196 | |
| 197 | SIValue *elements = arr->array; |
| 198 | uint32_t len = array_len(elements); |
| 199 | |
| 200 | // write number of elements |
| 201 | EffectsBuffer_WriteBytes(&len, sizeof(uint32_t), buff); |
| 202 | |
| 203 | // write each element |
| 204 | for (uint32_t i = 0; i < len; i++) { |
| 205 | EffectsBuffer_WriteSIValue(elements + i, buff); |
| 206 | } |
| 207 | } |
| 208 | |
| 209 | // dump attributes to stream |
| 210 | static void EffectsBuffer_WriteAttributeSet |
no test coverage detected