platform/core/uifw/tts.git
2 years agoDefine class for managing audio stream 67/271267/2
Suyeon Hwang [Wed, 28 Apr 2021 02:48:38 +0000 (11:48 +0900)]
Define class for managing audio stream

ttsd_player.cpp has too complexity responsibility to play PCM data. This complexity makes bad code
to maintain.

This patch makes new class AudioStream to manage audio stream. By this new class, we can simplify
the responsibility of ttsd_player.cpp, and this enhance the maintainability.

Change-Id: I3537411c41349166cd617815e65415676dda4723
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Fix potential defects on ttsd_player" into tizen
Suyeon Hwang [Thu, 17 Feb 2022 02:46:48 +0000 (02:46 +0000)]
Merge "Fix potential defects on ttsd_player" into tizen

2 years agoUse BackgroundVolume class on ttsd_player 20/271120/3
Suyeon Hwang [Fri, 7 May 2021 07:13:40 +0000 (16:13 +0900)]
Use BackgroundVolume class on ttsd_player

Change-Id: I598a0d7c7525ca97c1edd747b1a1c0e38ef9baab
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoDefine class for managing background sound 19/271119/3
Suyeon Hwang [Thu, 6 May 2021 02:54:15 +0000 (11:54 +0900)]
Define class for managing background sound

ttsd_player.cpp has too complexity responsibility to play PCM data. This complexity makes bad code
to maintain.

This patch makes new class BackgroundVolume to manage background sound. By this new class,
we can simplify the responsibility of ttsd_player.cpp, and this enhance the maintainability.

Change-Id: I080b092af1c833473bac30f768fefac3ec2d0674
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix potential defects on ttsd_player 45/271145/1
Suyeon Hwang [Wed, 16 Feb 2022 02:30:02 +0000 (11:30 +0900)]
Fix potential defects on ttsd_player

This patch includes this changes in order to fix some potential defects:
- Remove null pointer dereferencing
- Add mutex lock in order to use conditional wait
- Move assigning code to avoid change out of critical section

Change-Id: Iad704cfd30316b5299ab5acbb47178fb6ef2c12a
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoAdd code to check whether the player is initialized 95/271095/2
Suyeon Hwang [Thu, 20 Jan 2022 06:57:51 +0000 (15:57 +0900)]
Add code to check whether the player is initialized

Change-Id: Ic651a374b408dd10f0cee033e49c080d678d178f
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoChange file format of ttsd_player from c to cpp 14/266214/9
Suyeon Hwang [Tue, 27 Apr 2021 09:33:04 +0000 (18:33 +0900)]
Change file format of ttsd_player from c to cpp

To enhance readability, this patch changes the format of ttsd_player from c to cpp.

By this change, we can apply cpp grammar into ttsd_player code to enhance the readability and
simplify the code. And also, we can use class to seperate the responsibility of ttsd_player to
decrease the complexity.

Change-Id: I63ce7efe9729a4b31377265fc21d0551397aa160
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix condition to remove dead code 41/268941/5
Suyeon Hwang [Wed, 5 Jan 2022 04:44:56 +0000 (13:44 +0900)]
Fix condition to remove dead code

In current code, speak_data is not null if ttsd_data_get_speak_data() returns error none, so null
check on line #99 ~ #102 would become dead code.

To remove this dead code, this patch fixes the condition to check the result of
ttsd_data_get_speak_data(). And this patch fixes some potential memory leak and enhances the
readability.

Change-Id: Ic8dcf0eea79cb57a4a8ad8cf6afc9d59fcd60e49
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix prototypes of internal functions to increase readability 13/266213/9
Suyeon Hwang [Mon, 26 Apr 2021 10:36:04 +0000 (19:36 +0900)]
Fix prototypes of internal functions to increase readability

Some internal functions are not declared as a static. Using static keyword, each functions can
avoid the access from out of file.
And also, some functions have too many parameters and it makes difficult to use.

This patch adds static keywords to internal functions and simplify some internal function.

Change-Id: I6e315f19fe84c063f094cd1a665b2c2ae7097b19
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMake function for managing sound_data_s 12/266212/9
Suyeon Hwang [Tue, 27 Apr 2021 08:47:06 +0000 (17:47 +0900)]
Make function for managing sound_data_s

In previous code, instance of sound_data_s is created by ttsd_server.c. However, destruction of
instance is by ttsd_data.c.
This way of memory management is dangerous, because invalid memory access can occur by the mistake
of developers.

This patch provides two new function for creating and destroying instance of sound_data_s.
These functions provide safe creation and destruction of the instance.

