DJI Mobile SDK Documentation

      class Callback

      @Deprecated
      interface Callback
      Package:dji.sdk.media
      Description:

      Tells that a new media file (photo or video) is generated.
      Note:Because the firmware cannot return some information correctly, so the interface is deprecated, please use NewFileInfoCallback insteaded.

      Class Members:

      Callback Method

      State
      method
      method onNewFile
      @Deprecated
      void onNewFile(@NonNull MediaFile mediaFile)
      Package:dji.sdk.media
      Description:

      Called when a new media file (photo or video) has been generated.
      In this callback method, the MediaFile instance properties getDurationInSeconds and getVideoOrientation require special consideration. The thumbnail property normally has a pointer to a UIImage of the thumbnail, but this is only available when the camera is in MEDIA_DOWNLOAD work mode. Additionally, for this instance of MediaFile, the getDurationInSeconds property is 0 and the getVideoOrientation property is LANDSCAPE. Not supported by Zenmuse Z30 and Zenmuse XT2.
      Note:Because the firmware cannot return some information correctly, so the interface is deprecated, please use onNewFileInfo insteaded.

      Input Parameters:
      @NonNull MediaFile mediaFileThe new media file.