Search Unity

EveryPlay Upside down on ios

Discussion in 'Unity Everyplay' started by WellC, Jan 19, 2017.

  1. WellC

    WellC

    Joined:
    Mar 2, 2015
    Posts:
    48
    EveryPlay Upside down on ios.
    I'm saved the video on lcaol.
    This is my code:
    code from:
    http://answers.unity3d.com/questions/1089052/can-i-use-everyplay-to-record-without-upload.html

    Code (CSharp):
    1.  static string GetVideoPath ()
    2.      {
    3.          #if UNITY_IOS
    4.          var root = new DirectoryInfo(Application.persistentDataPath).Parent.FullName;
    5.          var everyplayDir = root + "/tmp/Everyplay/session";
    6.          #elif UNITY_ANDROID
    7.          var root = new DirectoryInfo(Application.temporaryCachePath).FullName;
    8.          var everyplayDir = root + "/sessions";
    9.          #endif
    10.          var files = new DirectoryInfo(everyplayDir).GetFiles("*.mp4", SearchOption.AllDirectories);
    11.          var videoLocation = "";
    12.          // Should only be one video, if there is one at all
    13.          foreach (var file in files) {
    14.              #if UNITY_ANDROID
    15.              videoLocation = "file://" + file.FullName;
    16.              #else
    17.              videoLocation = file.FullName;
    18.              #endif
    19.              break;
    20.          }
    21.          return videoLocation;
    22.      }
    As shown below
     

    Attached Files:

  2. WellC

    WellC

    Joined:
    Mar 2, 2015
    Posts:
    48
    help
     
  3. awardell_triggerglobal

    awardell_triggerglobal

    Joined:
    Apr 27, 2017
    Posts:
    5
    I am having this same issue. WellC, did you ever find a solution?
     
  4. yasirkula

    yasirkula

    Joined:
    Aug 1, 2011
    Posts:
    2,879
    This example code helped me a lot: https://stackoverflow.com/a/18894363

    It asynchronously rotates the video located at videoURL and saves the result to exportPath. In your case, videoURL should be the URL to your local Everyplay video and exportPath should be the desired path of the rotated video output.
     
  5. Seven27

    Seven27

    Joined:
    Mar 10, 2013
    Posts:
    7
    Hi @yasirkula, could you give us more information about how you got this? Thanks
     
  6. yasirkula

    yasirkula

    Joined:
    Aug 1, 2011
    Posts:
    2,879
    I'll be sharing example code soon on my GitHub page. Will also let you know.
     
  7. yasirkula

    yasirkula

    Joined:
    Aug 1, 2011
    Posts:
    2,879
    minhpl and polytropoi like this.