Change-Id: I18634d45e5a145238989c5eeefb7457332e7a782
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMake function for managing speak_data_s 11/266211/9
Suyeon Hwang [Mon, 26 Apr 2021 06:36:59 +0000 (15:36 +0900)]
Make function for managing speak_data_s

In previous code, instance of speak_data_s created by ttsd_server.c but destroyed by ttsd_data.c.
This way of memory management is dangerous because invalid memory access can occur by the mistake
of developers.

This patch provides two new function for creating and destroying instance of speak_data_s.
These functions provide safe creation and destruction of the instance.

Change-Id: I016720eccbffd16bdfcb23878573caa1cb9f3115
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUse single play thread to play PCM data 10/266210/9
Suyeon Hwang [Wed, 21 Apr 2021 10:40:41 +0000 (19:40 +0900)]
Use single play thread to play PCM data

To simplify the management of player thread, this patch makes only one sub thread to play PCM data.

Change-Id: I9f0a050f59411bb692e038488e474dce0716cb46
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Return error when TTS engine is terminated before beginning the main loop... submit/tizen/20220211.020451
Suyeon Hwang [Thu, 10 Feb 2022 02:38:13 +0000 (02:38 +0000)]
Merge "Return error when TTS engine is terminated before beginning the main loop" into tizen

2 years agoSend return value from server to client 32/270832/1
Suyeon Hwang [Fri, 28 Jan 2022 08:57:44 +0000 (17:57 +0900)]
Send return value from server to client

Current code does not send return value of server error to client which uses TIDL as IPC method.
However, this can make unintented behavior because some function like tts_play() needs to error
value for returning.

This patch makes server send return value to client although the client uses TIDL. By this change,
clients can always get proper error values from server.

Change-Id: Ibb98cd1bf64e92746022632f3bc5bf9eded904df
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
(cherry picked from commit 3a86f249ae8266bf145944f108088af0dd5f2ba3)

2 years agoReturn error when TTS engine is terminated before beginning the main loop 31/270831/1
sooyeon [Fri, 28 Jan 2022 00:49:43 +0000 (09:49 +0900)]
Return error when TTS engine is terminated before beginning the main loop

Change-Id: I93e5a1b189632629f3e3334d08d7d99a9942042a
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
(cherry picked from commit 8ac094519445240d9c29133b1ada3dd7c2a7b73a)

2 years agoSend new state to client synchornously 75/269575/3
Suyeon Hwang [Wed, 12 Jan 2022 04:30:41 +0000 (13:30 +0900)]
Send new state to client synchornously

Current code sends new state asynchornously using ecore timer in order to prohibit main loop
from being blocked. However, sending new state can be delayed by the event from
ecore_main_loop_thread_safe_call_async(). Callback registered by this function has higher priority
than the ecore timer callback. This may cause uninteded behavior on client side.

To prevent this situation, this patch sends new state synchornously. By this patch, client gets
new state immediately after stop player. Of course, IPC overhead can be added into
ttsd_server_play(), but the overhead is short enough.

Change-Id: Ia580edbd957d57a215d3d760fdcd8de54b73c49c
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUpdate version to 1.70.0 15/269815/1 submit/tizen/20220120.074959
wn.jang [Thu, 20 Jan 2022 07:35:36 +0000 (16:35 +0900)]
Update version to 1.70.0

Change-Id: I1025a116f660c8006dad779956dbe88d77c740ed

2 years agoCoverage support for robot profile 93/269693/3
wn.jang [Thu, 20 Jan 2022 04:22:14 +0000 (13:22 +0900)]
Coverage support for robot profile

Change-Id: I94628c39ae124a282001a1ccf4f2afc8cc07e5b4

2 years agoTerminate service engine when engine is changed 52/269452/1
Suyeon Hwang [Fri, 14 Jan 2022 02:55:12 +0000 (11:55 +0900)]
Terminate service engine when engine is changed

Change-Id: I2d9bc90b0ce71cb37b9c9f4997debdb7dc517061
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
(cherry picked from commit 4bd34ef0d4ef885642c3752b7ecfcdf76d5d2694)

2 years agoAdd credential field into app data on server side 67/268967/1
Suyeon Hwang [Wed, 5 Jan 2022 09:32:14 +0000 (18:32 +0900)]
Add credential field into app data on server side

Change-Id: I7e0ddb44b6053c4cd6002414f3157e4a32640567
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoAdd app check code to handle TCs 83/268883/1
Suyeon Hwang [Tue, 4 Jan 2022 03:00:34 +0000 (12:00 +0900)]
Add app check code to handle TCs

Change-Id: Iaaf4804ec6099dbb072e6473faba3eff8c427685
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
(cherry picked from commit 85cf465610d564ba60ebb9f7a2d7b2ac711a39bb)

