How to record a view's activity in iOS swift? -


i trying record view i.e ever activity going on view want record , save .mp4 . have how managed record view , saved recorded video .mp4 camera roll well.i can see animation on real device when run project.

but happening animation happening on imageview not getting record i.e animating set of images on imageview i.e sub view of view (contentview) want record.

for recording view using iascreencaptureview library. , code doing follow :

@iboutlet var contentview: iascreencaptureview! @iboutlet var mainimageview: uiimageview! @iboutlet var animateimageview: uiimageview!   let myimgarr = ["beauty_01","beauty_02","beauty_03","beauty_04","beauty_05","beauty_06","beauty_07","beauty_08","beauty_09","beauty_10","beauty_11","beauty_12","beauty_13","beauty_14","beauty_15","beauty_16","beauty_17","beauty_18","beauty_19","beauty_20","beauty_21","beauty_22","beauty_23","beauty_24","beauty_25","beauty_26","beauty_27","beauty_28","beauty_29","beauty_30"]   override func viewdidload() {         super.viewdidload()          animate_images()      }   func animate_images()      {         var images = [uiimage]()          in 0..<myimgarr.count         {             images.append(uiimage(named: myimgarr[i])!)         }          animateimageview.animationimages = images         animateimageview.animationduration = 2.0         animateimageview.startanimating()         contentview.addsubview(animateimageview)      }  var t = false     @ibaction func donebuttonaction(_ sender: uibutton) {          if t {              print("stopped")             contentview.stoprecording()          }else {              print("started")             contentview.startrecording()         }          t = !t      } 

hope able convey self. in advance highly appreciated.


Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -