Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice
  3. Dismiss Notice

[Released] AVPro Movie Capture

Discussion in 'Assets and Asset Store' started by AndrewRH, Jan 24, 2012.

  1. amz012_utida

    amz012_utida

    Joined:
    Nov 16, 2016
    Posts:
    4
    Linear. I have not tried anything else.
    Same result when I get a PNG sequence.
    Camera capture is used.
     
  2. monkeydev4

    monkeydev4

    Joined:
    Jan 7, 2022
    Posts:
    2
    Hi Chris,

    We're also having issues with recordings being darker. In our case, this happens on Android as well though iOS is much worse. Linear colour space, did not try PNG sequence, tried both Camera Capture and Texture Capture with same results. Unity 2021.3.2 and also tried 2021.3.26.
     
  3. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    @monkeydev4,

    Is this using URP?

    Kind regards,
    Chris
     
  4. monkeydev4

    monkeydev4

    Joined:
    Jan 7, 2022
    Posts:
    2
    This is using the Standard Pipeline.

    Another thing to note is that we're using AR Foundation. We initially had a single camera and used Capture from Camera which introduced a lot of stuttering on Android. This was mostly due to AR Core limiting the framerate to 30fps so while recording the framerate was dropping between 7 and 15. We had dark videos then too but this was before we purchased the asset so we assumed the darkness was part of the watermark.

    We now have the Ultra Edition and we're now using a second camera that renders to a render texture. We set that to the Capture from Texture component. Framerate still drops to about 20 but a significant improvement. Recordings are still dark.

    In regards to iOS, the framerate is significantly better. Sits around 45 - 50 while recording but the videos are still dark.
     
  5. Gunhi

    Gunhi

    Joined:
    Apr 18, 2012
    Posts:
    300
    AVPro Movie Capture - Basic Edition License V5, I bought it from the AssetStore. How can I upgrade it to Desktop License?
     
  6. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi,

    We have managed to reproduce the colour issue.
    The issue is caused by Unity picking a floating point texture format for its render target that we don't currently account for. This is also why it was tricky to track down as this format wasn't being chosen on the devices we have access to.

    A fix will make it into the next release.

    Kind regards,
    Chris
     
    amz012_utida and monkeydev4 like this.
  7. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi @Gunhi ,

    You should be able to upgrade with the discounted rate automatically applied on the Desktop Edition page of the Unity Asset Store as long as you are logged in using the same account that you have the Basic Edition.

    Kind regards,
    Chris
     
  8. Ste-RH

    Ste-RH

    Joined:
    May 17, 2019
    Posts:
    149
    Hi Everyone,

    AVPro Movie Capture version 5.1.7 has just been released!

    DOWNLOAD HERE

    Changes include:

    General
    • Fixes
      • #279 Added warning if capture component is disabled before file writes have completed
      • #294 Fixed camera rotation not being honoured with mono camera in Capture From Camera 360 (VR) component
    macOS/iOS
    • Fixes
      • #276 Fixed issue with captures in linear colourspace coming out darker when using URP
      • #292 Plugin built with Xcode 13.2.1 to resolve bitcode compatibility issue with Unity
    Thanks to everyone that reported bugs that were fixed in this release :)

    Please report any issues to our Github Issues
     
    amz012_utida likes this.
  9. Rave-TZ

    Rave-TZ

    Joined:
    Jul 21, 2013
    Posts:
    84
    Is there a method in AVPro Movie Capture to stream to a URL / RTMP?
     
  10. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
  11. choigw

    choigw

    Joined:
    Jul 21, 2020
    Posts:
    4
    Hi,
    I have a question.
    how to handle when the device does not have enough space for recording?

    i'm using avpro capture ultimate and my app is working on ios, android, windows.
    in windows, there is the function for checking the freespace and it stops but other platforms?
    can i add that function on android, ios?
    give me an advice.

    thank you in advance.
     
  12. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
  13. mchangxe

    mchangxe

    Joined:
    Jun 16, 2019
    Posts:
    69
    Hello, ive came across a weird bug. When in build, the first time i call startcapture occasionally leads to application freezing for about 30-60 seconds. Afterwards, the application resumes and work properly for the subsequent startcaptures. Any ideas? The last line in the log is the usual avpro startcapture log. Thanks!

    EDIT: Upon further inspection, it seems like a screenshot before/after avpro startcapture causes the whole app to freeze and crash: WeChat Image_20230903140525.png
    Maybe the screenshot and startcapture is fighting over RenderTexture.active?

    EDIT2: I commented out the screenshot code, and the problem still persists on StartCapture....

    EDIT3: I found that the freeze happens in StartCapture -> PrepareCapture -> NativePlugin.CreateRecorderVideo.

    EDIT4 SOLVED: solved by turning on _forceGPUFlush
     
    Last edited: Sep 3, 2023
    Chris-RH likes this.
  14. Rave-TZ

    Rave-TZ

    Joined:
    Jul 21, 2013
    Posts:
    84
    Any option to flip horizonal? I'm capturing from camera on Android
     
  15. SuperNbie

    SuperNbie

    Joined:
    Nov 1, 2012
    Posts:
    15
    Basic Edition Can Record Unity Audio with "Capture Audio(From AudioListener)"?
     
  16. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi,

    Horizontal flip isn't an option that we support.

    Kind regards,
    Chris
     
  17. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi,

    Yes, in the Basic Edition only Capturing from Unity Audio is available.

    Kind regards,
    Chris
     
  18. Ste-RH

    Ste-RH

    Joined:
    May 17, 2019
    Posts:
    149
    Hi Everyone,

    AVPro Movie Capture version 5.1.8 has just been released!

    DOWNLOAD HERE

    Changes include:

    macOS/iOS
    • Fixes
      • #308 Fixed issue with Capture From Screen component not capturing when using Unity 2022 or later with URP
      • #311 Fixed issue with audio capture from microphone continuing when the capture is paused
      • #316 Fixed issue with failing to save captures to the photo library
    iOS
    • Enhancements
      • #301 Added support for bluetooth audio input devices
    Android
    • Fixes
      • Fixed issue with output being incorrect on some devices when no capture rotation is enabled and the encoder does not support the resolution being requested
    • Known Issues
      • When using Unity 2022 or later, CaptureFromScreen will produce incorrect captures when using the Vulkan graphics API with 'PlayerSettings.vulkanEnablePreTransform' enabled

    Thanks to everyone that reported bugs that were fixed in this release :)

    Please report any issues to our Github Issues
     
  19. unitea_terekhin

    unitea_terekhin

    Joined:
    Oct 28, 2023
    Posts:
    1
    I try to use CaptureFromCamera.GetPreviewTexture but I get only null.
     
  20. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi @unitea_terekhin,

    That's strange. Could you provide a bit more detail please.
    1. AVPro version
    2. Platform
    3. What is happening while you are trying to use CaptureFromCamera.GetPreviewTexture? Are you doing this before, during or after capture?
    4. Is the capture itself working?
    Kind regards,
    Chris
     
  21. kasym_

    kasym_

    Joined:
    Oct 18, 2022
    Posts:
    11
    Hello Renderheads team!

    I am using latest AVPro Movie Capture (ultra edition) and recording from WebCamTexture. Then I am sending that video to a backend server.
    At some point I download the videos from the backend and play it using built in video player.

    It works fine for high end devices, but as I switch to low end devices problems start to occur on Android.
    Video recorded on a powerful device when watched from a weak device stutters, sometimes I hear stuttering audio but can't see the video.
    On iOS everything seems to be fine

    Could you please tell me what could be possible issues, what are the potential optimization tips?
     
  22. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi @kasym_

    Without knowing the specs of the videos you are recording or which devices are struggling to play the video, I would suggest:
    Reduce the video resolution
    Reduce the video FPS
    Reduce the video bitrate
    Try encoding using a different codec

    Kind regards,
    Chris
     
  23. RiVRUK

    RiVRUK

    Joined:
    Oct 19, 2023
    Posts:
    2
    Hi, Hoping you can help.

    Upside down video and no audio on Android (works fine in editor, Windows 11

    Unity 2022.3.1
    Latest Evaluation version of Move Capture
    Hardware as a Quest 3

    Using CaptureFromTexture

    H.264
    AAC
    Capturing from Microphone default index (permissions checked)
    Texture source is a RenderTexture attached to a camera in scene.
    There is also a RawImage using the RenderTexture as the source (for video viewfinder in a camera)

    RenderTexter res 1280x720

    Code to start the capture is

    Code (CSharp):
    1.        
    2.         _movieCapture.AudioCaptureSource = AudioCaptureSource.Microphone;
    3.         _movieCapture.ForceAudioInputDeviceIndex = 0;
    4.         _movieCapture.SetSourceTexture(_view.CameraScreenRenderTexture);
    5.         _movieCapture.FilenamePrefix = newVideo.Id;
    6.         _movieCapture.StartCapture();
    Android Video:
    1.png

    Windows Video:
    2.png
     

    Attached Files:

    • 1.png
      1.png
      File size:
      35.8 KB
      Views:
      39
    • 2.png
      2.png
      File size:
      38.6 KB
      Views:
      39
  24. RiVRUK

    RiVRUK

    Joined:
    Oct 19, 2023
    Posts:
    2
    Log output
    10/11/2023 17:08:45 [AVProMovieCapture] Init version: 5.1.8 (plugin v5.1.8-trial) with GPU Adreno (TM) 740 Vulkan 1.1.0 [512.737.0] OS: Android OS 12 / API-32 (SQ3A.220605.009.A1/49743630046900510)

    10/11/2023 17:08:46 [AVProMovieCapture] Start File Capture: 1280x720 @ 24.00fps [RGBA32] vcodec:'HEVC' audio source:'Default Microphone' acodec:'AAC' to file: '/storage/emulated/0/Android/data/uk.rivr.arc/files/Videos/cf354e2d-c4a2-43f4-969a-faa4e9b98452.mp4'

    10/11/2023 17:08:49 [AVProMovieCapture] Stopping capture 46656

    10/11/2023 17:08:49 Video Saved: RenderHeads.Media.AVProMovieCapture.FileWritingHandler
    RenderHeads.Media.AVProMovieCapture.FileWritingHandler:Dispose()
    RenderHeads.Media.AVProMovieCapture.FileWritingHandler:IsFileReady()
    RenderHeads.Media.AVProMovieCapture.CaptureBase:RemoveCompletedFileWrites()
    RenderHeads.Media.AVProMovieCapture.CaptureBase:LateUpdate()

     
  25. SuperNbie

    SuperNbie

    Joined:
    Nov 1, 2012
    Posts:
    15
    Basic Edition Can Record with "Capture from WebCamTexture"?
     
  26. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi @RiVRUK,

    Could you open this as an issue on our github please and complete the bug report?

    Kind regards,
    Chris
     
  27. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi @SuperNbie,

    No, the Basic edition is Screen Capture only.

    Kind regards,
    Chris
     
  28. chrpetry

    chrpetry

    Joined:
    Mar 7, 2018
    Posts:
    65
    Hello,

    I'm struggling with getting my own watermark to be rendered correctly.
    I have to render with CaptureFromCamera. When adding my watermark via camera canvas the PostProcessing also is applied on the watermark, which I don't want.
    So I tried an alternative with adding a separate camera to the "contributing" cameras in order to add the watermark by rendering it on top. But somehow this does not work at all. I tried clear flags etc. but only the "lastCamera" is considered in the resulting video.
    Can you give me a hint on how to do this?

    Im using Unity 2022.1.24 with built-in render pipeline.
     
  29. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi @chrpetry,

    I'm afraid that we don't support that functionality yet. Its on our list of possible future enhancements.

    Kind regards,
    Chris
     
  30. Ste-RH

    Ste-RH

    Joined:
    May 17, 2019
    Posts:
    149
    Hi Everyone,

    AVPro Movie Capture version 5.2.0 has just been released!

    DOWNLOAD HERE

    Changes include:

    General
    • Enchancements
      • #305 Reworked CaptureFromScreen to not call StartCoroutine every frame
      • #338 Added property for `_pauseCaptureOnAppPause`
      • #338 Added property for `_pauseCaptureOnAppPause`
      • Added convenience method `SetMicrophoneRecordingHint` to `CaptureBase`
    macOS/iOS
    • Enhancements
      • #331 Added fixed and nearest frame presentation timestamp modes for realtime capture
    iOS/Android
    • Enhancements
      • #235 Added support for writing webcam texture orientation metadata to the captured video file
    Android
    • Fixes
      • #344 Fixed issue with captures being flipped when using the CaptureFromTexture component
    • Known Issues
      • When using Unity 2022 or later, CaptureFromScreen will produce incorrect captures when using the Vulkan graphics API with ```PlayerSettings.vulkanEnablePreTransform``` enabled

    Thanks to everyone that reported bugs that were fixed in this release :)

    Please report any issues to our Github Issues
     
  31. Noisecrime

    Noisecrime

    Joined:
    Apr 7, 2010
    Posts:
    2,058
    Got a strange colour issue when using captureFromCamera, where the exported video is much darker than the source camera. Was wondering if anyone has any suggestions as to how I might fix it.

    Below is a gif that cycles between GameView - AVProCapture Video frame - AVProCapture PNG - Video frame - Unity CaptureScreen - Video frame - AVProCapture inspector over gameView - Video frame

    As you can see screenshots of the GameView & AVProCapture Inspector, AVProCapture PNG and Unity's own captureScreenshot methods all have the same color appearance. Toggling between them in photoshop layers shows no changes. However the AVProCapture video output is clearly darker.

    VideoEncodingIssue.gif
    • Unity: 2018.4.23f1
    • AVProCapture: 5.2.0
    • OS: Windows 10
    • Renderer: Built-in using Gamma space and DX11.
    • ImageEffects: HBAO, Tiltshift, Vignette, Amplify Colour.
    I realise that the Unity version is old and there are plans to update the project in the future, but its not straightforward process. In addition other than addressing the use of TryGetComponent<> and the colour problem everything else seems to work perfectly.

    I'm wondering if there is anything in the video codec being used that could be tweaked to fix the colour or if there might be some weird gamma/linear issue going?

    EDIT - More Weirdness
    I opened the video file in DaVinci Resolve to conduct further testing and the video from AVProCapture had the correct colour! The darker appearance of mp4 video is coming from opening it in VLC Player. I then tried playing the file in a browser window and that too had the darker appearance.

    What really confuses me though is if I use FFMPEG to convert the png export from AVProCapture and my own solution using Unity captureScreenshot, when I compare those to the video output from AVProCapture, all three are exactly the same colour wise in Davinci, but in VLC the FFMPEG ones are colour correct but the video is not! I made a table to show the issue.

    Results.png

    I'm not sure what is going on exactly maybe some colorspace encoding embedded in the video itself that DaVinci or VLC is ignoring perhaps? Maybe AVproCapture is not embedding the correct colourspace profile or something?

    If anyone can offer an explanation I'd love to know the specifics

    For reference here is the FFMPEG command I used on the png images.
    ffmpeg -framerate 30 -i Frame_%06d.png -c:v libx264 -crf 15 -pix_fmt yuv420p out.mp4
     
    Last edited: Dec 24, 2023
  32. Chris-RH

    Chris-RH

    Joined:
    Apr 21, 2022
    Posts:
    223
    Hi @Noisecrime

    Thank you, that's a very detailed analysis.
    I would be interested in knowing what results you get using a linear colourspace or H265.
    What do you get if you use ffprobe on your outputted video file?

    Kind regards,
    Chris
     
  33. Noisecrime

    Noisecrime

    Joined:
    Apr 7, 2010
    Posts:
    2,058
    Thanks for your reply.
    I'm unable to test with linear colour space atm, but will give H265 a try when I can. In the meantime I ran FFProbe ( thanks for suggesting it ) and there are a couple of discrepancies that might explain the issue;
    • AVProMovieCapture uses pix-fmt of yuvj420p vs yuv420p.
    • AVProMovieCapture includes a parameter called 'Color-Range' with a value of 'PC'.
    I feel that either of these could be the culprit, but its important to remember that its only the AVPro video has the incorrect colour when directly compared against the Unity output, unless its open in DaVinci Resolve. So while its my understanding that yuvj420p has greater range and should therefore provide better colour reproduction, its the one that is causing the darker/incorrect colour appearance.

    Is there any way I can affect these settings in the plugin, perhaps override the pix-fmt, at least to test to see if they are the problem?

    Small aside but are there any recommendations for setting the quality for the video? I've left them at default, but would like to try with higher settings, but I don't know what the defaults are. Although I guess now i've got FFProbe I can see the bitrate from that. Just wondering if RenderHeads have written out a 'best practice' or guidance as to settings to use?
     
  34. Ste-RH

    Ste-RH

    Joined:
    May 17, 2019
    Posts:
    149
    Hi Everyone,

    AVPro Movie Capture version 5.2.1 has just been released!

    DOWNLOAD HERE

    Changes include:

    General
    • Enhancements
      • Reduced CPU overhead of calling StartCapture
    Android
    • Enhancements
      • Added support for saving Relative To Pictures
      • Switched to using Oboe for capturing audio from the microphone
      • Added caching of the video codec's format when creating a video recorder in order to reduce CPU overhead for subsequent calls with matching parameters
    • Fixes
      • #344 Fixed issue with image sequence captures being flipped vertically
      • #347 Fixed issue with captures failing when the avc1 codec doesn't support the High profile
      • #361 Fixed issue with orientation metadata not being written correctly
      • #364 Fixed issue with OpenGLES 3 resources not being released when disposing of a capture instance
      • Fixed issue with captures failing in Basic edition when using the Vulkan graphics API

    Thanks to everyone that reported bugs that were fixed in this release :)

    Please report any issues to our Github Issues
     
  35. Ste-RH

    Ste-RH

    Joined:
    May 17, 2019
    Posts:
    149
    Hi Everyone,

    AVPro Movie Capture version 5.2.2 has just been released!

    DOWNLOAD HERE

    Changes include:

    General
    • Fixes
      • #371 Fixed typo in CaptureBase.OutputPath.RelativeToPersistentData, marked old spelling as deprecated
    Android
    • Enhancements
      • #196 Added support for android permissions check for writing to videos
    • Fixes
      • #370 Fixed issue with glsl shaders failing to compile on devices without support for glsl 3.1
      • #372 Fixed issue with stride and slice height being set incorrectly on certain hardware leading to freezes/crashes

    Thanks to everyone that reported bugs that were fixed in this release :)

    Please report any issues to our Github Issues
     
  36. AndrewRH

    AndrewRH

    Joined:
    Jan 24, 2012
    Posts:
    2,806
    Hi Everyone,

    AVPro Movie Capture version 5.2.3 has just been released!

    DOWNLOAD HERE

    Changes include:

    Android
    • Fixes
      • #370 Fixed issue with shaders failing to compile on devices running Android 9 with Adreno 308 GPU
      • #375 Fixed issue with capture failing when using Unity2023.1 and later with "Application Entry Point" set to "GameActivity"
      • #377 Fixed crash when capturing images and the renderer API is OpenGLES 3

    Thanks to everyone that reported bugs that were fixed in this release :)

    Please report any issues to our Github Issues
     
  37. Ste-RH

    Ste-RH

    Joined:
    May 17, 2019
    Posts:
    149
    Hi Everyone,

    AVPro Movie Capture version 5.2.4 has just been released!

    DOWNLOAD HERE

    Changes include:

    Android
    • Fixes
      • #372 Fixed issue with invalid values being set for stride and slice height when failing to configure the media codec
    macOS/iOS
    • Changes
      • Added privacy manifest

    Thanks to everyone that reported bugs that were fixed in this release :)

    Please report any issues to our Github Issues
     
  38. sonofbryce

    sonofbryce

    Joined:
    May 19, 2009
    Posts:
    112
    I had problems getting the "CompletedFileWritingAction" event to fire with "CaptureFromCamera." To get it to work, I ended up having to copy this "_fileWritingHandlers.Add(handler)" to OnBeginFinalFileWriting(), as in the Demo file.

    Code (CSharp):
    1.         private void OnBeginFinalFileWriting(FileWritingHandler handler)
    2.         {
    3.             _fileWritingHandlers.Add(handler);
    4.         }
    Just mentioning it in case this is useful.
     
  39. makaka-org

    makaka-org

    Joined:
    Dec 1, 2013
    Posts:
    1,077
    Hi, I am searching for a replacement of Cross-Platform Screen Recorder Kit for my App (AR Masker) for Android & iOS.

    I need Screen Recording and internal Mic Recording for an app that uses AR Foundation (ARKit, ARCore), Face Tracking and Universal Render Pipeline.

    The mentioned asset causes some audio delay, even on iPhone 15.
    The iPhone XS Max has even more audio delay (less than a second, but still).

    Separately from this asset, Unity integration with Replay Kit also has audio delay when using AR Foundation and Face Tracking, even with simple Face Tracking scene from public Unity repo.

    My questions about your plugin:
    1. Did you test Screen Recording of your plugin with AR Foundation and Face Tracking?
    2. What about audio delay?
    3. Have your asset any nuances when using AR Foundation, Face Tracking and URP?
    4. Basic Edition will be enough for my needs?
     
    Last edited: May 14, 2024
  40. makaka-org

    makaka-org

    Joined:
    Dec 1, 2013
    Posts:
    1,077
    Are you guys still working? I have no answers to my questions here and on the GitHub for weeks.
    I bought the Mobile Edition.
     
  41. wechat_os_Qy02fzyOGnzWoIhqek1ZhmB5s

    wechat_os_Qy02fzyOGnzWoIhqek1ZhmB5s

    Joined:
    Aug 6, 2020
    Posts:
    5
    Hello, I am very honored to purchase AVPro Movie Capture. AVPro Capture works well on Windows platform, but when I click to record screen on Android phone, there is no video. How can I record video on Android? Thank you very much!
     
  42. makaka-org

    makaka-org

    Joined:
    Dec 1, 2013
    Posts:
    1,077
    Folder > Relative to Pictures. This way, the photo will be saved into DCIM folder and will be shown in Gallery app.

    P.S. The Samsung A71 has a delay of showing in the Gallery app. When using the default Camera app, there is no delay.
     
  43. mw2357

    mw2357

    Joined:
    Jul 12, 2020
    Posts:
    20
    Hi, is it possible to use this asset to record ingame videos from a Quest 3 VR headset in stand alone mode (not connected to a PC)? Given the headset is based on Android I suspect it might be possible.. But wondering if the performance of the VR game will decrease significantly? And it would require to access the Quests file system to store the captured video.