2 years agoCall finalize synchronously when app termination is requested by app fw 95/268695/2
Suyeon Hwang [Thu, 30 Dec 2021 03:05:30 +0000 (12:05 +0900)]
Call finalize synchronously when app termination is requested by app fw

Current code always calls finalize using ecore timer, so finalize codes must be called on next
event loop. However, finalize can not be worked because there is no event loop when app is
terminated by outside app terminate request. This behavior can make unintended problem.

To resolve this problem this patch makes server call finalize synchronously when app is terminated
by outside request. By this change, finalize must be called in the case.

Change-Id: Ib22cf36fd16e227ad606b78dbbfbd660242335bf
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge branch 'tizen_6.5' into tizen 94/268594/1
Suyeon Hwang [Mon, 27 Dec 2021 09:08:28 +0000 (18:08 +0900)]
Merge branch 'tizen_6.5' into tizen

Change-Id: Ic8aa8568180c89b29c2be41178951385ac972605

2 years agoUpdate version (1.70.0) 93/268593/1
Suyeon Hwang [Mon, 27 Dec 2021 08:55:17 +0000 (17:55 +0900)]
Update version (1.70.0)

Change-Id: I3b3e91576cf1854ab633a593c46feea4a923cf3f
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUpdate version (1.65.17) 82/268582/1
Suyeon Hwang [Mon, 27 Dec 2021 08:38:23 +0000 (17:38 +0900)]
Update version (1.65.17)

Change-Id: I07459ac7d601073736b62dda9efc6b199e72e43a
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoGet UID from list using tts_config_client_s structure 94/268294/4
Suyeon Hwang [Mon, 20 Dec 2021 04:53:26 +0000 (13:53 +0900)]
Get UID from list using tts_config_client_s structure

Current code converts the type of element as integer. However, the element of the list is instance
of tts_config_client_s structure. Because the first member of the structure is uid, so current code
has no problem until now. But this can occur problem if the type of uid or the order of member is
changed.

To solve this problem, this patch changes the type from integer to the structure. This can provide
safe access to member.

Change-Id: I168011529efec4a59a1a1abc8b7d203e412a4972
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix the data type for uid 41/268241/6
Suyeon Hwang [Fri, 17 Dec 2021 08:44:16 +0000 (17:44 +0900)]
Fix the data type for uid

On 32bit architecture, signed integer is enough to store uid value. However, on 64bit architecture,
signed integer is not enough because maximum value of pid is 4194304 and value of pid * 1000 is
bigger than the limit of signed integer. And it cause overflow problem.

To solve this issue, this patch changes the data type of variable that stores uid.
Unsigned integer can provides enough space to store uid value on 64bit os.

Change-Id: I7e4cc46ca454c8a8fb38d37a4434eee492aefee9
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoReset flag and thread pointer 98/268398/1
Suyeon Hwang [Wed, 22 Dec 2021 08:06:36 +0000 (17:06 +0900)]
Reset flag and thread pointer

Change-Id: Id26e7dedbb3baf6657e50c24c259c3d4a3b34a56
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoSkip waiting if reprepare by engine changed 81/263681/2
Suyeon Hwang [Wed, 8 Sep 2021 06:02:03 +0000 (15:02 +0900)]
Skip waiting if reprepare by engine changed

Change-Id: Ia4fd4aa75f4d49c21aea8c59cfaf08d2a64e5512
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoDefine constant for max length of app ID 80/263680/2
Suyeon Hwang [Wed, 8 Sep 2021 03:36:26 +0000 (12:36 +0900)]
Define constant for max length of app ID

Change-Id: Id8d394884fb5136a9e577ff735e9e3197e91760e
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoReactivate sound ducking when background volume ratio is changed 44/268344/1
Suyeon Hwang [Tue, 21 Dec 2021 06:57:53 +0000 (15:57 +0900)]
Reactivate sound ducking when background volume ratio is changed

To avoid some side effect or unintended behavior, current code does not apply the change of
background volume ratio immediately. To apply it immediately, tts service has to deactivate the
sound ducking and activate it again. This may cause tick noise or failure to recover background
volume. However, the requirement wants to apply the background volume ratio immediately.

Thus, this patch deactivate and activate the sound ducking right after changing background volume
ratio. To do this safely, the new code handles the behavior for background volume on main loop.
And this new code only works when the sound ducking is activated.

Change-Id: I11ea051aaa69b5a0bd959853d72943569c678a57
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoSet client type when config already initialized 17/268317/2 submit/tizen_6.5/20211223.020506
Suyeon Hwang [Mon, 20 Dec 2021 08:46:56 +0000 (17:46 +0900)]
Set client type when config already initialized

