MCPcopy Create free account
hub / github.com/BatchDrake/SigDigger / openRaw

Method openRaw

Tasks/ExportSamplesTask.cpp:267–289  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

265}
266
267bool
268ExportSamplesTask::openRaw(void)
269{
270 SF_INFO sfinfo;
271
272 sfinfo.channels = 2;
273 sfinfo.samplerate = static_cast<int>(fs);
274 sfinfo.format = SF_FORMAT_RAW | SF_FORMAT_FLOAT;
275
276 if ((this->sfp = sf_open(
277 path.toStdString().c_str(),
278 SFM_WRITE,
279 &sfinfo)) == nullptr) {
280 this->lastError =
281 "Cannot open "
282 + this->path
283 + ": "
284 + QString(strerror(errno));
285 return false;
286 }
287
288 return true;
289}
290
291
292bool

Callers 1

attemptOpenMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected