Search Unity

Video Unity Video player lose video quality, anyway to avoid it?

Discussion in 'Audio & Video' started by deano37, Oct 12, 2017.

  1. deano37

    deano37

    Joined:
    Apr 18, 2016
    Posts:
    2
    This is becoming very frustrating for me and I am looking for a way to avoid this issue.

    The problem is, whenever I imported a .mp4 (h.264 24000 bit rate 2k resolution) video file into unity and play it through videoplayer and make it into a VR app. It is noticeable that the video has been compressed in a way that the quality is dropped compared to the original video quality. I tried to play the video file directly in one of the other VR video player app such as (VR media player 360 - android) and it seems they can play the VR video file without downgrade of quality or compression. It was just better.

    Does anyone else encountered this problem and found a way to avoid it?
     
  2. jocyf

    jocyf

    Joined:
    Jan 30, 2007
    Posts:
    288
    I just dont "Transcode" the video in unity and play it as it is. Take into account that transcoding is taking your compressed .mp4 video as source, so it will loss quality for sure when unity recompress it to its own internal codec.

    I use H264 videos with profiler Baseline or Main and Encoder Level 3.0 or 3.1 and it works fine (In normal project not VR ones). I'm playing the video over a 3d surface (a plane) not full screen.

    Hope that helps
     
  3. deano37

    deano37

    Joined:
    Apr 18, 2016
    Posts:
    2
    Thanks jocyf, will start testing and experimenting the resolution. I tried using 2017 skybox solution but it seems the resolution is getting even worse. I will try it again without transcoding the video clip and see how it goes.
     
  4. Folond

    Folond

    Joined:
    Nov 8, 2016
    Posts:
    1
    Hi, I have the same problem, have you found a solution?
     
  5. losingisfun

    losingisfun

    Joined:
    May 26, 2016
    Posts:
    36
    in your texture, change the dimensions up to the resolution of the video, eg, instead of it being 256x256, try using 1080x720
     
  6. jocyf

    jocyf

    Joined:
    Jan 30, 2007
    Posts:
    288
    If you use an skyBox take into account that you'll need a huge resolution in VR. An 1080p HD video is low if you want to see in 360º. Maybe you need 2k (I tested 2K videos on a skybox in a Oculus Go and it works fine)
     
  7. fafase

    fafase

    Joined:
    Jul 3, 2012
    Posts:
    163
    Just want to emphasize on losingfun answer above. Setting the render texture to the ratio of the video will get it back to original quality.
     
    FaisalGamingStudio likes this.
  8. jocyf

    jocyf

    Joined:
    Jan 30, 2007
    Posts:
    288
    You need to update both... obviously :)
     
  9. awkwardstreamer

    awkwardstreamer

    Joined:
    Apr 21, 2020
    Posts:
    4
    hey i know this is old but i actually got the best result from the "color format" options, i noticed if i played my video in a video player outside of unity it looked great, so i went through them and found one that was the closest to what i was expecting, my texture resolutions are all over the place. just thought id post incase it can help anyone aswell. mine was a 4096 x 4096 top/bottom stereoscopic clip Films & TV 2020-06-13 2_31_59 PM.png pic.png pic3.png
     

    Attached Files:

    • pic.png
      pic.png
      File size:
      146.3 KB
      Views:
      462
    • pic2.png
      pic2.png
      File size:
      153.1 KB
      Views:
      432
  10. SibochCZ

    SibochCZ

    Joined:
    Apr 29, 2017
    Posts:
    3
    Thanks.
     
  11. engnouramer3

    engnouramer3

    Joined:
    Apr 22, 2021
    Posts:
    2
    thanks alot
     
  12. FaisalGamingStudio

    FaisalGamingStudio

    Joined:
    Oct 25, 2017
    Posts:
    1
    Thanks Its work!
     
  13. AdrianGTR

    AdrianGTR

    Joined:
    Jan 6, 2021
    Posts:
    4
    Thanks! It's still valid! Hahaha... You saved me with an easy solution! <3