Change-Id: I72a698aeb074890d03e642b2ccb11e65c839dd4a
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoAdd retry logic when rpc_port_stub_tts_register() is failed 75/268275/1
sooyeon [Sun, 19 Dec 2021 13:40:04 +0000 (22:40 +0900)]
Add retry logic when rpc_port_stub_tts_register() is failed

Change-Id: Ide6d36eb8b6f66fd156358fead29e911f936ffd1
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoMerge "Add thread_wait to wait g_reprepare_thread is terminated" into tizen_6.5
Sooyeon Kim [Fri, 17 Dec 2021 07:49:40 +0000 (07:49 +0000)]
Merge "Add thread_wait to wait g_reprepare_thread is terminated" into tizen_6.5

2 years agoAdd thread_wait to wait g_reprepare_thread is terminated 33/268233/1
sooyeon [Fri, 17 Dec 2021 16:03:50 +0000 (01:03 +0900)]
Add thread_wait to wait g_reprepare_thread is terminated

Change-Id: Icabe75f263144ba51c03487d2e918e4d6529547d
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoRearrange logs 88/268188/3
sooyeon [Fri, 17 Dec 2021 09:00:48 +0000 (18:00 +0900)]
Rearrange logs

Change-Id: Ia6089503030001bd8072c79518fe05a997333c72
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoMerge "Fix config client type as a bit flat" into tizen_6.5
Wonnam Jang [Fri, 17 Dec 2021 07:40:48 +0000 (07:40 +0000)]
Merge "Fix config client type as a bit flat" into tizen_6.5

2 years agoFix config client type as a bit flat 19/268219/2
Suyeon Hwang [Fri, 17 Dec 2021 06:47:52 +0000 (15:47 +0900)]
Fix config client type as a bit flat

There is case that the app uses both client and setting API. In current code, this kind of usage
can cause invalid blocking to fix configuration file. Because current config client type is only
store single mode in one process.

To solve this problem, this patch changes config client type to bit flag variable. By this change,
a process can store multiple client type, and this can avoid wrong behavior.

Change-Id: I66bdb64cff148da5a0cc3cc725842265534d4842
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix SVACE issue (Add mutex_unlock before returning) 29/268129/1
sooyeon [Thu, 16 Dec 2021 19:49:00 +0000 (04:49 +0900)]
Fix SVACE issue (Add mutex_unlock before returning)

Change-Id: I6b5749b8221d577231db6b60361fb69658659bdc
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoUpdate version (1.65.16) 13/267613/1 accepted/tizen/6.5/unified/20211212.212705 submit/tizen_6.5/20211208.023642
Suyeon Hwang [Wed, 8 Dec 2021 01:40:46 +0000 (10:40 +0900)]
Update version (1.65.16)

Change-Id: If5beefbbc7c1826f3ccf63785a7eb8ab16c09608
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Call ttse_terminate when engine is changed before registering vconfkey callbac...
Suyeon Hwang [Tue, 7 Dec 2021 09:58:08 +0000 (09:58 +0000)]
Merge "Call ttse_terminate when engine is changed before registering vconfkey callback" into tizen_6.5

2 years agoCall ttse_terminate when engine is changed before registering vconfkey callback 79/267579/1
sooyeon [Tue, 7 Dec 2021 17:58:57 +0000 (02:58 +0900)]
Call ttse_terminate when engine is changed before registering vconfkey callback

Change-Id: I92785e18c480154f4802500c759ff725c8d116b6
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoAdd parameter to detemine client and others 91/267491/4
Suyeon Hwang [Mon, 6 Dec 2021 07:19:24 +0000 (16:19 +0900)]
Add parameter to detemine client and others

Client app does not need to fix configuration, but current code has allowed the client to fix
configuration file. And this behavior makes race condition of configuration. By this problem,
configuration file has invalid value, and it is possible to make side effect.

To solve this problem, this patch adds new parameter to identify client app. By this change,
framework can block the fix from client, and by this behavior, possibility of race condition
would be reduced.

Change-Id: I37d26f78c9d1aa185d4ab22b15a8cd76fb890196
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Add mutex on tts_config_info for thread safety" into tizen_6.5
Sooyeon Kim [Mon, 6 Dec 2021 02:23:51 +0000 (02:23 +0000)]
Merge "Add mutex on tts_config_info for thread safety" into tizen_6.5

2 years agoMerge "Seperate memory of tts_config_info for thread safety" into tizen_6.5
Sooyeon Kim [Mon, 6 Dec 2021 02:23:42 +0000 (02:23 +0000)]
Merge "Seperate memory of tts_config_info for thread safety" into tizen_6.5

2 years agoMake g_synth_control as atomic and Add extra logs 22/267422/3
sooyeon [Fri, 3 Dec 2021 15:59:44 +0000 (00:59 +0900)]
Make g_synth_control as atomic and Add extra logs

