[ZenFone 2 Original Android Development] krasCGQ:
I think the screen recording isn't working (or more specifically: producing zero-byte file) due to mediaserver crash. I found this on my logcat:

11-20 22:27:36.967 E/pvr_drv_video (26491): CreateContext config_id:16777216, pic_w:1080, pic_h:1920, flag:1, num_render_targets:4, render_targets: 0xe521d300.
11-20 22:27:36.968 I/VideoEncoder(26491): Success to create libva context width 1080, height 1920
11-20 22:27:36.974 I/InputManager-JNI( 707): Setting show touches feature to enabled.
11-20 22:27:36.975 I/InputReader( 707): Reconfiguring input devices. changes=0x00000008
11-20 22:27:36.995 D/componentbase(26491): OMX.Intel.VideoEncoder.AVC:video_encoder.avc: transition from OMX_StateLoaded to OMX_StateIdle completed
11-20 22:27:36.996 D/componentbase(26491): OMX.Intel.VideoEncoder.AVC:video_encoder.avc: transition from OMX_StateIdle to OMX_StateExecuting completed
11-20 22:27:37.018 D/GraphicBufferSource(26491): got buffer with new dataSpace #104
11-20 22:27:37.019 D/ACodec (28629): dataspace changed to 0x10c10000 (R:2(Limited), P:1(BT709_5), M:1(BT709_5), T:3(SMPTE170M)) (R:2(Limited), S:1(BT709), T:3(SMPTE_170M))
11-20 22:27:37.023 W/pvr_drv_video(26491): int gralloc_lock(buffer_handle_t, int, int, int, int, int, void **): gralloc module has not been initialized. Should initialize it first
11-20 22:27:37.024 D/pvr_drv_video(26491): hw_get_module returned
--------- beginning of crash
11-20 22:27:37.028 F/libc (26491): Fatal signal 11 (SIGSEGV), code 1, fault addr 0x0 in tid 28663 (IntelHwCodec)
11-20 22:27:37.028 W/ ( 231): debuggerd: handling request: pid=26491 uid=1013 gid=1005 tid=28663
11-20 22:27:37.069 V/NotificationService( 707): pkg=org.cyanogenmod.screencast canInterrupt=false intercept=true
11-20 22:27:37.075 D/hwcomposer( 269): void android::intel::UeventObserver::onUevent(): received Uevent: REPEATED_FRAME
11-20 22:27:37.075 D/hwcomposer( 269): virtual void android::intel::Hwcomposer::invalidate(): invalidating screen...
11-20 22:27:37.102 F/DEBUG (28664): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
11-20 22:27:37.102 F/DEBUG (28664): CM Version: 'unknown'
11-20 22:27:37.102 F/DEBUG (28664): Build fingerprint: 'asus/WW_Z00A/Z00A:6.0.1/MMB29P/4.21.40.134_20160825_4746_user:user/release-keys'
11-20 22:27:37.102 F/DEBUG (28664): Revision: '0'
11-20 22:27:37.102 F/DEBUG (28664): ABI: 'x86'
11-20 22:27:37.102 F/DEBUG (28664): pid: 26491, tid: 28663, name: IntelHwCodec >>> /system/bin/mediaserver <<<
11-20 22:27:37.102 F/DEBUG (28664): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
11-20 22:27:37.102 F/DEBUG (28664): eax 00000000 ebx e08dfd40 ecx 00000780 edx def83980
11-20 22:27:37.102 F/DEBUG (28664): esi ea518e40 edi 00000438
11-20 22:27:37.102 F/DEBUG (28664): xcs 00000023 xds 0000002b xes 0000002b xfs 00000003 xss 0000002b
11-20 22:27:37.102 F/DEBUG (28664): eip 00000000 ebp dcc6d598 esp dcc6d52c flags 00000286
11-20 22:27:37.102 F/DEBUG (28664):
11-20 22:27:37.102 F/DEBUG (28664): backtrace:
11-20 22:27:37.103 F/DEBUG (28664): #00 pc 00000000 <unknown>
11-20 22:27:37.230 W/NativeCrashListener( 707): Couldn't find ProcessRecord for pid 26491
11-20 22:27:37.233 W/ ( 231): debuggerd: resuming target 26491
11-20 22:27:37.233 I/BootReceiver( 707): Copying /data/tombstones/tombstone_03 to DropBox (SYSTEM_TOMBSTONE)
11-20 22:27:37.260 E/Surface ( 269): dequeueBuffer: IGraphicBufferProducer::requestBuffer failed: -32
11-20 22:27:37.260 E/IMGSRV ( 269): :0: DequeueBufferWrapper: Failed to de-queue buffer (-32)
11-20 22:27:37.260 E/IMGSRV ( 269): :0: KEGLGetDrawableParameters: Native window is invalid
11-20 22:27:37.260 E/IMGSRV ( 269): :0: GLES3MakeCurrentGC: Invalid write drawable - what do we do?
11-20 22:27:37.260 E/IMGSRV ( 269): :0: IMGeglMakeCurrent: unexpected error code
11-20 22:27:37.260 W/MediaMetadataRetriever( 1896): MediaMetadataRetriever server died!
11-20 22:27:37.260 E/libEGL ( 269): eglMakeCurrent:820 error 3003 (EGL_BAD_ALLOC)
11-20 22:27:37.260 W/SurfaceFlinger( 269): DisplayDevice::makeCurrent failed. Aborting surface composition for display hidden:screen-recording
11-20 22:27:37.261 W/MediaCodec(28629): ResourceManagerService died.
11-20 22:27:37.261 E/ACodec (28629): OMX/mediaserver died, signalling error!
11-20 22:27:37.261 E/ACodec (28629): signalError(omxError 0x8000100d, internalError -32)
11-20 22:27:37.262 E/MediaCodec(28629): Codec reported err 0xffffffe0, actionCode 0, while in state 6
11-20 22:27:37.262 I/ServiceManager( 268): service 'media.player' died
11-20 22:27:37.262 I/ServiceManager( 268): service 'media.resource_manager' died
11-20 22:27:37.262 I/ServiceManager( 268): service 'media.camera' died
11-20 22:27:37.266 E/RecordingDevice(28629): Encoder error
11-20 22:27:37.266 E/RecordingDevice(28629): java.lang.IllegalStateException
11-20 22:27:37.266 E/RecordingDevice(28629):	at android.media.MediaCodec.native_dequeueOutputBuffer(Native Method)
11-20 22:27:37.266 E/RecordingDevice(28629):	at android.media.MediaCodec.dequeueOutputBuffer(MediaCodec.java:2570)
11-20 22:27:37.266 E/RecordingDevice(28629):	at org.cyanogenmod.screencast.RecordingDevice$Recorder.encode(RecordingDevice.java:233)
11-20 22:27:37.266 E/RecordingDevice(28629):	at org.cyanogenmod.screencast.EncoderDevice$EncoderRunnable.run(EncoderDevice.java:151)
11-20 22:27:37.266 E/RecordingDevice(28629):	at java.lang.Thread.run(Thread.java:761)
11-20 22:27:37.270 I/DisplayManagerService( 707): Display device removed: DisplayDeviceInfo{"hidden:screen-recording": uniqueId="virtual:org.cyanogenmod.screencast,10021,hidden:screen-recording,0", 1080 x 1920, modeId 3, defaultModeId 3, supportedModes [{id=3, width=1080, height=1920, fps=60.0}], colorMode 0, supportedColorModes [0], HdrCapabilities null, density 1, 1.0 x 1.0 dpi, appVsyncOff 0, presDeadline 16666666, touch NONE, rotation 0, type VIRTUAL, state ON, owner org.cyanogenmod.screencast (uid 10021), FLAG_SECURE}
11-20 22:27:37.270 I/RecordingDevice(28629): =======ENCODING COMPLETE=======