Open justinmakaila opened 9 years ago
I started to use a custom output url (also in the temp dir) and I'm seeing the error less. I'm not sure if that was actually the cause, and would still appreciate feedback.
Could you share the additional informations held by this exception? Seems like you are using SCAssetExportSession correctly.
Yes.
*** -[AVAssetWriter initWithURL:fileType:error:] invalid parameter not satisfying: outputURL != ((void *)0)
It's an NSInvalidArgumentException
.
Let me know if you need more details.
That helps! If you don't set a fileType inside the SCRecordSession, it tries to figure out one based on the info it has from SCRecorder. I suppose at that point you detached this recordSession from the recorder, which means it doesn't know which fileType to use anymore. It could be improved, as if the recordSession already has segments, it should be able to figure out a fileType without asking the recorder. The fix for now is to manually set a fileType inside your recordSession. Tell me if that works.
@rFlex AWESOME. I'm going to implement your change this evening, I'll report back here. Thanks!
@rFlex that solution worked for most cases. I'm now having the same issue exclusively with videos that are recorded to the maximum duration. Any ideas?
Almost 1 in every 6 times, the
SCAssetExportSession
throws an exception:I configure the session like so:
The
SCRecordSession
is also impossible to retry (the exception is thrown over and over again).The strange thing is that the
SCRecordSession
is only one segment, and should not be too complicated to export. Can you please provide insight? I'm trying to use the library for a client and this is blocking.