Change-Id: I68eda73b4b4c458b4ea17d387def2d6b478eb564
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoAdd mutex on tts_config_info for thread safety 08/267408/1
wn.jang [Fri, 3 Dec 2021 01:25:02 +0000 (10:25 +0900)]
Add mutex on tts_config_info for thread safety

Change-Id: Ia4b9a35c2c15aeb6a419892a9bde072f9455afad

2 years agoSeperate memory of tts_config_info for thread safety 06/267406/1
wn.jang [Fri, 3 Dec 2021 01:15:13 +0000 (10:15 +0900)]
Seperate memory of tts_config_info for thread safety

Change-Id: I15f7802301e03515f5f88081aa73c4e2c83efcdc

2 years agoUpdate version (1.65.15) 81/267281/1 accepted/tizen/6.5/unified/20211205.214036 submit/tizen_6.5/20211202.041353
Suyeon Hwang [Wed, 1 Dec 2021 03:03:04 +0000 (12:03 +0900)]
Update version (1.65.15)

Change-Id: Icac35e6f2dbce38430ffe5bea92e8cf9578681e4
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoSet playing status into vconf 80/267280/1
Suyeon Hwang [Wed, 1 Dec 2021 02:33:35 +0000 (11:33 +0900)]
Set playing status into vconf

Change-Id: I1fb76eb58d87a54516bbf15fcd02ea6829c59f85
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix invalid file pointer access to avoid crash 11/267011/3
Suyeon Hwang [Wed, 24 Nov 2021 05:41:32 +0000 (14:41 +0900)]
Fix invalid file pointer access to avoid crash

Change-Id: I71ce23eb03e181a5157bddbccfe18221e349d01c
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUpdate version (1.65.14) 36/266436/1 accepted/tizen/6.5/unified/20211116.032717 submit/tizen_6.5/20211112.081028 submit/tizen_6.5/20211115.015659
Suyeon Hwang [Fri, 12 Nov 2021 07:49:50 +0000 (16:49 +0900)]
Update version (1.65.14)

Change-Id: I6ad69319e504dd2844712482be6543cb48a93d50
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUpdate version (1.65.14) 37/266437/1 accepted/tizen/unified/20211116.130548 submit/tizen/20211112.081043 submit/tizen/20211115.015644
Suyeon Hwang [Fri, 12 Nov 2021 07:49:50 +0000 (16:49 +0900)]
Update version (1.65.14)

Change-Id: I6ad69319e504dd2844712482be6543cb48a93d50
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge branch 'tizen' into tizen_6.5 32/266432/1
Suyeon Hwang [Fri, 12 Nov 2021 06:56:29 +0000 (15:56 +0900)]
Merge branch 'tizen' into tizen_6.5

Change-Id: I6cbcaa89dad3d71bac077260b98576bb1b542dcd

2 years agoMerge "Match the function hierarchy" into tizen
Wonnam Jang [Thu, 11 Nov 2021 07:58:27 +0000 (07:58 +0000)]
Merge "Match the function hierarchy" into tizen

2 years agoMerge "Send mode to server after prepare success" into tizen
Suyeon Hwang [Thu, 11 Nov 2021 07:48:42 +0000 (07:48 +0000)]
Merge "Send mode to server after prepare success" into tizen

2 years agoSend mode to server after prepare success 77/266377/2
Suyeon Hwang [Thu, 11 Nov 2021 07:19:48 +0000 (16:19 +0900)]
Send mode to server after prepare success

Current code, request set mode message by tidl is trasmitted before prepare is finished. This
behavior makes server stores proper mode information of client, so the policy works wrong way.

This patch makes client request set mode after prepare is finished. And also, this patch unify the
logic to request set mode from both tidl and dbus.

Change-Id: Ifa7201b26c6b6ad9cc206f7e9a4f259757e04702
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMatch the function hierarchy 79/266379/1
wn.jang [Thu, 11 Nov 2021 07:33:24 +0000 (16:33 +0900)]
Match the function hierarchy

Change-Id: Ie7e01227bfe5e790b8ca26c11e894c5482c343e7

2 years agoAdd codes to avoid parse non-xml file 68/266368/3
wn.jang [Thu, 11 Nov 2021 06:00:29 +0000 (15:00 +0900)]
Add codes to avoid parse non-xml file

Change-Id: I25d1f7c13013ed9b9a7ea499709c35d29d715df9

2 years agoUnify TTSD processes into two processes (default, interrupt) 82/265982/6
sooyeon [Wed, 3 Nov 2021 15:40:57 +0000 (00:40 +0900)]
Unify TTSD processes into two processes (default, interrupt)

