writeInto method
Writes all fields directly into the native struct reference p.
For nested structs, use writeInto as well.
Implementation
@override
void writeInto(MaterialC p) {
shader.writeInto(p.shader);
if (p.maps.address != 0) {
if (maps.isNotEmpty) {
for (int i = 0; i < maps.length; i++) {
maps[i].writeInto((p.maps + i).ref);
}
} else {
p.maps = nullptr;
}
}
for (int i = 0; i < paramCount; i++) {
p.params[i] = params[i];
}
}