Search Unity

NatCorder - Video Recording API

Discussion in 'Assets and Asset Store' started by Lanre, Nov 18, 2017.

  1. unitydevstudio

    unitydevstudio

    Joined:
    Jun 24, 2017
    Posts:
    24
    Hi @Venzel
    I have one question for you.
    Your AR app uses ARFoundation and you have set the resolution to 720x1280.
    I also use ARFoundation and Natcorder. When I record with 720x1280, I got the video distorted video because device resolution is different with recording resolution like 1125x2436 or 1242x2688. So I use screen.width and height for recording resolution.
    Did you solve this problem?
    Or you mean you are recording the part(720x1280) of the full screen? how?
    I appreciate your help.

    Thanks.

    P.S: I am getting a crash due to memory leak on iOS 13.4 with Unity2019.3.13f, Natcorder 1.7.2 when start recording.
    You don't?
     
  2. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    I use NatCorder to record ARFoundation and I don't get a crash. Try out what I mentioned in my last post and share the memory profiler screen in Xcode.
     
  3. unitydevstudio

    unitydevstudio

    Joined:
    Jun 24, 2017
    Posts:
    24
    Hi, @Lanre
    Yes. I am trying now.
    By the way in Unity Editor, it occurs error - Object reference not set to instance of object. at CameraInput.cs:99
    It will work on iOS?
     
  4. Venzel

    Venzel

    Joined:
    May 7, 2018
    Posts:
    19
    Hello @unitydevstudio!
    I wrote "720x1280" as an example.
    In my real code I use Screen.width and Screen.height.
    If Screen.width more than 1500, I divide them by two. So it keeps aspect ratio the same.
    I have no crashes on start recording with NatCorder 1.7.1, Unity 2019.3.13, ios 13.4
     
    Lanre likes this.
  5. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Oops. In the `CameraInput` constructor, change this line:
    Code (CSharp):
    1. this.readbackBuffer = SystemInfo.supportsAsyncGPUReadback ? null : new Texture2D(frameBuffer.width, frameBuffer.height, TextureFormat.RGBA32, false, false);
    to this:
    Code (CSharp):
    1. this.readbackBuffer = new Texture2D(frameBuffer.width, frameBuffer.height, TextureFormat.RGBA32, false, false);
     
  6. unitydevstudio

    unitydevstudio

    Joined:
    Jun 24, 2017
    Posts:
    24
    Thanks for your quick response.
     
  7. unitydevstudio

    unitydevstudio

    Joined:
    Jun 24, 2017
    Posts:
    24
    hi, @Lanre
    I tried as you advised.
    But it's same
     
  8. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Then this issue is coming from something else. Recorders do not make any allocations; and since you've disabled async GPU readbacks, CameraInput doesn't make any allocations either. Can you create an empty project, import NatCorder, and show the memory behaviour from the ReplayCam example?

    Also, use Xcode's Instruments to see where these allocations are being made.
     
  9. Venzel

    Venzel

    Joined:
    May 7, 2018
    Posts:
    19
  10. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    This is a bug in NatDevice. I have a pretty good idea what's causing it so check back with me in a day or two for a build with the fix.
     
  11. infosekr

    infosekr

    Joined:
    Jul 12, 2013
    Posts:
    46
    I cannot build for iOS due to missing armv7 symbols, can you provide a library that includes both 32 and 64 bit symbols?

    ld: warning: ignoring file /.../Libraries/NatCorder/Plugins/iOS/libNatCorder.a, building for iOS-armv7 but attempting to link with file built for iOS-arm64

    Undefined symbols for architecture armv7:

    "_NCFinishWriting", referenced from:

    _Bridge_FinishWriting_mD4D0B20A3CCCD633B4F535B1786498B0A29E2D20 in Assembly-CSharp5.o

    _NativeRecorder_FinishWriting_m8BAF35AB9CA6CEBDCEBDA67936DCA82C05D851B1 in Assembly-CSharp5.o

    "_NCCommitSamples", referenced from:

    _Bridge_CommitSamples_mE29D3F2596E2A978081A5F9F25134D95EA5F8563 in Assembly-CSharp5.o

    _NativeRecorder_CommitSamples_mFC5E079ABFB6C5571908632515C03FA79759206E in Assembly-CSharp5.o

    "_NCCommitFrame", referenced from:

    _Bridge_CommitFrame_m42264022537D0F54FF1343495B786956FBB76AAC in Assembly-CSharp5.o

    _NativeRecorder_CommitFrame_mB60BB0953C71634B874BB297CD6E9A3A396F94C5 in Assembly-CSharp5.o

    "_NCFrameSize", referenced from:

    _Bridge_FrameSize_m152BC5DF440BC9FB000E705745323EC0AA2AB961 in Assembly-CSharp5.o

    _NativeRecorder_get_frameSize_m6E511F054C96AB1F86010C3AE2D8DEDF89145B8D in Assembly-CSharp5.o

    "_NCCreateMP4Recorder", referenced from:

    _Bridge_CreateMP4Recorder_m93A7B10DF439D19B90D6F3509E531BEE02AB321A in Assembly-CSharp5.o

    "_NCCreateHEVCRecorder", referenced from:

    _Bridge_CreateHEVCRecorder_m55AB98D7FD89C04B31C2B545EBF268A6F4480438 in Assembly-CSharp5.o

    "_NCCreateGIFRecorder", referenced from:

    _Bridge_CreateGIFRecorder_mE2AA8657B3EAB205C0E9DD20293F99FCC38CBD53 in Assembly-CSharp5.o

    ld: symbol(s) not found for architecture armv7
     
  12. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    The NatSuite Framework doesn't support armv7, and Unity is discontinuing support for armv7 in Unity 2020. Use arm64.
     
  13. infosekr

    infosekr

    Joined:
    Jul 12, 2013
    Posts:
    46
    After adding in NatCoder I'm forced by Apple to provide NSCameraUsageDescription. Is there a reason that NatCoder is making calls to an api that is triggering this requirement? I only record the screen and never want to access the physical camera or microphone on the device, and I don't want my users worried about this permission.
     
  14. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    This is probably because of the included example scenes which use the camera. Deleting the Examples folder in NatCorder (and making sure that the rest of your app does not use the camera) should take care of this.
     
  15. Menion-Leah

    Menion-Leah

    Joined:
    Nov 5, 2014
    Posts:
    189
    I don't know about @infosekr , but I never imported demo scenes from the NatCorder package, and NSCameraUsageDescription is required anyway
     
  16. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    NatCorder doesn't have any camera code, so this will have to be coming from somewhere else. You can do a `Find` in your project for references to `WebCamTexture`. Unity might also not be stripping `WebCamTexture`, though I'm not sure how the process works for them.
     
  17. infosekr

    infosekr

    Joined:
    Jul 12, 2013
    Posts:
    46
    After removing the Examples folder removed the need to include NSCameraUsageDescription.

    EDIT: Sorry, spoke too soon. Just got an email from my submission, looks like it still requires the NSCameraUsageDescription after removing that folder. Any other things I could try?
     
    Last edited: May 27, 2020
    Lanre likes this.
  18. infosekr

    infosekr

    Joined:
    Jul 12, 2013
    Posts:
    46
    Removing NatCoder/Plugins/Managed/Inputs/WebCameraTextureInput.cs solved the problem.
     
  19. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
  20. Venzel

    Venzel

    Joined:
    May 7, 2018
    Posts:
    19
    Hello @Lanre!
    Do you have any solution?
    It would be cool.
     
  21. vicente-beneitez

    vicente-beneitez

    Joined:
    Jun 28, 2019
    Posts:
    1
    Hi!
    I have problems with the NatCorder when I create a video screen capture on a Galaxy Note10+. It crashes and show an error like this: "The device has an odd resolution: 2280x1080"

    I need help. Thank you very much in advance.
     
  22. Venzel

    Venzel

    Joined:
    May 7, 2018
    Posts:
    19
    Hello @vicente-beneitez!
    You can just check for odd number and add one to the value:

    Code (CSharp):
    1. private void RoundScreenSize()
    2.     {
    3.         if (videoWidth % 2 == 1)
    4.         {
    5.             videoWidth++;
    6.         }
    7.  
    8.         if (videoHeight % 2 == 1)
    9.         {
    10.             videoHeight++;
    11.         }
    12.     }
     
  23. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Not yet unfortunately. I'll have to delay this to early next week because I have to address some other stuff. Sorry for the delay!
     
  24. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Can you share the full logs in a .txt attachment? The logged resolution is clearly not odd, and NatCorder would not log the line you've quoted, so I'm not sure where that is coming from.
     
  25. mayurasodariya33

    mayurasodariya33

    Joined:
    May 8, 2019
    Posts:
    5
    How to record video with custom path, Is there any example for it so that I can record video at my own path :) right now it get stored at "Data\" path. Could any one please guide me
     
  26. mayurasodariya33

    mayurasodariya33

    Joined:
    May 8, 2019
    Posts:
    5
    I just simple move the file to my desired location by ;- File.Move(rendererPath, finalPath);
     
    Lanre likes this.
  27. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    This is the correct thing to do.
     
  28. tztzo

    tztzo

    Joined:
    Nov 20, 2018
    Posts:
    1
    Hello, I have difficult to screen video record in my app , so I want to test your API.
     
  29. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Unfortunately there is no trial version of NatCorder. I recommend checking out the online documentation.
     
  30. Shadowdragon000

    Shadowdragon000

    Joined:
    Apr 21, 2018
    Posts:
    1
    Currently having an issue where on android the mp4 being output is empty/unplayable. It works fine on the desktop but I don't see any errors. Any suggestions?
     
  31. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Can you share the full logs from logcat in a .txt file?
     
  32. jrrathod7

    jrrathod7

    Joined:
    Dec 24, 2018
    Posts:
    6
    I am facing same issue in iOS. Where i have to do change to solve this bug.
     
  33. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    There is no minification on iOS, so you are likely facing an entirely different issue. Can you share more information? Error logs? Xcode screenshots?
     
  34. jrrathod7

    jrrathod7

    Joined:
    Dec 24, 2018
    Posts:
    6
    Bug Log Report.

    NatCorder: Prepared MP4 video encoder at resolution 720x1280@30.000000Hz with average bitrate 5909760 and keyframe interval 3s
    2020-06-07 09:04:16.657347+0530 app[2652:533300] NatCorder: Prepared MP4 audio encoder for 2 channels at 48000Hz
    2020-06-07 09:04:16.848232+0530 app[2652:533300] NatCorder Error: Failed to record video frame for time 55577000 due to invalid recorder state: 3


    Unity Version :- 2018.4.13f1
     
    Last edited: Jun 7, 2020
  35. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Can you share your full recording code? What device does this occur on?
     
  36. Venzel

    Venzel

    Joined:
    May 7, 2018
    Posts:
    19
  37. jrrathod7

    jrrathod7

    Joined:
    Dec 24, 2018
    Posts:
    6
    I am using IPHONE6 and XSMax.
    I want to record AudioListener Voice.
     

    Attached Files:

  38. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
  39. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    You are using an outdated version of NatCorder. Upgrade to NatCorder 1.7.2 on the Asset Store (first delete NatCorder in your project before importing the update) and try again.
     
  40. Sound-Master

    Sound-Master

    Joined:
    Aug 1, 2017
    Posts:
    48
    Hi, @Lanre

    I am using NatCorder with ARFoundation and I am having a problem where the Post Processing layer doesn't get recorded in the videos on Android (I haven't tried iOS yet).

    I am using Unity 2019.3.13f1, Natcorder 1.7.2, Universal RP 7.3.1 with Shader Graph, ARFoundation 4.0p1.
    The URP foward renderer is setup with the AR Background renderer feature as suggested to work with AR Foundation.

    The shader is set as a PBR graph.

    The Post Processing is setup using a Volume component on a dedicated gameobject. The URP settings have HDR enabled and the camera has post processing enabled.

    I can see the Post Processing effects on screen, they just don't get recorded in the videos.

    Many Thanks
    Michele
     
  41. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    NatCorder currently doesn't support HDR rendering. Specifically, `CameraInput` must render to an RGBA8888 RenderTexture because this is the pixel format that recorders expect, but as far as I know Unity will disable post fx when rendering to a non floating-point RenderTexture.
     
  42. Sound-Master

    Sound-Master

    Joined:
    Aug 1, 2017
    Posts:
    48
    Thank you for your quick response! That's too bad....
     
  43. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    I will look into adding support for this. Will you be able to provide a repro by any chance?
     
  44. Sound-Master

    Sound-Master

    Joined:
    Aug 1, 2017
    Posts:
    48
    That would be amazing! I will look at repackaging and send it to you.

    Many Thanks
    Michele
     
  45. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Sure thing just shoot me a PM.
     
  46. Flamacore

    Flamacore

    Joined:
    Dec 17, 2013
    Posts:
    140
    Hey there. Seeing you working on this day an night is great tbh :) I have a crash problem too but it occurs on every device. Editor, Android (Samsung S7 and S6 and Note4), iOS (iPhone8, iPhone6s) all to the highest available version.

    I have a crash dump from Unity editor here. It happens on StopRecording() but the problem is, it's inconsistent. Only happens every now and then and I cannot pinpoint why because the conditions are always the same when I stop recording. Sooo, have any leads on this? :)

    EXCEPTION_RECORD: (.exr -1)
    ExceptionAddress: 00007ff88d651273 (NatCorder!NCStopRecording+0x0000000000000003)
    ExceptionCode: c0000005 (Access violation)
    ExceptionFlags: 00000000
    NumberParameters: 2
    Parameter[0]: 0000000000000000
    Parameter[1]: ffffffffffffffff
    Attempt to read from address ffffffffffffffff

    PROCESS_NAME: Unity.exe

    READ_ADDRESS: ffffffffffffffff

    ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at 0x%p referenced memory at 0x%p. The memory could not be %s.

    EXCEPTION_CODE_STR: c0000005

    EXCEPTION_PARAMETER1: 0000000000000000

    EXCEPTION_PARAMETER2: ffffffffffffffff

    IP_ON_HEAP: 000001ed86e51327
    The fault address in not in any loaded module, please check your build's rebase
    log at <releasedir>\bin\build_logs\timebuild\ntrebase.log for module which may
    contain the address if it were loaded.

    FRAME_ONE_INVALID: 1

    STACK_TEXT:
    0000009e`e55de008 000001ed`86e51327 : 00000000`00000000 00007ff6`d3f1f736 00000000`00000000 00000000`00000000 : NatCorder!NCStopRecording+0x3
    0000009e`e55de010 000001ed`86e511f3 : 00007ff8`094bad78 00000000`00000000 000001ef`ab2aba20 00000000`00000000 : 0x000001ed`86e51327
    0000009e`e55de0b0 000001ed`86e510f8 : 0000009e`e55deb88 00000000`00000000 0000009e`e55de1b0 000001ef`a81958a3 : 0x000001ed`86e511f3
    0000009e`e55de100 000001ed`86e50df3 : 000001ef`a84b6700 000001ef`b2e63bd0 000001ef`b2e63bd0 0000009e`e55de178 : 0x000001ed`86e510f8
    0000009e`e55de150 000001f0`6f076713 : 000001ed`93fc0000 00007ff6`00000002 00007ff6`d8b86af0 00007ff6`d4cbf346 : 0x000001ed`86e50df3
    0000009e`e55de1c0 000001ef`af7accc1 : 00000000`00000000 00000000`00000000 3faf8f3e`3fd3bda7 40497150`3fd3bda7 : 0x000001f0`6f076713
    0000009e`e55de570 000001ef`af7aceb0 : 000001ef`b265dd20 00000000`00000000 00000000`00000001 00000000`00000000 : 0x000001ef`af7accc1
    0000009e`e55de5e0 00007ff8`0914cbb0 : 000001ef`ad6060be 0000009e`e55de8f0 0000009e`00000000 000001ef`ad0cc398 : 0x000001ef`af7aceb0
    0000009e`e55de690 00007ff8`090d2122 : ffffffff`fffffffe 00000000`0000000a 000001ef`e115e190 00000000`00000000 : mono_2_0_bdwgc!mono_jit_runtime_invoke+0x530
    0000009e`e55de870 00007ff8`090db11f : 0000009e`e55deb88 00000000`00000000 0000009e`e55dec30 000001ee`a741da01 : mono_2_0_bdwgc!do_runtime_invoke+0x82
    0000009e`e55de8c0 00007ff6`d3daa21e : 00000000`00000000 0000009e`e55debd0 00007ff8`090db0b0 00007ff6`d3d634e0 : mono_2_0_bdwgc!mono_runtime_invoke+0x6f
    0000009e`e55de970 00007ff6`d3da3f6d : 0000009e`e55debd0 000001ee`41e91d80 0000009e`e55deab0 000001ee`aa957a20 : Unity!scripting_method_invoke+0xbe
    0000009e`e55de9b0 00007ff6`d3d6649f : 000001ef`e115e190 00000000`00000000 000001ee`aa957a20 00000000`00000000 : Unity!ScriptingInvocation::Invoke+0x21d
    0000009e`e55deb00 00007ff6`d3d63a0c : 000001ee`aa957a20 0000009e`e55dee28 00000000`00000000 000001ef`b22aec00 : Unity!Coroutine::Run+0x29f
    0000009e`e55ded40 00007ff6`d3424b58 : 000001ee`a0b71a60 00000000`00000001 00000000`00000076 00000000`00000001 : Unity!Coroutine::ContinueCoroutine+0xbc
    0000009e`e55dedd0 00007ff6`d3852fff : 000001ee`00002776 000001ee`00000002 00007ff6`d3d63950 00007ff6`d8b595d8 : Unity!DelayedCallManager::Update+0x158
    0000009e`e55deeb0 00007ff6`d383c3c8 : 00007ff6`d8a89a10 000001ee`a5f5a8a0 000001ee`a5f59c60 00000000`00000000 : Unity!`InitPlayerLoopCallbacks'::`2'::UpdateScriptRunDelayedDynamicFrameRateRegistrator::Forward+0x4f
    0000009e`e55deef0 00007ff6`d383c49d : ffffffff`fffffffe 00000000`00000000 0000009e`e55df200 00007ff6`d3d9df45 : Unity!ExecutePlayerLoop+0x58
    0000009e`e55df0b0 00007ff6`d3841694 : 000001ee`a0d8a101 000001ee`a0d8a101 00000000`00000001 00000000`00000001 : Unity!ExecutePlayerLoop+0x12d
    0000009e`e55df270 00007ff6`d1c5632b : 000001ee`00000001 000001ee`a0d8a1e0 449b4000`45280000 000001ee`a05ffc88 : Unity!PlayerLoop+0x194
    0000009e`e55df310 00007ff6`d1c54268 : 000001ee`40f7f220 000001ee`40f7f220 00007ff6`d8a9e538 0000009e`e55df4c0 : Unity!PlayerLoopController::UpdateScene+0x1ab
    0000009e`e55df3c0 00007ff6`d2597860 : 00000000`00000000 000001ee`41432020 00007ff6`d8a9e510 00000000`00000000 : Unity!Application::TickTimer+0x1378
    0000009e`e55df670 00007ff6`d25a15fa : 00007ff6`d8b02d10 00007ff6`d5ccf8b0 00007ff6`d259b870 00007ff6`d5cd14c8 : Unity!MainMessageLoop+0x240
    0000009e`e55df8c0 00007ff6`d5525762 : 00000000`0000000a 00000000`00000000 00000000`00000000 00000000`00000000 : Unity!WinMain+0xf6a
    0000009e`e55efb50 00007ff8`98d07bd4 : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : Unity!__scrt_common_main_seh+0x106
    0000009e`e55efb90 00007ff8`9942ce51 : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : kernel32!BaseThreadInitThunk+0x14
    0000009e`e55efbc0 00000000`00000000 : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : ntdll!RtlUserThreadStart+0x21


    SYMBOL_NAME: NatCorder!NCStopRecording+3

    MODULE_NAME: NatCorder

    IMAGE_NAME: NatCorder.dll

    STACK_COMMAND: ~0s ; .ecxr ; kb

    FAILURE_BUCKET_ID: INVALID_POINTER_READ_c0000005_NatCorder.dll!NCStopRecording

    OS_VERSION: 10.0.18362.1

    BUILDLAB_STR: 19h1_release

    OSPLATFORM_TYPE: x64

    OSNAME: Windows 10

    FAILURE_ID_HASH: {291306cc-881e-d3e3-c2d8-9676621b41a7}

    Followup: MachineOwner
    ---------
     
  47. Lanre

    Lanre

    Joined:
    Dec 26, 2013
    Posts:
    3,971
    Hey there. You seem to be using an outdated version of NatCorder. Grab the 1.7.2 upgrade from the Asset Store. Make sure to delete NatCorder in your project before importing the update.
     
  48. Flamacore

    Flamacore

    Joined:
    Dec 17, 2013
    Posts:
    140
    Oh for sure. Lemme try that immediately :)
     
    Lanre likes this.
  49. nativehfQ

    nativehfQ

    Joined:
    Nov 1, 2017
    Posts:
    11
    Hi I am trying Natcoder on Android 11 device and seeing the error below, can you check in your native code please?

    Line 1815: 06-16 15:38:21.463 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 1819: 06-16 15:38:21.478 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 1823: 06-16 15:38:21.482 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 1829: 06-16 15:38:21.492 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 1838: 06-16 15:38:21.513 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    ...
    Line 2195: 06-16 15:38:22.245 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 2198: 06-16 15:38:22.255 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 2211: 06-16 15:38:22.282 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 2223: 06-16 15:38:22.311 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 2227: 06-16 15:38:22.320 30473 30663 E Unity : NatRender Error: Performed blit with error 1286
    Line 2234: 06-16 15:38:22.334 30473 30663 E Unity : NatRender Error: Performed blit with error 1286

    The error keeps showing as long as recording APIs are not disposed. I am using the mp4 API and the file is not getting saved.

    The same code works fine on Android 8 device. Really need help, thanks
     
  50. nativehfQ

    nativehfQ

    Joined:
    Nov 1, 2017
    Posts:
    11
    Update:
    Unity version 2019.3.7f1
    compiling for ARM64 (LL2CPP)
    Graphics APIs tried: Vulkan, OpenGLES3, OpenGLES2