- To reduce RAM usage, unifying 3 TTSD processes (default, sr, noti) is necessary.
- (server) Add a variable 'mode' into 'app_data_s' in ttsd_data. This is used when ttsd_player checks the current playing_info's mode.
- (client) Make only Default mode TTSD process launched, when client's mode is default/sr/noti.

Change-Id: Iba8c4ff99dd8d5b035c2804148a1b5b0803c4a27
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoUpdate version (1.65.13) 80/265980/1
Suyeon Hwang [Wed, 3 Nov 2021 06:45:03 +0000 (15:45 +0900)]
Update version (1.65.13)

Change-Id: I3145cc0a483d80483118a068cd20e6f9d7a16922
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Invoke register callback once during tts_prepare()" into tizen
Suyeon Hwang [Wed, 3 Nov 2021 06:35:26 +0000 (06:35 +0000)]
Merge "Invoke register callback once during tts_prepare()" into tizen

2 years agoAdd a checker whether quit_loop_timer is carried out or not 22/265922/1
sooyeon [Tue, 2 Nov 2021 10:40:18 +0000 (19:40 +0900)]
Add a checker whether quit_loop_timer is carried out or not

Change-Id: I2b875ea42ef0a9c5e4db1b4707639f3860a2ebc7
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoInvoke register callback once during tts_prepare() 83/265883/2
Suyeon Hwang [Mon, 1 Nov 2021 08:24:55 +0000 (17:24 +0900)]
Invoke register callback once during tts_prepare()

Current code tries to create new notify callback handle every callback register. It is for
matching business logic for dbus. However, server can send message through expired callback handle
by this logic.

This patch makes code create and register callback handle once during tts_prepare().
By this change, server always sends message throught valid callback handle.
However, if registering callback is failed, this logic can not handle the situation.

If the situation occurs, handling code should be required.

Change-Id: I5e88be20ffc84c0ace99e4559440219c21d36089
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUpdate version (1.65.12) 80/265780/1 submit/tizen/20211028.101609
Suyeon Hwang [Thu, 28 Oct 2021 09:11:39 +0000 (18:11 +0900)]
Update version (1.65.12)

Change-Id: I1225545df138622a169d854d79d31c1d82b85e11
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoPrevent destroying rpc handle on rejected callback 68/265768/2
Suyeon Hwang [Thu, 28 Oct 2021 07:30:52 +0000 (16:30 +0900)]
Prevent destroying rpc handle on rejected callback

Change-Id: Ib9027b06aa96f3b5a37748dfdbeb9904d9a4f6f0
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoAdd a state checker to ignore invalid synthesized pcm 86/265486/2
sooyeon [Wed, 20 Oct 2021 19:26:54 +0000 (04:26 +0900)]
Add a state checker to ignore invalid synthesized pcm

Change-Id: Ib0282024e288cede7e557dd00ea5ee0b09f7fe90
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoUse tidl synchronous connect for tts_prepare_sync() 29/265429/2
Suyeon Hwang [Tue, 19 Oct 2021 07:59:05 +0000 (16:59 +0900)]
Use tidl synchronous connect for tts_prepare_sync()

Change-Id: I58652521adaf9bf4faee8225e5998d28bb707a5d
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoCreate new proxy handle when connection is rejected 28/265428/2
Suyeon Hwang [Tue, 19 Oct 2021 04:01:50 +0000 (13:01 +0900)]
Create new proxy handle when connection is rejected

TIDL proxy does not need to try connect repeatedly. And also, if connection is failed by timeout,
app needs to create new proxy handle.

Thus, this patch makes flag variable to check whether connect function is called. Using this flag,
app calls connect function once. And also this patch creates new handle when on_rejected callback
is called to retry connection.

Change-Id: I8a7c26f825e95276e257e77451ffacc7a6722af5
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoCall __change_background_volume in main thread 45/265345/1
sooyeon [Fri, 15 Oct 2021 16:02:08 +0000 (01:02 +0900)]
Call __change_background_volume in main thread

Change-Id: Ia8cd1519285f9b81a3fc7b44b76460c2ab7419c5
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoUpdate version (1.65.11) 25/265325/1
sooyeon [Fri, 15 Oct 2021 12:24:13 +0000 (21:24 +0900)]
Update version (1.65.11)

Change-Id: I53d2455892f61642399dfeb0f690eec9c0770876
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoAdd a checker whether ttse_terminate() is invoked or not 23/265323/2
sooyeon [Fri, 15 Oct 2021 11:19:45 +0000 (20:19 +0900)]
Add a checker whether ttse_terminate() is invoked or not

