427 * CS call: UPL: mic source and modem sink |
427 * CS call: UPL: mic source and modem sink |
428 * CS call: DNL: modem source and speaker sink |
428 * CS call: DNL: modem source and speaker sink |
429 * IP call: UPL: mic source, codec format and client sink |
429 * IP call: UPL: mic source, codec format and client sink |
430 * IP call: DNL: client source, codec format and speaker sink |
430 * IP call: DNL: client source, codec format and speaker sink |
431 * |
431 * |
432 * @return |
432 * @param retrytime |
|
433 * Indicates (in seconds) for how long TMS should retry stream |
|
434 * initialization in case of an error. When stream initialization |
|
435 * fails within specified retry time, TMS will return |
|
436 * TMS_EVENT_STREAM_STATE_CHANGE_ERROR. If set to 0, TMS will return |
|
437 * TMS_EVENT_STREAM_STATE_CHANGE_ERROR immediately without retrying. |
|
438 * If set to -1, TMS will keep retrying until user cancels by calling |
|
439 * either Stop() or Deinit(). |
|
440 * |
|
441 * @return |
|
442 * Common return codes: |
433 * TMS_RESULT_SUCCESS if stream transitioned to the initialized state. |
443 * TMS_RESULT_SUCCESS if stream transitioned to the initialized state. |
434 * TMS_RESULT_INVALID_STATE if stream has not transitioned to the |
444 * TMS_RESULT_INVALID_STATE if stream has not transitioned to the |
435 * TMS_STREAM_UNINITIALIZED state. |
445 * TMS_STREAM_INITIALIZED state. |
436 * TMS_RESULT_FORMAT_TYPE_UNSPECIFIED (IP call only) when stream |
446 * TMS_RESULT_FORMAT_TYPE_UNSPECIFIED (IP call only) when stream |
437 * has no format attached to it. |
447 * has no format attached to it. |
438 * TMS_RESULT_UNINITIALIZED_OBJECT when stream has no sink or source |
448 * TMS_RESULT_UNINITIALIZED_OBJECT when stream has no sink or source |
439 * element attached to it. |
449 * element attached to it. |
440 * |
450 * |
441 */ |
451 */ |
442 IMPORT_C gint Init(); |
452 IMPORT_C gint Init(gint retrytime = 0); |
443 |
453 |
444 /** |
454 /** |
445 * Trigger stream to transition to the paused state. |
455 * Trigger stream to transition to the paused state. |
446 * |
456 * |
447 * This function can be called only when stream is in the |
457 * This function can be called only when stream is in the |
454 * be in the TMS_STREAM_PAUSED state. |
464 * be in the TMS_STREAM_PAUSED state. |
455 * |
465 * |
456 * Note: In TMS Ver 1.0.0.0, pausing stream for CS call is not supported. |
466 * Note: In TMS Ver 1.0.0.0, pausing stream for CS call is not supported. |
457 * |
467 * |
458 * @return |
468 * @return |
459 * TMS_RESULT_SUCCESS if stream successfully transitioned to the paused |
469 * Common return codes: |
460 * state. |
470 * TMS_RESULT_SUCCESS if stream successfully transitioned to the |
|
471 * paused state. |
461 * TMS_RESULT_INVALID_STATE if stream is not in the |
472 * TMS_RESULT_INVALID_STATE if stream is not in the |
462 * TMS_STREAM_INITIALIZED or TMS_STREAM_STARTED state. |
473 * TMS_STREAM_INITIALIZED or TMS_STREAM_PAUSED state. |
463 * |
474 * |
464 */ |
475 */ |
465 IMPORT_C gint Pause(); |
476 IMPORT_C gint Pause(); |
466 |
477 |
467 /** |
478 /** |
478 * state change callback. |
489 * state change callback. |
479 * |
490 * |
480 * Upon stream's successful transition to the started state, the stream will |
491 * Upon stream's successful transition to the started state, the stream will |
481 * be in the TMS_STREAM_STARTED state. |
492 * be in the TMS_STREAM_STARTED state. |
482 * |
493 * |
483 * @return |
494 * @param retrytime |
484 * TMS_RESULT_SUCCESS if stream successfully transitioned to the paused |
495 * Indicates (in seconds) for how long TMS should attempt to start |
485 * state. |
496 * a stream in case of an error. When stream starting fails within |
|
497 * specified retry time, TMS will return |
|
498 * TMS_EVENT_STREAM_STATE_CHANGE_ERROR. If set to 0, TMS will return |
|
499 * TMS_EVENT_STREAM_STATE_CHANGE_ERROR immediately without retrying. |
|
500 * If set to -1, TMS will keep retrying until user cancels by calling |
|
501 * either Stop() or Deinit(). |
|
502 * |
|
503 * @return |
|
504 * Common return codes: |
|
505 * TMS_RESULT_SUCCESS if stream successfully transitioned to the |
|
506 * started state. |
486 * TMS_RESULT_INVALID_STATE if stream is not in the |
507 * TMS_RESULT_INVALID_STATE if stream is not in the |
487 * TMS_STREAM_INITIALIZED or TMS_STREAM_PAUSED state. |
508 * TMS_STREAM_INITIALIZED or TMS_STREAM_STARTED state. |
488 * |
509 * |
489 */ |
510 */ |
490 IMPORT_C gint Start(); |
511 IMPORT_C gint Start(gint retrytime = 0); |
491 |
512 |
492 /** |
513 /** |
493 * Trigger stream to transition to the initialized state. |
514 * Trigger stream to transition to the initialized state. |
494 * |
515 * |
495 * This function can be called only when stream is in the |
516 * This function can be called only when stream is in the |
500 * |
521 * |
501 * Upon stream's successful transition to the started state, the stream will |
522 * Upon stream's successful transition to the started state, the stream will |
502 * be in the TMS_STREAM_INITIALIZED state. |
523 * be in the TMS_STREAM_INITIALIZED state. |
503 * |
524 * |
504 * @return |
525 * @return |
505 * TMS_RESULT_SUCCESS if stream successfully transitioned to the paused |
526 * Common return codes: |
506 * state. |
527 * TMS_RESULT_SUCCESS if stream successfully transitioned to the |
|
528 * stopped state. |
507 * TMS_RESULT_INVALID_STATE if stream is not in the |
529 * TMS_RESULT_INVALID_STATE if stream is not in the |
508 * TMS_STREAM_STARTED or TMS_STREAM_PAUSED state. |
530 * TMS_STREAM_STARTED or TMS_STREAM_PAUSED state. |
509 * |
531 * |
510 */ |
532 */ |
511 IMPORT_C gint Stop(); |
533 IMPORT_C gint Stop(); |