close method
void
close()
Implementation
void close() {
if (_closed) return;
if (_streams.any((s) => s._busy)) {
throw StateError('Audio encoder has a busy stream');
}
_closed = true;
for (final stream in _streams.toList()) {
stream.close();
}
_gpu?.dispose();
_gpu = null;
for (final m in _matrices.values) {
m.free();
}
_matrices.clear();
_floats.clear();
}