- When 'ttse_terminate' is invoked, 'ttsd_ipc_close_connection()', 'ttsd_network_finalize()', and ttsd_finalize()' are invoked repeatably.
To avoid this phenomenon, we remove them from 'ttsd_terminate()'.

Change-Id: Ia048cce5f884d4b3fa71f63258caf9e83e43f38d
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoUpdate version (1.65.10) 61/265161/1 submit/tizen/20211012.065801
Suyeon Hwang [Tue, 12 Oct 2021 06:46:51 +0000 (15:46 +0900)]
Update version (1.65.10)

Change-Id: Id21635559542cb203389098cdd6dbe127858c9fa
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoRemove unvalid unit TC 60/265160/1
Suyeon Hwang [Tue, 12 Oct 2021 06:46:08 +0000 (15:46 +0900)]
Remove unvalid unit TC

Change-Id: I81614f409af063baf5cbcc46940e19f2320deae1
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoPrevent audio mixing between each mode 89/264189/3
Suyeon Hwang [Tue, 14 Sep 2021 07:17:06 +0000 (16:17 +0900)]
Prevent audio mixing between each mode

By the change of audio policy, tts have to do not mix the voice of each engine process.

This patch makes all engine process acquire sound focus to send signal to other engine process.
By this change, each engine process can pause or stop the player by policy.

Change-Id: Ica781a49c90e07802f7f8cdb880ab64b0c6db525
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoStart play thread only when 'ttsd_server_play()' is called 88/264188/3
Suyeon Hwang [Mon, 13 Sep 2021 11:18:07 +0000 (20:18 +0900)]
Start play thread only when 'ttsd_server_play()' is called

Previous code calls 'ttsd_player_play()' repeatedly when 'ttsd_send_result()' is called.
This logic can skip the stop request by player policy, so this patch changes the logic.

By this patch 'ttsd_player_play()' is only called when 'ttsd_server_play()' is called.

Change-Id: I8b1cfa888fc9049c7b17bf900f728eaa6062819f
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoRemove unvaluable deadcode by changing function prototype 30/264930/2
Suyeon Hwang [Tue, 28 Sep 2021 04:07:50 +0000 (13:07 +0900)]
Remove unvaluable deadcode by changing function prototype

Change-Id: I26fbd60f320ab8d0bb5452cb7246d9e37bc80361
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoClean up mixing policy code 87/264187/3
Suyeon Hwang [Wed, 8 Sep 2021 01:02:36 +0000 (10:02 +0900)]
Clean up mixing policy code

To fix the policy, this patch refactors the code which handles the policy.
By this patch, readability of the code will be enhanced and it will help to fix the policy.

Change-Id: I024e33e537fc013feaffbfa64a8bb245f12a2e4b
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Fix implementation related to TIDL" into tizen
Suyeon Hwang [Tue, 12 Oct 2021 05:27:38 +0000 (05:27 +0000)]
Merge "Fix implementation related to TIDL" into tizen

2 years agoAdd dummy value when null parameter is used 70/265070/1
Suyeon Hwang [Fri, 8 Oct 2021 06:42:57 +0000 (15:42 +0900)]
Add dummy value when null parameter is used

Change-Id: Id39e6689460acb7c5fb1fffb96524e90d8548924
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix implementation related to TIDL 69/263169/5
Hwankyu Jhun [Fri, 27 Aug 2021 06:32:36 +0000 (15:32 +0900)]
Fix implementation related to TIDL

APIs that are generated by tidlc are changed.

Requires:
 - https://review.tizen.org/gerrit/#/c/platform/core/appfw/tidl/+/263601/

Change-Id: I39d19db04b43d8f06fd73f56f68452be8d6d1173
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
2 years agoFix memory leak when remove item from g_list 64/264864/1
Suyeon Hwang [Fri, 1 Oct 2021 08:53:08 +0000 (17:53 +0900)]
Fix memory leak when remove item from g_list

Change-Id: I50f3d8a152982393f5eff313a7ab31cd45fb52b6
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoReorder mutex to prevent deadlock 93/264793/1 submit/tizen/20210930.015514
Suyeon Hwang [Thu, 30 Sep 2021 01:44:37 +0000 (10:44 +0900)]
Reorder mutex to prevent deadlock

Change-Id: Iecb2765a2362d7f3407a26c4e3399fff0fe10f57
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUpdate version (1.65.9) 67/264767/1 submit/tizen/20210929.093305
Suyeon Hwang [Wed, 29 Sep 2021 09:27:24 +0000 (18:27 +0900)]
Update version (1.65.9)

Change-Id: Ie30ce1687d9be895a4ebf76cb0efd6c073a143d0
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Add mutex to prevent race condition of g_playing_info" into tizen
Suyeon Hwang [Wed, 29 Sep 2021 09:18:50 +0000 (09:18 +0000)]
Merge "Add mutex to prevent race condition of g_playing_info" into tizen

