title: How to Record Video from Background Service using Camera2 API?
body: <p>I am trying to record video from a Background Service without showing any preview. It is like <a href="https://stackoverflow.com/questions/10121660/how-to-record-video-from-background-of-application-android">this example</a> but trying to do it with Camera2 API.</p>
  
  <p>I am trying to follow along with the <a href="https://github.com/googlesamples/android-Camera2Video" rel="noreferrer">android-Camera2Video sample code</a> and trying to use that in the service. </p>
  
  <p>Which parts should I cut out / ignore - is it the part <code>TexttureViewer</code> part where it is previewed? I dont want to preview anything I just want to record it.</p>