[Android Q&A, Help & Troubleshooting] MrObvious:
So I need a little help in compiling CM 12.1 for the G Stylo. I'm hoping someone smart enough here may have a clue. We have a 90% complete ROM, but video recording is the only thing we can't seem to figure out how to get working. Here's the output from logcat:

E/ACodec ( 307): [OMX.qcom.video.encoder.avc] storeMetaDataInBuffers (output) failed w/ err -1010

W/ACodec ( 307): do not know color format 0x7fa30c04 = 2141391876

W/ACodec ( 307): do not know color format 0x7f000789 = 2130708361

E/ACodec ( 307): [OMX.qcom.video.encoder.avc] does not support color format 39

E/ACodec ( 307): [OMX.qcom.video.encoder.avc] configureCodec returning error -2147483648

E/ACodec ( 307): [OMX.qcom.video.encoder.avc] configureCodec returning error -2147483648

E/ACodec ( 307): signalError(omxError 0x80001001, internalError -2147483648)

E/MediaCodec( 307): Codec reported err 0x80001001, actionCode 0, while in state 3

E/MediaCodec( 307): configure failed with err 0x80001001, resetting...

I/OMX-VENC( 307): Component Deinit

I/OMX-VENC( 307): Component_init : OMX.qcom.video.encoder.avc : return = 0x0

I/OMX-VENC( 307): Component Deinit

E/StagefrightRecorder( 307): Failed to create video encoder

D/CameraSource( 307): reset: E

W/CameraClient( 307): attempt to use a locked camera from a different process (old pid 307, new pid 32037)

E/QCameraStateMachine( 307): stateMachine : m_state [2], evt [16]

D/CameraSource( 307): reset: X

E/MediaRecorder(32037): start failed: -2147483648

E/CAM_VideoModule(32037): Could not start media recorder.

E/CAM_VideoModule(32037): java.lang.RuntimeException: start failed.

E/CAM_VideoModule(32037): at android.media.MediaRecorder.start(Native Method)

E/CAM_VideoModule(32037): at com.android.camera.VideoModule$11.onStorageUpdateD one(VideoModule.java:1388)

E/CAM_VideoModule(32037): at com.android.camera.CameraActivity$18.onPostExecute (CameraActivity.java:2164)

I did some Googling and the missing codec formats may be:

W/ACodec ( 307): do not know color format 0x7fa30c04 = 2141391876

http://alumnus.caltech.edu/~heirich/styled-6/index.html

COLOR_QCOM_FormatYUV420SemiPlanar32m

W/ACodec ( 307): do not know color format 0x7f000789 = 2130708361

https://lists.freedesktop.org/archives/gstreamer-devel/2013-October/043721.html

OMX_COLOR_FormatAndroidOpaque

I'm thinking of adding to frameworks\av\media\libstagefreight\CameraSource.c pp a couple lines for the two above:

if (!strcmp(colorFormat, CameraParameters::PIXEL_FORMAT_YUV420SP_NV21)) {

static const int OMX_SEC_COLOR_FormatNV21Linear = 0x7F000011;

return OMX_SEC_COLOR_FormatNV21Linear;

}

I would also need to modify CameraParameters.h and CameraParameters.cpp like https://github.com/TeamRegular/andro...85287ff60fb487 had done.

Does that sound right?

Here's the custom repos I'm using for the device, kernel, and vendor binaries for reference.

<?xml version="1.0" encoding="UTF-8"?>

<manifest>

<project name="Cyanogenmod/android_external_mm-dash" path="external/mm-dash" revision="cm-12.1" />

<project name="Cyanogenmod/android_device_qcom_common" path="device/qcom/common" revision="cm-12.1" />

<project name="TeamRegular/android_kernel_lge_msm8916" path="kernel/lge/msm8916" revision="cm-12.1-lg" />

<project name="TeamRegular/android_device_lge_msm8916-common" path="device/lge/msm8916-common" revision="cm-12.1" />

<project name="TeamRegular/android_device_lge_g4stylus-common" path="device/lge/g4stylus-common" revision="cm-12.1" />

<project name="TeamRegular/android_device_lge_h631" path="device/lge/h631" revision="cm-12.1" />

<project name="TeamRegular/vendor_lge" path="vendor/lge" revision="cm-12.1" />

</manifest>