2 years agoMake new function for tidl to match ttsd_ipc interface 24/264724/2
Suyeon Hwang [Wed, 29 Sep 2021 02:42:07 +0000 (11:42 +0900)]
Make new function for tidl to match ttsd_ipc interface

Change-Id: I2bc1ea73f5f3041cebe7c833a2ae38d4b8775eaf
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMake ipc method name more specific 23/264723/1
Suyeon Hwang [Wed, 29 Sep 2021 02:26:42 +0000 (11:26 +0900)]
Make ipc method name more specific

Change-Id: Iff46d2653dbadfe8ed5de389166020912aaed2e3
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoChange function name to identify ipc method 22/264722/1
Suyeon Hwang [Wed, 29 Sep 2021 02:14:47 +0000 (11:14 +0900)]
Change function name to identify ipc method

Change-Id: I38c9157aba9b131825057d07f67a1f3a60cc5270
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoAdd mutex to prevent race condition of g_playing_info 72/264672/1
Suyeon Hwang [Tue, 28 Sep 2021 05:53:40 +0000 (14:53 +0900)]
Add mutex to prevent race condition of g_playing_info

Change-Id: I380fb2b7bd9b514f879952e1c0a0508f21bcfa16
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoUpdate version (1.65.8) 38/264638/1 accepted/tizen/6.5/unified/20211028.122529 accepted/tizen/unified/20210928.125345 submit/fixVD/20210927.111930 submit/tizen/20210927.112041 submit/tizen_6.5/20211028.163101 tizen_6.5.m2_release
Suyeon Hwang [Mon, 27 Sep 2021 11:17:20 +0000 (20:17 +0900)]
Update version (1.65.8)

Change-Id: If0e0638521c95958b07dbcadd4b6af5a05f42014
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoAdd and delete timer on main thread for safe handling 36/264536/2
Suyeon Hwang [Fri, 24 Sep 2021 06:26:26 +0000 (15:26 +0900)]
Add and delete timer on main thread for safe handling

Change-Id: I8eb75373d4c23d846fe8035bd6b9bc84f79c162c
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix order of checking condition for screen reader 84/264584/1
Suyeon Hwang [Mon, 27 Sep 2021 01:39:54 +0000 (10:39 +0900)]
Fix order of checking condition for screen reader

Change-Id: Ifcf74312c89105474ca0281b75ff91c1951681db
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Fix typo error" into tizen
Sooyeon Kim [Fri, 24 Sep 2021 02:36:03 +0000 (02:36 +0000)]
Merge "Fix typo error" into tizen

2 years agoFix typo error 24/264524/1
sooyeon [Fri, 24 Sep 2021 11:02:17 +0000 (20:02 +0900)]
Fix typo error

Change-Id: I65d0ca07ee6329553d91fa772e7f34ee03bed454
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
2 years agoMerge "Handle already_initialize error properly not ignored" into tizen
Suyeon Hwang [Fri, 24 Sep 2021 02:10:53 +0000 (02:10 +0000)]
Merge "Handle already_initialize error properly not ignored" into tizen

2 years agoHandle already_initialize error properly not ignored 06/264506/1
Suyeon Hwang [Thu, 23 Sep 2021 11:47:12 +0000 (20:47 +0900)]
Handle already_initialize error properly not ignored

Change-Id: Ib42f2750757371c74df1463ac8ba6ed738dc0847
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoRemove retval description not generated by this function 25/264325/1
Suyeon Hwang [Thu, 16 Sep 2021 05:08:12 +0000 (14:08 +0900)]
Remove retval description not generated by this function

Change-Id: Ifc99620f16c6cadb577659279297051470aa5961
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoFix config file matched with default engine 10/264210/1 accepted/tizen/unified/20210915.001815 submit/tizen/20210914.213650
Suyeon Hwang [Tue, 14 Sep 2021 12:02:55 +0000 (21:02 +0900)]
Fix config file matched with default engine

Change-Id: Iec1c9664c42c36e199612fc814a2654d161f8639
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
2 years agoMerge "Use generated tidl codes" into tizen accepted/tizen/unified/20210908.131709 submit/tizen/20210907.042858
Sooyeon Kim [Tue, 7 Sep 2021 08:39:52 +0000 (08:39 +0000)]
Merge "Use generated tidl codes" into tizen

2 years agoComment out codes to duck system sound 29/263629/1
sooyeon [Tue, 7 Sep 2021 15:56:41 +0000 (00:56 +0900)]
Comment out codes to duck system sound

Change-Id: Id8274794fac89559f01c06802d307b7adf6b306b
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>