Remove unnecessary log in sink callback.
Also remove unused function and add mem-free in _cleanup function.
Change-Id: I1d1e9a3c2927f4d3a4f77bd6d68bbd80b6a67e1e
Signed-off-by: Jaeyun Jung <jy1210.jung@samsung.com>
(cherry picked from commit
c953cea20fd6f2b3ec1e902ec276dc57cec5a8e7)
g_main_loop_quit(pMainLoop);
}
- FPRINTF("[Line : %d][%s] Callback Timeout\\n", __LINE__, API_NAMESPACE);
return false;
}
pszNnpipeline = g_strdup ("appsrc name=srcx ! other/tensor,dimension=(string)4:1:1:1,type=(string)uint8,framerate=(fraction)0/1 ! tensor_sink");
- g_unsinkCount = (guint *) g_malloc (sizeof (guint));
- *g_unsinkCount = 0;
-
- g_pipePipeLineState = (TestPipeState *) g_new0 (TestPipeState, 1);
nRet = ml_pipeline_construct (pszNnpipeline, NULL, NULL, &g_hPipelinehandle);
if(!g_bFeatureIsSupported)
{
}
g_hPipelinehandle = NULL;
}
- g_free (g_pipePipeLineState);
g_free (pszNnpipeline);
}
//
#include "ITs-nnstreamer-common.h"
-/**
- * @function MlPipelineSinkCallback
- * @description A tensor-sink callback for sink handle in a pipeline
- */
-static void MlPipelineSinkCallback(const ml_tensors_data_h data, const ml_tensors_info_h info, void *user_data)
-{
- FPRINTF("[Line : %d][%s] Inside callback MlPipelineSinkCallback \\n", __LINE__, API_NAMESPACE);
- guint *count = (guint *) user_data;
-
- *count = *count + 1;
- g_bCallbackHit = true;
-}
-
/**
* @function MlPipelineStateChangeCallback
* @description Pipeline state changed callback
pszNnpipeline = g_strdup ("input-selector name=ins ! tensor_converter ! tensor_sink name=sinkx "
"videotestsrc is-live=true ! videoconvert ! ins.sink_0 "
- "videotestsrc num-buffers=3 is-live=true ! videoconvert ! ins.sink_1");
+ "videotestsrc is-live=true ! videoconvert ! ins.sink_1");
g_pipePipeLineState = (TestPipeState *) g_new0 (TestPipeState, 1);
nRet = ml_pipeline_construct (pszNnpipeline, MlPipelineStateChangeCallback, g_pipePipeLineState, &g_hPipelinehandle);
*/
static void MlPipelineSinkCallback(const ml_tensors_data_h data, const ml_tensors_info_h info, void *user_data)
{
- FPRINTF("[Line : %d][%s] Inside callback MlPipelineSinkCallback \\n", __LINE__, API_NAMESPACE);
guint *count = (guint *) user_data;
*count = *count + 1;
g_bFeatureMLInterference = TCTCheckSystemInfoFeatureSupported(FEATURE_ML_INTERFACE, API_NAMESPACE);
g_bFeatureIsSupported = g_bFeatureML && g_bFeatureMLInterference;
- pszNnpipeline = "videotestsrc is-live=true ! videoconvert ! videoscale ! video/x-raw,format=RGBx,width=224,height=224,framerate=60/1 ! tensor_converter ! valve name=valve1 ! valve name=valvey ! input-selector name=is01 ! tensor_sink name=sinkx";
+ pszNnpipeline = g_strdup ("videotestsrc is-live=true ! videoconvert ! videoscale ! video/x-raw,format=RGBx,width=224,height=224,framerate=30/1 ! tensor_converter ! valve name=valve1 ! valve name=valvey ! input-selector name=is01 ! tensor_sink name=sinkx");
g_unsinkCount = (guint *) g_malloc (sizeof (guint));
*g_unsinkCount = 0;
}
g_hPipelinehandle = NULL;
}
+ g_free (g_unsinkCount);
+ g_free (g_pipePipeLineState);
+ g_free (pszNnpipeline);
}