MediaCodec createInputSurface
问题 I want to use MediaCodec to encode a Surface into H.264. With API 18, there is a way to encode content from a surface by calling createInputSurface() and then drawing on that surface. I get IllegalStateException on createInputSurface(). Here's additional logcat output: D/H264Encoder(17570): MediaFormat: {frame-rate=25, bitrate=1000000, height=600, mime=video/avc, color-format=19, i-frame-interval=75, width=800} D/NvOsDebugPrintf( 125): NvMMLiteOpen : Block : BlockType = 4 D/NvOsDebugPrintf(