title: How To Save TextureView As Video File or Mp4 file?
body: <p>i have successful load my video textured on texture view. and successfully played that frames on texttureview now i am looking for record that textureview. i dont know how to record it as video file. i searched on web and i found only one refrence link that talked about grafika video player but i failed to record video using grafika can any one help me in thi topic.</p>
  
  <p>i tried </p>
  
  <p><a href="https://stackoverflow.com/a/42538679/12589339">https://stackoverflow.com/a/42538679/12589339</a></p>
  
  <p>i got this error</p>
  
  <pre><code>2019-12-24 15:02:40.675 22942-24463/com.example.texture E/TextureRender: glCreateShader type=35633: glError 1281
  2019-12-24 15:02:40.722 22942-24463/com.example.texture W/MediaAnalyticsItem: Unable to record: (codec:0:-1:-11:0:7:android.media.mediacodec.codec=OMX.qcom.video.encoder.avc:android.media.mediacodec.mode=video:android.media.mediacodec.secure=0:android.media.mediacodec.width=394:android.media.mediacodec.height=702:android.media.mediacodec.rotation-degrees=0:android.media.mediacodec.mime=video/avc:) [forcenew=0]
  2019-12-24 15:02:40.768 22942-24461/com.example.texture W/System.err: java.lang.RuntimeException: glCreateShader type=35633: glError 1281
  2019-12-24 15:02:40.770 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.TextureRender.checkGlError(TextureRender.java:219)
  2019-12-24 15:02:40.770 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.TextureRender.loadShader(TextureRender.java:170)
  2019-12-24 15:02:40.770 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.TextureRender.createProgram(TextureRender.java:185)
  2019-12-24 15:02:40.770 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.TextureRender.surfaceCreated(TextureRender.java:111)
  2019-12-24 15:02:40.771 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.OutputSurfaceNew.setup(OutputSurfaceNew.java:106)
  2019-12-24 15:02:40.771 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.OutputSurfaceNew.&lt;init&gt;(OutputSurfaceNew.java:97)
  2019-12-24 15:02:40.771 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.ExtractDecodeEditEncodeMuxTest.extractDecodeEditEncodeMux(ExtractDecodeEditEncodeMuxTest.java:369)
  2019-12-24 15:02:40.771 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.ExtractDecodeEditEncodeMuxTest.access$000(ExtractDecodeEditEncodeMuxTest.java:55)
  2019-12-24 15:02:40.771 22942-24461/com.example.texture W/System.err:     at com.example.texture.recording.ExtractDecodeEditEncodeMuxTest$TestWrapper.run(ExtractDecodeEditEncodeMuxTest.java:205)
  2019-12-24 15:02:40.771 22942-24461/com.example.texture W/System.err:     at java.lang.Thread.run(Thread.java:764)
  2019-12-24 15:02:40.789 22942-23097/com.example.texture W/Adreno-ES20: &lt;core_glFinish:34&gt;: glFinish skipped: 0
  2019-12-24 15:02:40.791 22942-23097/com.example.texture W/Adreno-ES20: &lt;core_glFinish:34&gt;: glFinish skipped: 0
  </code></pre>