status = nns_pipeline_start (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE); /* At this moment, it can be READY, PAUSED, or PLAYING */
EXPECT_NE (state, NNS_PIPELINE_UNKNOWN);
EXPECT_NE (state, NNS_PIPELINE_NULL);
- g_usleep(50000); /* 50ms. Let a few frames flow. */
- status = nns_pipeline_getstate(handle, &state);
+ g_usleep (50000); /* 50ms. Let a few frames flow. */
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (state, NNS_PIPELINE_PLAYING);
status = nns_pipeline_stop (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- g_usleep(50000); /* 50ms. Let a few frames flow. */
+ g_usleep (50000); /* 50ms. Let a few frames flow. */
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (state, NNS_PIPELINE_PAUSED);
status = nns_pipeline_start (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE); /* At this moment, it can be READY, PAUSED, or PLAYING */
EXPECT_NE (state, NNS_PIPELINE_UNKNOWN);
EXPECT_NE (state, NNS_PIPELINE_NULL);
- g_usleep(50000); /* 50ms. Let a few frames flow. */
- status = nns_pipeline_getstate(handle, &state);
+ g_usleep (50000); /* 50ms. Let a few frames flow. */
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (state, NNS_PIPELINE_PLAYING);
status = nns_pipeline_stop (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- g_usleep(50000); /* 50ms. Let a few frames flow. */
+ g_usleep (50000); /* 50ms. Let a few frames flow. */
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (state, NNS_PIPELINE_PAUSED);
EXPECT_NE (state, NNS_PIPELINE_UNKNOWN);
EXPECT_NE (state, NNS_PIPELINE_NULL);
- g_usleep(50000); /* 50ms. Enough to empty the queue */
+ g_usleep (50000); /* 50ms. Enough to empty the queue */
status = nns_pipeline_stop (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (state, NNS_PIPELINE_PAUSED);
*/
TEST (nnstreamer_capi_valve, test01)
{
- const gchar *_tmpdir = g_get_tmp_dir();
+ const gchar *_tmpdir = g_get_tmp_dir ();
const gchar *_dirname = "nns-tizen-XXXXXX";
gchar *fullpath = g_build_path ("/", _tmpdir, _dirname, NULL);
- gchar *dir = g_mkdtemp((gchar *) fullpath);
- gchar *file1 = g_build_path("/", dir, "valve1", NULL);
- gchar *pipeline = g_strdup_printf("videotestsrc is-live=true num-buffers=20 ! videoconvert ! videoscale ! video/x-raw,format=RGBx,width=16,height=16,framerate=60/1 ! tensor_converter ! queue ! valve name=valve1 ! filesink location=\"%s\"",
- file1);
+ gchar *dir = g_mkdtemp ((gchar *) fullpath);
+ gchar *file1 = g_build_path ("/", dir, "valve1", NULL);
+ gchar *pipeline =
+ g_strdup_printf
+ ("videotestsrc is-live=true num-buffers=20 ! videoconvert ! videoscale ! video/x-raw,format=RGBx,width=16,height=16,framerate=60/1 ! tensor_converter ! queue ! valve name=valve1 ! filesink location=\"%s\"",
+ file1);
GStatBuf buf;
nns_pipeline_h handle;
EXPECT_TRUE (dir != NULL);
- status = nns_pipeline_valve_gethandle (handle, "valve1", &valve1);
+ status = nns_pipeline_valve_get_handle (handle, "valve1", &valve1);
EXPECT_EQ (status, NNS_ERROR_NONE);
status = nns_pipeline_start (handle);
status = nns_pipeline_valve_control (valve1, 1); /* close */
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE); /* At this moment, it can be READY, PAUSED, or PLAYING */
EXPECT_NE (state, NNS_PIPELINE_UNKNOWN);
EXPECT_NE (state, NNS_PIPELINE_NULL);
- g_usleep(100000); /* 100ms. Let a few frames flow. */
+ g_usleep (100000); /* 100ms. Let a few frames flow. */
status = nns_pipeline_stop (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
status = nns_pipeline_valve_control (valve1, 0); /* open */
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_valve_puthandle (valve1); /* release valve handle */
+ status = nns_pipeline_valve_put_handle (valve1); /* release valve handle */
EXPECT_EQ (status, NNS_ERROR_NONE);
- g_usleep(50000); /* 50ms. Let a few frames flow. */
+ g_usleep (50000); /* 50ms. Let a few frames flow. */
status = nns_pipeline_stop (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
/**
* @brief A tensor-sink callback for sink handle in a pipeline
*/
-static void nns_sink_callback_dm01 (const char *buf[], const size_t size[],
- const nns_tensors_info_s *tensorsinfo, void *pdata)
+static void
+nns_sink_callback_dm01 (const char *buf[], const size_t size[],
+ const nns_tensors_info_s * tensorsinfo, void *pdata)
{
gchar *filepath = (gchar *) pdata;
FILE *fp = g_fopen (filepath, "a");
/**
* @brief compare the two files.
*/
-static int file_cmp (const gchar *f1, const gchar *f2)
+static int
+file_cmp (const gchar * f1, const gchar * f2)
{
gboolean r;
gchar *content1, *content2;
gchar *file1 = g_build_path ("/", dir, "original", NULL);
gchar *file2 = g_build_path ("/", dir, "sink", NULL);
- gchar *pipeline = g_strdup_printf ("videotestsrc num-buffers=3 ! videoconvert ! video/x-raw,format=BGRx,width=64,height=48,famerate=60/1 ! tee name=t t. ! queue ! filesink location=\"%s\" t. ! queue ! tensor_converter ! tensor_sink name=sinkx",
+ gchar *pipeline =
+ g_strdup_printf
+ ("videotestsrc num-buffers=3 ! videoconvert ! video/x-raw,format=BGRx,width=64,height=48,famerate=60/1 ! tee name=t t. ! queue ! filesink location=\"%s\" t. ! queue ! tensor_converter ! tensor_sink name=sinkx",
file1);
nns_pipeline_h handle;
nns_pipeline_state_e state;
status = nns_pipeline_start (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE); /* At this moment, it can be READY, PAUSED, or PLAYING */
EXPECT_NE (state, NNS_PIPELINE_UNKNOWN);
EXPECT_NE (state, NNS_PIPELINE_NULL);
- g_usleep(100000); /* 100ms. Let a few frames flow. */
- status = nns_pipeline_getstate(handle, &state);
+ g_usleep (100000); /* 100ms. Let a few frames flow. */
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (state, NNS_PIPELINE_PLAYING);
status = nns_pipeline_stop (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- g_usleep(10000); /* 10ms. Wait a bit. */
+ g_usleep (10000); /* 10ms. Wait a bit. */
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (state, NNS_PIPELINE_PAUSED);
}
static char uintarray[10][4];
-static char* uia_index[10];
+static char *uia_index[10];
/**
* @brief Test NNStreamer pipeline src
gchar *fullpath = g_build_path ("/", _tmpdir, _dirname, NULL);
gchar *dir = g_mkdtemp ((gchar *) fullpath);
gchar *file1 = g_build_path ("/", dir, "output", NULL);
- gchar *pipeline = g_strdup_printf ("appsrc name=srcx ! other/tensor,dimension=4:1:1:1,type=uint8,framerate=0/1 ! filesink location=\"%s\"",
+ gchar *pipeline =
+ g_strdup_printf
+ ("appsrc name=srcx ! other/tensor,dimension=4:1:1:1,type=uint8,framerate=0/1 ! filesink location=\"%s\"",
file1);
nns_pipeline_h handle;
nns_pipeline_state_e state;
uint8_t *content;
gboolean r;
gsize len;
- const size_t size[1] = {4};
+ const size_t size[1] = { 4 };
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_TRUE (dir != NULL);
uia_index[i] = &uintarray[i][0];
uintarray[i][0] = i;
- uintarray[i][1] = i+1;
- uintarray[i][2] = i+3;
- uintarray[i][3] = i+2;
+ uintarray[i][1] = i + 1;
+ uintarray[i][2] = i + 3;
+ uintarray[i][3] = i + 2;
uintarray2[i] = (char *) g_malloc (4);
- uintarray2[i][0] = i+3;
- uintarray2[i][1] = i+2;
- uintarray2[i][2] = i+1;
+ uintarray2[i][0] = i + 3;
+ uintarray2[i][1] = i + 2;
+ uintarray2[i][2] = i + 1;
uintarray2[i][3] = i;
/* These will be free'ed by gstreamer (NNS_BUF_FREE_BY_NNSTREAMER) */
/** @todo Check whether gstreamer really deallocates this */
status = nns_pipeline_start (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_getstate(handle, &state);
+ status = nns_pipeline_get_state (handle, &state);
EXPECT_EQ (status, NNS_ERROR_NONE); /* At this moment, it can be READY, PAUSED, or PLAYING */
EXPECT_NE (state, NNS_PIPELINE_UNKNOWN);
EXPECT_NE (state, NNS_PIPELINE_NULL);
-
- status = nns_pipeline_src_gethandle (handle, "srcx", &tensorsinfo, &srchandle);
+ status = nns_pipeline_src_get_handle (handle, "srcx", &tensorsinfo, &srchandle);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (tensorsinfo.num_tensors, 1);
tensorsinfo.info[0].dimension[2] = 1;
tensorsinfo.info[0].dimension[3] = 1;
- status = nns_pipeline_src_inputdata (srchandle, NNS_BUF_DO_NOT_FREE1,
+ status = nns_pipeline_src_input_data (srchandle, NNS_BUF_DO_NOT_FREE1,
&(uia_index[0]), size, 1);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_src_inputdata (srchandle, NNS_BUF_DO_NOT_FREE1,
+ status = nns_pipeline_src_input_data (srchandle, NNS_BUF_DO_NOT_FREE1,
&(uia_index[0]), size, 1);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_src_puthandle (srchandle);
+ status = nns_pipeline_src_put_handle (srchandle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_src_gethandle (handle, "srcx", &tensorsinfo, &srchandle);
+ status = nns_pipeline_src_get_handle (handle, "srcx", &tensorsinfo, &srchandle);
EXPECT_EQ (status, NNS_ERROR_NONE);
EXPECT_EQ (tensorsinfo.num_tensors, 1);
for (i = 0; i < 10; i++) {
- status = nns_pipeline_src_inputdata (srchandle, NNS_BUF_DO_NOT_FREE1,
+ status = nns_pipeline_src_input_data (srchandle, NNS_BUF_DO_NOT_FREE1,
&(uia_index[i]), size, 1);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_src_inputdata (srchandle, NNS_BUF_FREE_BY_NNSTREAMER,
+ status = nns_pipeline_src_input_data (srchandle, NNS_BUF_FREE_BY_NNSTREAMER,
&(uintarray2[i]), size, 1);
EXPECT_EQ (status, NNS_ERROR_NONE);
}
- status = nns_pipeline_src_puthandle (srchandle);
+ status = nns_pipeline_src_put_handle (srchandle);
EXPECT_EQ (status, NNS_ERROR_NONE);
g_usleep (50000); /* Wait for the pipeline to flush all */
EXPECT_EQ (len, 8 * 11);
for (i = 0; i < 10; i++) {
- EXPECT_EQ (content[i*8 + 0 + 8], i);
- EXPECT_EQ (content[i*8 + 1 + 8], i+1);
- EXPECT_EQ (content[i*8 + 2 + 8], i+3);
- EXPECT_EQ (content[i*8 + 3 + 8], i+2);
- EXPECT_EQ (content[i*8 + 4 + 8], i+3);
- EXPECT_EQ (content[i*8 + 5 + 8], i+2);
- EXPECT_EQ (content[i*8 + 6 + 8], i+1);
- EXPECT_EQ (content[i*8 + 7 + 8], i);
+ EXPECT_EQ (content[i * 8 + 0 + 8], i);
+ EXPECT_EQ (content[i * 8 + 1 + 8], i + 1);
+ EXPECT_EQ (content[i * 8 + 2 + 8], i + 3);
+ EXPECT_EQ (content[i * 8 + 3 + 8], i + 2);
+ EXPECT_EQ (content[i * 8 + 4 + 8], i + 3);
+ EXPECT_EQ (content[i * 8 + 5 + 8], i + 2);
+ EXPECT_EQ (content[i * 8 + 6 + 8], i + 1);
+ EXPECT_EQ (content[i * 8 + 7 + 8], i);
}
g_free (content);
nns_tensors_info_s tensorsinfo;
nns_src_h srchandle;
- status = nns_pipeline_src_gethandle (NULL, "dummy", &tensorsinfo, &srchandle);
+ status = nns_pipeline_src_get_handle (NULL, "dummy", &tensorsinfo, &srchandle);
EXPECT_EQ (status, NNS_ERROR_INVALID_PARAMETER);
}
int status = nns_pipeline_construct (pipeline, &handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_src_gethandle (handle, "wrongname", &tensorsinfo, &srchandle);
+ status = nns_pipeline_src_get_handle (handle, "wrongname", &tensorsinfo, &srchandle);
EXPECT_EQ (status, NNS_ERROR_INVALID_PARAMETER);
status = nns_pipeline_destroy (handle);
nns_pipeline_h handle;
nns_tensors_info_s tensorsinfo;
nns_src_h srchandle;
- const size_t tensor_size[1] = {num_dims};
+ const size_t tensor_size[1] = { num_dims };
char *pbuffer[num_tensors];
for (int i = 0; i < num_tensors; ++i)
- pbuffer[i] = (char *)g_malloc0 (sizeof(char) * num_dims);
+ pbuffer[i] = (char *) g_malloc0 (sizeof (char) * num_dims);
int status = nns_pipeline_construct (pipeline, &handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
status = nns_pipeline_start (handle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_src_gethandle (handle, "srcx", &tensorsinfo, &srchandle);
+ status = nns_pipeline_src_get_handle (handle, "srcx", &tensorsinfo, &srchandle);
EXPECT_EQ (status, NNS_ERROR_NONE);
- status = nns_pipeline_src_inputdata (srchandle, NNS_BUF_DO_NOT_FREE1,
- &(pbuffer[0]), tensor_size, num_tensors);
+ status = nns_pipeline_src_input_data (srchandle, NNS_BUF_DO_NOT_FREE1,
+ &(pbuffer[0]), tensor_size, num_tensors);
EXPECT_EQ (status, NNS_ERROR_INVALID_PARAMETER);
- status = nns_pipeline_src_inputdata (srchandle, NNS_BUF_DO_NOT_FREE1,
- &(pbuffer[0]), tensor_size, 0);
+ status = nns_pipeline_src_input_data (srchandle, NNS_BUF_DO_NOT_FREE1,
+ &(pbuffer[0]), tensor_size, 0);
EXPECT_EQ (status, NNS_ERROR_INVALID_PARAMETER);
- status = nns_pipeline_src_puthandle (srchandle);
+ status = nns_pipeline_src_put_handle (srchandle);
EXPECT_EQ (status, NNS_ERROR_NONE);
status = nns_pipeline_stop (handle);
/**
* @brief Main gtest
*/
-int main (int argc, char **argv)
+int
+main (int argc, char **argv)
{
testing::InitGoogleTest (&argc, argv);
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid. (pipe is NULL?)
* @retval #NNS_ERROR_STREAMS_PIPE Failed to get state from the pipeline.
*/
-int nns_pipeline_getstate (nns_pipeline_h pipe, nns_pipeline_state_e *state);
+int nns_pipeline_get_state (nns_pipeline_h pipe, nns_pipeline_state_e *state);
/****************************************************
** NNStreamer Pipeline Start/Stop Control **
/**
* @brief Gets a handle to operate as a src node of nnstreamer pipelines.
* @since_tizen 5.5
- * @remarks If the function succeeds, @a h handle must be released using nns_pipeline_src_puthandle().
+ * @remarks If the function succeeds, @a h handle must be released using nns_pipeline_src_put_handle().
* @param[in] pipe The pipeline to be attached with a src node.
* @param[in] srcname The name of src node, described with nns_pipeline_construct().
* @param[out] tensors_info The cardinality, dimension, and type of given tensor/tensors.
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid.
* @retval #NNS_ERROR_STREAMS_PIPE Fail to get SRC element.
*/
-int nns_pipeline_src_gethandle (nns_pipeline_h pipe, const char *srcname, nns_tensors_info_s *tensors_info, nns_src_h *h);
+int nns_pipeline_src_get_handle (nns_pipeline_h pipe, const char *srcname, nns_tensors_info_s *tensors_info, nns_src_h *h);
/**
* @brief Closes the given handle of a src node of nnstreamer pipelines.
* @retval #NNS_ERROR_NONE Successful
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid.
*/
-int nns_pipeline_src_puthandle (nns_src_h h);
+int nns_pipeline_src_put_handle (nns_src_h h);
/**
* @brief Puts an input data frame.
* @param[in] h The nns_src_handle returned by nns_pipeline_gethandle().
* @param[in] policy The policy of buf deallocation.
* @param[in] buf The input buffers, in the format of tensorsinfo given by nns_pipeline_gethandle()
- * @param[in] size The sizes of input buffers. This must be consistent with the given tensorsinfo, probed by nns_pipeline_src_gethandle().
- * @param[in] num_tensors The number of tensors (number of buf and number of size) for the input frame. This must be consistent with the given tensorinfo, probed by nns_pipeline_src_gethandle(). MAX is 16 (NNS_TENSOR_SIZE_LIMIT).
+ * @param[in] size The sizes of input buffers. This must be consistent with the given tensorsinfo, probed by nns_pipeline_src_get_handle().
+ * @param[in] num_tensors The number of tensors (number of buf and number of size) for the input frame. This must be consistent with the given tensorinfo, probed by nns_pipeline_src_get_handle(). MAX is 16 (NNS_TENSOR_SIZE_LIMIT).
* @return 0 on success (buf is filled). otherwise a negative error value.
* @retval #NNS_ERROR_NONE Successful
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid.
*
* @todo Allow to use GstBuffer instead of buf/size pairs, probably with yet another API.
*/
-int nns_pipeline_src_inputdata (nns_src_h h, nns_buf_policy_e policy, char *buf[], const size_t size[], unsigned int num_tensors);
+int nns_pipeline_src_input_data (nns_src_h h, nns_buf_policy_e policy, char *buf[], const size_t size[], unsigned int num_tensors);
/****************************************************
** NNStreamer Pipeline Switch/Valve Control **
* @brief Gets a handle to operate a "GstInputSelector / GstOutputSelector" node of nnstreamer pipelines.
* @detail Refer to https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-bad-plugins/html/gst-plugins-bad-plugins-input-selector.html for input selectors.
* Refer to https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-plugins/html/gstreamer-plugins-output-selector.html for output selectors.
- * @remarks If the function succeeds, @a h handle must be released using nns_pipeline_switch_puthandle().
+ * @remarks If the function succeeds, @a h handle must be released using nns_pipeline_switch_put_handle().
* @param[in] pipe The pipeline to be managed.
* @param[in] switchname The name of switch (InputSelector/OutputSelector)
* @param[out] type The type of the switch. If NULL, it is ignored.
* @retval #NNS_ERROR_NONE Successful
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid.
*/
-int nns_pipeline_switch_gethandle (nns_pipeline_h pipe, const char *switchname, nns_switch_type_e *type, nns_switch_h *h);
+int nns_pipeline_switch_get_handle (nns_pipeline_h pipe, const char *switchname, nns_switch_type_e *type, nns_switch_h *h);
/**
* @brief Closes the given switch handle.
* @retval #NNS_ERROR_NONE Successful
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid.
*/
-int nns_pipeline_switch_puthandle (nns_switch_h h);
+int nns_pipeline_switch_put_handle (nns_switch_h h);
/**
* @brief Controls the switch with the given handle to select input/output nodes(pads).
- * @param[in] h The switch handle returned by nns_pipeline_switch_gethandle()
+ * @param[in] h The switch handle returned by nns_pipeline_switch_get_handle()
* @param[in] padname The name of the chosen pad to be activated. Use nns_pipeline_switch_nodelist to list the available pad names.
* @return @c 0 on success. otherwise a negative error value
* @retval #NNS_ERROR_NONE Successful
/**
* @brief Gets the pad names of a switch.
- * @param[in] h The switch handle returned by nns_pipeline_switch_gethandle()
+ * @param[in] h The switch handle returned by nns_pipeline_switch_get_handle()
* @param[out] list NULL terminated array of char*. The caller must free each string (char*) in the list and free the list itself.
* @return @c 0 on success. otherwise a negative error value
* @retval #NNS_ERROR_NONE Successful
/**
* @brief Gets a handle to operate a "GstValve" node of nnstreamer pipelines.
* @detail Refer to https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-plugins/html/gstreamer-plugins-valve.html for more info.
- * @remarks If the function succeeds, @a h handle must be released using nns_pipeline_valve_puthandle().
+ * @remarks If the function succeeds, @a h handle must be released using nns_pipeline_valve_put_handle().
* @param[in] pipe The pipeline to be managed.
* @param[in] valvename The name of valve (Valve)
* @param[out] h The valve handle.
* @retval #NNS_ERROR_NONE Successful
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid.
*/
-int nns_pipeline_valve_gethandle (nns_pipeline_h pipe, const char *valvename, nns_valve_h *h);
+int nns_pipeline_valve_get_handle (nns_pipeline_h pipe, const char *valvename, nns_valve_h *h);
/**
* @brief Closes the given valve handle.
* @retval #NNS_ERROR_NONE Successful
* @retval #NNS_ERROR_INVALID_PARAMETER Given parameter is invalid.
*/
-int nns_pipeline_valve_puthandle (nns_valve_h h);
+int nns_pipeline_valve_put_handle (nns_valve_h h);
/**
* @brief Controls the valve with the given handle.
- * @param[in] h The valve handle returned by nns_pipeline_valve_gethandle()
+ * @param[in] h The valve handle returned by nns_pipeline_valve_get_handle()
* @param[in] valve_drop 1 to close (drop & stop the flow). 0 to open (let the flow pass)
* @return @c 0 on success. otherwise a negative error value
* @retval #NNS_ERROR_NONE Successful