nstudio / nativescript-plugins

@nstudio/nativescript-* plugin workspace.
Apache License 2.0
52 stars 40 forks source link

[camera-plus] Known issues: video recording and preview layer. #12

Closed Codex- closed 1 year ago

Codex- commented 3 years ago

This is to move the known issues from the old repository to here. My changes / PR were used as the base to move the code to here and there were some known issues particularly on iOS:

Crash log:

CONSOLE LOG: NativeScript-CameraPlus --- [MySwifty viewDidAppear]
Received configuration update from daemon (initial)
CONSOLE LOG: NativeScript-CameraPlus --- [xml width/height: 414x342]
====== Assertion failed ======
Native stack trace:
1          0x10112e12c tns::Assert(bool, v8::Isolate*) + 128
2          0x1010ef0f8 tns::MetadataBuilder::RegisterStaticMethods(v8::Local<v8::Context>, v8::Local<v8::Function>, tns::BaseClassMeta const*, tns::KnownUnknownClassPair, robin_hood::detail::Table<true, 80ul, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, unsigned char, robin_hood::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >&) + 476
3          0x1010ecf84 tns::MetadataBuilder::GetOrCreateConstructorFunctionTemplateInternal(v8::Local<v8::Context>, tns::BaseClassMeta const*, tns::KnownUnknownClassPair, robin_hood::detail::Table<true, 80ul, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, unsigned char, robin_hood::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >&, robin_hood::detail::Table<true, 80ul, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, unsigned char, robin_hood::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::_<\M-b\M^@\M-&>
4          0x1010eb1d0 tns::MetadataBuilder::GetOrCreateConstructorFunctionTemplate(v8::Local<v8::Context>, tns::BaseClassMeta const*, tns::KnownUnknownClassPair, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) + 88
5          0x1010959b0 std::__1::function<v8::Local<v8::FunctionTemplate> (v8::Local<v8::Context>, tns::BaseClassMeta const*, tns::KnownUnknownClassPair, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)>::operator()(v8::Local<v8::Context>, tns::BaseClassMeta const*, tns::KnownUnknownClassPair, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) const + 60
6          0x101092db4 tns::ArgConverter::CreateJsWrapper(v8::Local<v8::Context>, tns::BaseDataWrapper*, v8::Local<v8::Object>, bool, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) + 1392
7          0x1011563e4 tns::Interop::GetResult(v8::Local<v8::Context>, tns::TypeEncoding const*, tns::BaseCall*, bool, std::__1::shared_ptr<v8::Persistent<v8::Value, v8::NonCopyablePersistentTraits<v8::Value> > >, bool, bool, bool, bool) + 3708
8          0x101152614 tns::Interop::CallFunctionInternal(tns::MethodCall&) + 496
9          0x101092224 tns::ArgConverter::Invoke(v8::Local<v8::Context>, objc_class*, v8::Local<v8::Object>, tns::V8Args&, tns::MethodMeta const*, bool) + 780
10         0x1010f0100 tns::MetadataBuilder::InvokeMethod(v8::Local<v8::Context>, tns::MethodMeta const*, v8::Local<v8::Object>, tns::V8Args&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, bool) + 88
11         0x1010efbf4 tns::MetadataBuilder::PropertyGetterCallback(v8::FunctionCallbackInfo<v8::Value> const&) + 252
12         0x10126be10 v8::internal::FunctionCallbackArguments::Call(v8::internal::CallHandlerInfo) + 536
13         0x10126b3dc v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate*, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) + 516
14         0x10126add0 v8::internal::Builtins::InvokeApiFunction(v8::internal::Isolate*, bool, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::Object>, int, v8::internal::Handle<v8::internal::Object>*, v8::internal::Handle<v8::internal::HeapObject>) + 492
15         0x101591214 v8::internal::Object::GetPropertyWithAccessor(v8::internal::LookupIterator*) + 372
16         0x101590a6c v8::internal::Object::GetProperty(v8::internal::LookupIterator*, bool) + 140
17         0x1014247c8 v8::internal::LoadIC::Load(v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::Name>, bool) + 1428
18         0x10142cc64 v8::internal::Runtime_LoadNoFeedbackIC_Miss(int, unsigned long*, v8::internal::Isolate*) + 216
19         0x1019fcc4c Builtins_CEntry_Return1_DontSaveFPRegs_ArgvOnStack_NoBuiltinExit + 108
20         0x101a6f778 Builtins_LdaNamedPropertyHandler + 4408
21         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
22         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
23         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
24         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
25         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
26         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
27         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
28         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
29         0x10198e504 Builtins_ArgumentsAdaptorTrampoline + 228
30         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
31         0x10198e504 Builtins_ArgumentsAdaptorTrampoline + 228
32         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
33         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
34         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
35         0x10198e504 Builtins_ArgumentsAdaptorTrampoline + 228
36         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
37         0x10198e504 Builtins_ArgumentsAdaptorTrampoline + 228
38         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
39         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
40         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
41         0x10198e504 Builtins_ArgumentsAdaptorTrampoline + 228
42         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
43         0x10198e504 Builtins_ArgumentsAdaptorTrampoline + 228
44         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
45         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
46         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
47         0x10198e504 Builtins_ArgumentsAdaptorTrampoline + 228
48         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
49         0x1019956b4 Builtins_InterpreterEntryTrampoline + 244
50         0x101992f64 Builtins_JSEntryTrampoline + 164
51         0x101992c08 Builtins_JSEntry + 168
52         0x143b0c000 52  ???                                 0x0000000143b0c000 0x0 + 5430624256

Despite this being set: UISaveVideoAtPathToSavedPhotosAlbum(recordingPath, this, 'videoDidFinishSavingWithErrorContextInfo', null);

When you stop recording a video you get a hard crash with errors similar to this:

***** Fatal JavaScript exception - application has been terminated. *****
NativeScript encountered a fatal error: Uncaught Error: MySwifty<0x1088e5800> does not respond to selector videoDidFinishSavingWithErrorContextInfo
at
module.exports.push.../../src/camera-plus.ts.MySwifty.recordingReady(file:///app/bundle.js:788:17)
at module.exports.push.../../src/camera-plus.ts.SwiftyDelegate.swiftyCamDidFinishProcessVideoAt(file:///app/bundle.js:569:27)
*** Terminating app due to uncaught exception 'NativeScript encountered a fatal error: Uncaught Error: MySwifty<0x1088e5800> does not respond to selector videoDidFinishSavingWithErrorContextInfo
at
module.exports.push.../../src/camera-plus.ts.MySwifty.recordingReady(file:///app/bundle.js:788:17)
at module.exports.push.../../src/camera-plus.ts.SwiftyDelegate.swiftyCamDidFinishProcessVideoAt(file:///app/bundle.js:569:27)
', reason: '(null)'
CirXe0N commented 3 years ago

Is there any updates on this issue? Or maybe know where the issue might lie, so I can take a look at it? @Codex-

Codex- commented 3 years ago

@CirXe0N issue is as described above, any investigation / contributions are welcomed :)

macroorganizm commented 3 years ago

Are there any updates on this issue?