summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gstreamer_ti/Makefile.common17
-rw-r--r--gstreamer_ti/gstreamer_demo/dm368/loadmodules.sh5
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/Makefile.external14
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/src/gsttiauddec1.c2
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/src/gstticodecplugin_dm368.cfg104
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/src/gstticodecs_dm368.c106
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/src/gsttidmaivideosink.c23
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/src/gsttiprepencbuf.c6
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/src/gsttividdec2.c9
-rw-r--r--gstreamer_ti/ti_build/ticodecplugin/src/gsttividenc1.c14
10 files changed, 286 insertions, 14 deletions
diff --git a/gstreamer_ti/Makefile.common b/gstreamer_ti/Makefile.common
index ca29bc9..82331ff 100644
--- a/gstreamer_ti/Makefile.common
+++ b/gstreamer_ti/Makefile.common
@@ -128,6 +128,9 @@ ifndef CROSS_COMPILER
ifeq ($(GST_TI_PLATFORM), dm365)
CROSS_COMPILER=CS_2009Q1
endif
+ ifeq ($(GST_TI_PLATFORM), dm368)
+ CROSS_COMPILER=CS_2009Q1
+ endif
ifeq ($(GST_TI_PLATFORM), omap3530)
CROSS_COMPILER=CS_2008Q1
endif
@@ -183,6 +186,16 @@ ifeq ($(GST_TI_PLATFORM), dm365)
export LIBTOOL_SYSROOT_PATH = $(LINUXLIBS_INSTALL_DIR)/..
endif
+ifeq ($(GST_TI_PLATFORM), dm368)
+ export XDC_TARGET = gnu.targets.arm.GCArmv5T
+ export XDC_PLATFORM = ti.platforms.evmDM365
+ export MVTOOL_PREFIX = $(CSTOOL_PREFIX)
+ export MVTOOL_DIR = $(CSTOOL_DIR)
+ export PLATFORM_XDC = ${XDC_PLATFORM}
+ export CROSS_COMPILE = ${CSTOOL_PREFIX}
+ export LIBTOOL_SYSROOT_PATH = $(LINUXLIBS_INSTALL_DIR)/..
+endif
+
ifeq ($(GST_TI_PLATFORM), dm6467)
export XDC_TARGET = gnu.targets.MVArm9
export XDC_PLATFORM = ti.platforms.evmDM6467
@@ -272,6 +285,8 @@ CPPFLAGS_dm6467 += -I$(LINUXKERNEL_INSTALL_DIR)/include
CPPFLAGS_dm355 = -I$(LINUXLIBS_INSTALL_DIR)/include
CPPFLAGS_dm365 = -I$(LINUXLIBS_INSTALL_DIR)/include
CPPFLAGS_dm365 += -I$(LINUXKERNEL_INSTALL_DIR)/include
+CPPFLAGS_dm368 = -I$(LINUXLIBS_INSTALL_DIR)/include
+CPPFLAGS_dm368 += -I$(LINUXKERNEL_INSTALL_DIR)/include
CPPFLAGS_dm6467t = -I$(LINUXLIBS_INSTALL_DIR)/include
CPPFLAGS_omap3530 = -I$(LINUXLIBS_INSTALL_DIR)/include
CPPFLAGS_dm3730 = -I$(LINUXLIBS_INSTALL_DIR)/include
@@ -281,6 +296,7 @@ CFLAGS_all = -O2
CFLAGS_dm355 = -march=armv5te -mtune=arm926ej-s
CFLAGS_dm6446 = -march=armv5te -mtune=arm926ej-s
CFLAGS_dm365 = -march=armv5te -mtune=arm926ej-s
+CFLAGS_dm368 = -march=armv5te -mtune=arm926ej-s
CFLAGS_dm6467 = -march=armv5te -mtune=arm926ej-s
CFLAGS_dm6467t = -march=armv5te -mtune=arm926ej-s
CFLAGS_omapl138 = -march=armv5te -mtune=arm926ej-s
@@ -292,6 +308,7 @@ CFLAGS_dm3730 += -mfpu=neon -mfloat-abi=softfp
LDFLAGS_all = -L$(TARGET_GSTREAMER_DIR)/lib
LDFLAGS_dm355 = -L$(LINUXLIBS_INSTALL_DIR)/lib
LDFLAGS_dm365 = -L$(LINUXLIBS_INSTALL_DIR)/lib
+LDFLAGS_dm368 = -L$(LINUXLIBS_INSTALL_DIR)/lib
LDFLAGS_dm6467t = -L$(LINUXLIBS_INSTALL_DIR)/lib
LDFLAGS_omap3530 = -L$(LINUXLIBS_INSTALL_DIR)/lib
LDFLAGS_dm3730 = -L$(LINUXLIBS_INSTALL_DIR)/lib
diff --git a/gstreamer_ti/gstreamer_demo/dm368/loadmodules.sh b/gstreamer_ti/gstreamer_demo/dm368/loadmodules.sh
new file mode 100644
index 0000000..1d061d5
--- /dev/null
+++ b/gstreamer_ti/gstreamer_demo/dm368/loadmodules.sh
@@ -0,0 +1,5 @@
+#!/bin/sh
+# Run DVSDK loadmodule script to install kernel modules
+
+/etc/init.d/loadmodules-rc restart
+
diff --git a/gstreamer_ti/ti_build/ticodecplugin/Makefile.external b/gstreamer_ti/ti_build/ticodecplugin/Makefile.external
index d070ef2..b75e056 100644
--- a/gstreamer_ti/ti_build/ticodecplugin/Makefile.external
+++ b/gstreamer_ti/ti_build/ticodecplugin/Makefile.external
@@ -8,7 +8,7 @@
# Copyright (C) 2009 Ridgerun
#
-.PHONY: default configure dm6446 omap3530 dm355 dm6467 dm365 omapl138 dm3730
+.PHONY: default configure dm6446 omap3530 dm355 dm6467 dm365 omapl138 dm3730 dm368
DVSDK_PATH=undefined
DMAI_INSTALL_DIR=undefined
@@ -80,6 +80,15 @@ ifeq ($(GST_TI_PLATFORM), dm365)
export CROSS_COMPILE = ${CSTOOL_PREFIX}
endif
+ifeq ($(GST_TI_PLATFORM), dm368)
+ export XDC_TARGET = gnu.targets.arm.GCArmv5T
+ export XDC_PLATFORM = ti.platforms.evmDM365
+ export MVTOOL_PREFIX = $(CSTOOL_PREFIX)
+ export MVTOOL_DIR = $(CSTOOL_DIR)
+ export PLATFORM_XDC = ${XDC_PLATFORM}
+ export CROSS_COMPILE = ${CSTOOL_PREFIX}
+endif
+
ifeq ($(GST_TI_PLATFORM), omapl138)
export XDC_TARGET = gnu.targets.arm.GCArmv5T
export XDC_PLATFORM = ti.platforms.evmOMAPL138
@@ -151,3 +160,6 @@ omapl138: Makefile
dm3730: Makefile
$(MAKE) -f Makefile
+
+dm368: Makefile
+ $(MAKE) -f Makefile
diff --git a/gstreamer_ti/ti_build/ticodecplugin/src/gsttiauddec1.c b/gstreamer_ti/ti_build/ticodecplugin/src/gsttiauddec1.c
index 117a0b7..6a5dbbe 100644
--- a/gstreamer_ti/ti_build/ticodecplugin/src/gsttiauddec1.c
+++ b/gstreamer_ti/ti_build/ticodecplugin/src/gsttiauddec1.c
@@ -1104,7 +1104,7 @@ static gboolean gst_tiauddec1_codec_start (GstTIAuddec1 *auddec1)
}
if (gst_tiauddec1_codec_is_aac(auddec1)) {
- #if defined (Platform_dm365)
+ #if defined (Platform_dm365) || defined(Platform_dm368)
params.dataEndianness = XDM_LE_16;
#else
; /* do nothing */
diff --git a/gstreamer_ti/ti_build/ticodecplugin/src/gstticodecplugin_dm368.cfg b/gstreamer_ti/ti_build/ticodecplugin/src/gstticodecplugin_dm368.cfg
new file mode 100644
index 0000000..1256344
--- /dev/null
+++ b/gstreamer_ti/ti_build/ticodecplugin/src/gstticodecplugin_dm368.cfg
@@ -0,0 +1,104 @@
+/* ============================================================================
+ * Copyright (c) Texas Instruments Incorporated 2009
+ *
+ * Use of this software is controlled by the terms and conditions found in the
+ * license agreement under which this software has been supplied or provided.
+ * ============================================================================
+ */
+
+/* Load support for the Codec Engine OSAL */
+var osalGlobal = xdc.useModule('ti.sdo.ce.osal.Global');
+
+/* Configure CE to use it's DSP Link Linux version */
+osalGlobal.runtimeEnv = osalGlobal.LINUX;
+
+/*
+ * ======== Engine Configuration ========
+ */
+var CE_AUDIO1 = xdc.loadPackage("ti.sdo.ce.audio1");
+var CE_VIDEO2 = xdc.loadPackage("ti.sdo.ce.video2");
+
+var MPEG4DEC = xdc.useModule('ti.sdo.codecs.mpeg4dec_hdvicp.ce.MPEG4DEC_HDVICP');
+var MPEG2DEC = xdc.useModule('ti.sdo.codecs.mpeg2dec.ce.MPEG2DEC');
+var H264DEC = xdc.useModule('ti.sdo.codecs.h264dec.ce.H264DEC');
+var AACDEC = xdc.useModule('ittiam.codecs.aac_dec.ce.AAC_DEC');
+var JPEGDEC = xdc.useModule('ti.sdo.codecs.jpegdec.ce.JPEGDEC');
+var MPEG4ENC = xdc.useModule('ti.sdo.codecs.mpeg4enc_hdvicp.ce.MPEG4ENC_HDVICP');
+var MPEG2ENC = xdc.useModule('ti.sdo.codecs.mpeg2enc.ce.MPEG2ENC');
+var H264ENC = xdc.useModule('ti.sdo.codecs.h264enc.ce.H264ENC');
+var AACLCENC = xdc.useModule('ittiam.codecs.aaclc_enc.ce.AACLC_ENC');
+var JPEGENC = xdc.useModule('ti.sdo.codecs.jpegenc.ce.JPEGENC');
+
+var Engine = xdc.useModule('ti.sdo.ce.Engine');
+var myEngine = Engine.create("codecServer", [
+ {name: "mpeg4dec", mod: MPEG4DEC, local: true},
+ {name: "mpeg2dec", mod: MPEG2DEC, local: true},
+ {name: "h264dec", mod: H264DEC, local: true},
+ {name: "aacdec", mod: AACDEC, local: true, groupId: 1},
+ {name: "jpegdec", mod: JPEGDEC, local: true, groupId: 1},
+ {name: "mpeg4enc", mod: MPEG4ENC, local: true},
+ {name: "mpeg2enc", mod: MPEG2ENC, local: true},
+ {name: "h264enc", mod: H264ENC, local: true},
+ {name: "aaclcenc", mod: AACLCENC, local: true, groupId: 1},
+ {name: "jpegenc", mod: JPEGENC, local: true, groupId: 1}
+]);
+
+/* Disable caching for all codecs except AAC */
+algSettings = xdc.useModule('ti.sdo.ce.alg.Settings');
+algSettings.useCache = false;
+AACDEC.useCache = true;
+AACLCENC.useCache = true;
+
+/* Load support for the 'Davinci Multimedia Application Interface' modules */
+var DMAI = xdc.loadPackage('ti.sdo.dmai');
+
+/* Configure RMAN */
+var RMAN = xdc.useModule('ti.sdo.fc.rman.RMAN');
+RMAN.useDSKT2 = false;
+RMAN.persistentAllocFxn = "__ALG_allocMemory";
+RMAN.persistentFreeFxn = "__ALG_freeMemory";
+RMAN.semCreateFxn = "Sem_create";
+RMAN.semDeleteFxn = "Sem_delete";
+RMAN.semPendFxn = "Sem_pend";
+RMAN.semPostFxn = "Sem_post";
+RMAN.tableSize = 10;
+
+/* Configure VICPSYNC */
+var VICPSYNC = xdc.useModule('ti.sdo.fc.vicpsync.VICPSYNC');
+
+/* Configure HDVICPSYNC */
+var HDVICPSYNC = xdc.useModule('ti.sdo.fc.hdvicpsync.HDVICPSYNC');
+
+/* Configure MEMUTILS */
+var MEMUTILS = xdc.useModule('ti.sdo.fc.memutils.MEMUTILS');
+
+var EDMA3 = xdc.useModule('ti.sdo.fc.edma3.Settings');
+
+var HDVICP = xdc.useModule('ti.sdo.fc.ires.hdvicp.HDVICP');
+
+var VICP = xdc.useModule('ti.sdo.fc.ires.vicp.VICP2');
+
+var EDMA3CHAN = xdc.useModule('ti.sdo.fc.ires.edma3chan.EDMA3CHAN');
+
+var EDMA = xdc.useModule('ti.sdo.linuxutils.edma.EDMA');
+
+var ADDRSPACE = xdc.useModule('ti.sdo.fc.ires.addrspace.ADDRSPACE');
+
+var CMEM = xdc.useModule('ti.sdo.linuxutils.cmem.CMEM');
+
+/* Set the cmemBlockId for the ARM926 TCM memory used by the platinum codec.
+ * In our insmod for cmem, the TCM memory was specified using phys_start_1,
+ * where the "_1" represents the block ID.
+ */
+var MEMTCM = xdc.useModule('ti.sdo.fc.ires.memtcm.MEMTCM');
+MEMTCM.cmemBlockId = 1;
+
+/* Uncomment these lines if you wish to debug FC and enable FC trace */
+/*
+xdc.loadPackage('ti.sdo.fc.ires.vicp').profile = "debug_trace";
+xdc.loadPackage('ti.sdo.fc.ires.edma3chan').profile = "debug_trace";
+xdc.loadPackage('ti.sdo.fc.rman').profile = "debug_trace";
+xdc.loadPackage('ti.sdo.fc.edma3').profile = "debug_trace";
+EDMA3CHAN.trace = true;
+EDMA3CHAN.debug = true;
+*/
diff --git a/gstreamer_ti/ti_build/ticodecplugin/src/gstticodecs_dm368.c b/gstreamer_ti/ti_build/ticodecplugin/src/gstticodecs_dm368.c
new file mode 100644
index 0000000..85db865
--- /dev/null
+++ b/gstreamer_ti/ti_build/ticodecplugin/src/gstticodecs_dm368.c
@@ -0,0 +1,106 @@
+/*
+ * gstticodecs_dm365.c
+ *
+ * This file provides information for available codecs on the DM365 platform.
+ *
+ * Original Author:
+ * Sajesh Kumar Saran, Texas Instruments, Inc.
+ *
+ * Copyright (C) 2008-2010 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation version 2.1 of the License.
+ *
+ * This program is distributed #as is# WITHOUT ANY WARRANTY of any kind,
+ * whether express or implied; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ */
+
+#include "gstticodecs.h"
+
+/* Declaration of the production engine and decoders shipped with the DVSDK */
+static Char codecServer[] = "codecServer";
+
+/* NULL terminated list of speech decoders in the engine to use in the demo */
+GstTICodec gst_ticodec_codecs[] = {
+
+ /* Video Codecs */
+ {
+ "MPEG4 Video Decoder", /* String name of codec used by plugin */
+ "mpeg4dec", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+ {
+ "MPEG2 Video Decoder", /* String name of codec used by plugin */
+ "mpeg2dec", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+ {
+ "MPEG4 Video Encoder", /* String name of codec used by plugin */
+ "mpeg4enc", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+ {
+ "MPEG2 Video Encoder", /* String name of codec used by plugin */
+ "mpeg2enc", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+ {
+ "H.264 Video Decoder", /* String name of codec used by plugin */
+ "h264dec", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+ {
+ "H.264 Video Encoder", /* String name of codec used by plugin */
+ "h264enc", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+
+ /* Audio Codecs */
+ {
+ "AAC Audio Decoder", /* String name of codec used by plugin */
+ "aacdec", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+ {
+ "AAC Audio Encoder", /* String name of codec used by plugin */
+ "aaclcenc", /* String name of codec used by CE */
+ codecServer /* Engine that contains this codec */
+ },
+
+ /* Imaging Codecs */
+ {
+ "JPEG Image Encoder",
+ "jpegenc",
+ codecServer
+ },
+
+ {
+ "JPEG Image Decoder",
+ "jpegdec",
+ codecServer
+ },
+
+ { NULL }
+};
+
+
+/******************************************************************************
+ * Custom ViM Settings for editing this file
+ ******************************************************************************/
+#if 0
+ Tabs (use 4 spaces for indentation)
+ vim:set tabstop=4: /* Use 4 spaces for tabs */
+ vim:set shiftwidth=4: /* Use 4 spaces for >> operations */
+ vim:set expandtab: /* Expand tabs into white spaces */
+#endif
diff --git a/gstreamer_ti/ti_build/ticodecplugin/src/gsttidmaivideosink.c b/gstreamer_ti/ti_build/ticodecplugin/src/gsttidmaivideosink.c
index d64760f..ec86214 100644
--- a/gstreamer_ti/ti_build/ticodecplugin/src/gsttidmaivideosink.c
+++ b/gstreamer_ti/ti_build/ticodecplugin/src/gsttidmaivideosink.c
@@ -361,7 +361,7 @@ static void gst_tidmaivideosink_class_init(GstTIDmaiVideoSinkClass * klass)
/* Pad-buffer allocation is currently supported on DM365, OMAP3530 and DM3730 */
#if !defined(Platform_dm365) && !defined(Platform_omap3530) && \
- !defined(Platform_dm3730)
+ !defined(Platform_dm3730) && !defined(Platform_dm368)
gstbase_sink_class->buffer_alloc = NULL;
#endif
}
@@ -483,7 +483,7 @@ static void gst_tidmaivideosink_init(GstTIDmaiVideoSink * dmaisink,
gst_value_set_fraction(&dmaisink->oattrs.framerate, 0, 1);
/* DM365 supports setting the display framerate */
- #if defined(Platform_dm365)
+ #if defined(Platform_dm365) || defined(Platform_dm368)
dmaisink->can_set_display_framerate = TRUE;
#endif
@@ -1188,6 +1188,12 @@ static gboolean gst_tidmaivideosink_set_display_attrs(GstTIDmaiVideoSink *sink,
sink->dAttrs.colorSpace = colorSpace;
break;
#endif
+ #if defined(Platform_dm368)
+ case Cpu_Device_DM368:
+ sink->dAttrs = Display_Attrs_DM365_VID_DEFAULT;
+ sink->dAttrs.colorSpace = colorSpace;
+ break;
+ #endif
default:
sink->dAttrs = Display_Attrs_DM6446_DM355_VID_DEFAULT;
break;
@@ -1217,7 +1223,7 @@ static gboolean gst_tidmaivideosink_set_display_attrs(GstTIDmaiVideoSink *sink,
/* Specify framerate if supported by DMAI and the display driver */
if (sink->can_set_display_framerate) {
- #if defined (Platform_dm365)
+ #if defined (Platform_dm365) || defined(Platform_dm368)
sink->dAttrs.forceFrameRateNum =
gst_value_get_fraction_numerator(&sink->iattrs.framerate);
sink->dAttrs.forceFrameRateDen =
@@ -1403,8 +1409,9 @@ static gboolean gst_tidmaivideosink_init_display(GstTIDmaiVideoSink * sink)
*/
if (sink->hDispBufTab) {
#if defined(Platform_dm365) || defined(Platform_omap3530) || \
- defined(Platform_dm3730)
+ defined(Platform_dm3730) || defined(Platform_dm368)
sink->dAttrs.delayStreamon = TRUE;
+ printf("delay stream on ....\n");
#else
GST_ERROR("delayed V4L2 streamon not supported\n");
return FALSE;
@@ -1611,7 +1618,7 @@ static GstFlowReturn gst_tidmaivideosink_render(GstBaseSink * bsink,
}
inBuf = sink->tempDmaiBuf;
- #if defined(Platform_dm365)
+ #if defined(Platform_dm365) || defined(Platform_dm368)
/* DM365: TO componsate resizer 32-byte alignment, we need to set
* lineLength to roundup on 32-byte boundry.
*/
@@ -1963,7 +1970,7 @@ static gboolean gst_tidmaivideosink_alloc_display_buffers(
* For other platforms, unfortunately there is no default set and we need
* to specify one.
*/
- #if defined(Platform_dm365)
+ #if defined(Platform_dm365) || defined(Platform_dm368)
gfxAttrs.colorSpace = sink->dAttrs.colorSpace;
#elif defined(Platform_dm6467) || defined(Platform_dm6467t)
gfxAttrs.colorSpace = ColorSpace_YUV422PSEMI;
@@ -1976,7 +1983,7 @@ static gboolean gst_tidmaivideosink_alloc_display_buffers(
BufferGfx_calcLineLength(gfxAttrs.dim.width, gfxAttrs.colorSpace);
/* On DM365 the display pitch must be aligned to a 32-byte boundary */
- #if defined(Platform_dm365)
+ #if defined(Platform_dm365) || defined(Platform_dm368)
gfxAttrs.dim.lineLength = Dmai_roundUp(gfxAttrs.dim.lineLength, 32);
#endif
@@ -2004,7 +2011,7 @@ static gboolean gst_tidmaivideosink_open_osd(GstTIDmaiVideoSink * sink)
Display_Attrs aAttrs = {0};
Buffer_Handle hBuf;
- #if defined(Platform_dm365)
+ #if defined(Platform_dm365) || defined(Platform_dm368)
oAttrs = Display_Attrs_DM365_OSD_DEFAULT;
aAttrs = Display_Attrs_DM365_ATTR_DEFAULT;
#elif defined(Platform_dm6446) || defined(Platform_dm355)
diff --git a/gstreamer_ti/ti_build/ticodecplugin/src/gsttiprepencbuf.c b/gstreamer_ti/ti_build/ticodecplugin/src/gsttiprepencbuf.c
index 20a223b..a3bf2cb 100644
--- a/gstreamer_ti/ti_build/ticodecplugin/src/gsttiprepencbuf.c
+++ b/gstreamer_ti/ti_build/ticodecplugin/src/gsttiprepencbuf.c
@@ -465,7 +465,7 @@ gst_tiprepencbuf_copy_input(GstTIPrepEncBuf * prepencbuf,
Buffer_Handle hInBuf = NULL;
Int ret = -1;
-#if defined(Platform_dm365)
+#if defined(Platform_dm365) || defined(Platform_dm368)
BufferGfx_Dimensions dim;
#endif
@@ -510,9 +510,9 @@ gst_tiprepencbuf_copy_input(GstTIPrepEncBuf * prepencbuf,
goto exit;
}
-#if defined(Platform_dm365)
+#if defined(Platform_dm365) || defined(Platform_dm368)
/* Handle resizer 32-byte issue on DM365 platform */
- if (prepencbuf->device == Cpu_Device_DM365) {
+ if (prepencbuf->device == Cpu_Device_DM365 || prepencbuf->device == Cpu_Device_DM368) {
if ((prepencbuf->srcColorSpace == ColorSpace_YUV420PSEMI)) {
BufferGfx_getDimensions(hInBuf, &dim);
dim.lineLength = Dmai_roundUp(dim.lineLength, 32);
diff --git a/gstreamer_ti/ti_build/ticodecplugin/src/gsttividdec2.c b/gstreamer_ti/ti_build/ticodecplugin/src/gsttividdec2.c
index 47481ca..cc5ae6e 100644
--- a/gstreamer_ti/ti_build/ticodecplugin/src/gsttividdec2.c
+++ b/gstreamer_ti/ti_build/ticodecplugin/src/gsttividdec2.c
@@ -1333,6 +1333,15 @@ static gboolean gst_tividdec2_codec_start (GstTIViddec2 *viddec2,
defaultNumBufs = 4;
break;
#endif
+ #if defined(Platform_dm368)
+ case Cpu_Device_DM368:
+ params.forceChromaFormat = XDM_YUV_420SP;
+ params.maxWidth = VideoStd_720P_WIDTH;
+ params.maxHeight = VideoStd_720P_HEIGHT;
+ colorSpace = ColorSpace_YUV420PSEMI;
+ defaultNumBufs = 4;
+ break;
+ #endif
#if defined(Platform_omapl138)
case Cpu_Device_OMAPL138:
params.forceChromaFormat = XDM_YUV_420P;
diff --git a/gstreamer_ti/ti_build/ticodecplugin/src/gsttividenc1.c b/gstreamer_ti/ti_build/ticodecplugin/src/gsttividenc1.c
index 780224c..8bf1105 100644
--- a/gstreamer_ti/ti_build/ticodecplugin/src/gsttividenc1.c
+++ b/gstreamer_ti/ti_build/ticodecplugin/src/gsttividenc1.c
@@ -987,7 +987,7 @@ static gboolean gst_tividenc1_init_video(GstTIVidenc1 *videnc1)
videnc1->frameDuration = gst_tividenc1_frame_duration(videnc1);
/* Determine if we can pass input buffer directly to codec */
- #if defined(Platform_dm365) || defined(Platform_dm355)
+ #if defined(Platform_dm365) || defined(Platform_dm355) || defined(Platform_dm368)
if (videnc1->contiguousInputFrame) {
videnc1->zeroCopyEncode = TRUE;
}
@@ -1201,6 +1201,18 @@ static gboolean gst_tividenc1_codec_start (GstTIVidenc1 *videnc1)
break;
#endif
+ #if defined(Platform_dm368)
+ case Cpu_Device_DM368:
+ if (videnc1->colorSpace == ColorSpace_UYVY) {
+ params.inputChromaFormat = XDM_YUV_422ILE;
+ }
+ else {
+ params.inputChromaFormat = XDM_YUV_420SP;
+ params.reconChromaFormat = XDM_YUV_420SP;
+ }
+ break;
+ #endif
+
default:
GST_ELEMENT_ERROR(videnc1, RESOURCE, FAILED,
("unsupport cpu type\n"), (NULL));