[Samsung Galaxy S8 Themes, Apps, and Mods] SypeR_:
Hi [MENTION=4170211]ImbaWind[/MENTION] ,

I'm trying to port your Dolby Atmos port project on Note 4 Exynos Nougat project. I made it manually everything, but Dolby Effects didn't worked. I'm ported required Dolby .smali's to my framework. Anyway, here is my SAEffect logs.

<<< log_count = 82 >>>
[07-19 02:32:28.836 3102:3102 D/AudioSAEffectSecPlus]
EffectCreate - Allocating SessionNo 0 for SessionId -5

[07-19 02:32:28.836 3102:3102 D/AudioSAEffectSecPlus]
EffectCreate - This is the first effect in current sessionId -5 sessionNo 0

[07-19 02:32:28.836 3102:3102 D/AudioSAEffectSecPlus]
AudioSAEffectSec::AudioSAEffectSec ctor

[07-19 02:32:28.836 3102:3102 D/AudioSAEffectSecPlus]
AudioSAEffectSec::createSA

[07-19 02:32:28.836 3102:3102 D/AudioSAEffectSecPlus]
AudioSAEffectSec::createSA(0xada24980)

[07-19 02:32:28.837 3102:3102 I/AudioSAEffectSecPlus]
EFFECT_CMD_INIT mTrackChannel = 2, mThreadChannel = 2 mTrackFormat = 0x1

[07-19 02:34:42.420 12033:12033 D/SAEffectManager]
*****getNewSoundAliveInstance start*****

[07-19 02:34:42.441 12033:12033 D/SAEffectManager]
*****newSoundAliveEffect create Sucessfully*****

[07-19 02:34:42.441 12033:12033 D/SAEffectManager]
*****getNewSoundAliveInstance end****

[07-19 02:34:42.441 12033:12033 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:34:42.445 12033:12033 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:34:42.446 12033:12033 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:34:42.448 12033:12033 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:34:42.450 12033:12033 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:34:42.452 12033:12033 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:34:42.452 12033:12033 D/SAEffectManager]
*****updateSquareUIsetting()*****

[07-19 02:34:42.452 12033:12033 D/SAEffectManager]
position: 40

[07-19 02:34:42.453 12033:12033 D/SAEffectManager]
*****convPresetIndexToGenreIndex()***** presetIndex : 0 genreIndex : 0

[07-19 02:34:42.462 12033:12033 D/SAEffectManager]
set UHQ-Upscaler as : 0

[07-19 02:34:42.987 12033:12033 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:34:42.989 12033:12033 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:35.705 15111:15111 D/SAEffectManager]
*****getNewSoundAliveInstance start*****

[07-19 02:35:35.738 15111:15111 D/SAEffectManager]
*****newSoundAliveEffect create Sucessfully*****

[07-19 02:35:35.738 15111:15111 D/SAEffectManager]
*****getNewSoundAliveInstance end****

[07-19 02:35:35.738 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:35.739 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:35.740 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:35.741 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:35.751 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:35.752 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:35.752 15111:15111 D/SAEffectManager]
*****updateSquareUIsetting()*****

[07-19 02:35:35.752 15111:15111 D/SAEffectManager]
position: 40

[07-19 02:35:35.753 15111:15111 D/SAEffectManager]
*****convPresetIndexToGenreIndex()***** presetIndex : 0 genreIndex : 0

[07-19 02:35:35.759 15111:15111 D/SAEffectManager]
set UHQ-Upscaler as : 0

[07-19 02:35:36.287 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:36.289 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:43.866 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:43.868 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:43.876 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:43.877 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:43.877 15111:15111 D/SAEffectManager]
*****updateSquareUIsetting()*****

[07-19 02:35:43.877 15111:15111 D/SAEffectManager]
position: 40

[07-19 02:35:43.878 15111:15111 D/SAEffectManager]
*****convPresetIndexToGenreIndex()***** presetIndex : 0 genreIndex : 0

[07-19 02:35:43.884 15111:15111 D/SAEffectManager]
set UHQ-Upscaler as : 0

[07-19 02:35:44.266 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:44.267 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:44.273 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:44.274 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:44.274 15111:15111 D/SAEffectManager]
*****updateSquareUIsetting()*****

[07-19 02:35:44.274 15111:15111 D/SAEffectManager]
position: 40

[07-19 02:35:44.275 15111:15111 D/SAEffectManager]
*****convPresetIndexToGenreIndex()***** presetIndex : 0 genreIndex : 0

[07-19 02:35:44.278 15111:15111 D/SAEffectManager]
set UHQ-Upscaler as : 0

[07-19 02:35:44.392 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:44.393 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:35:44.787 15111:15111 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:35:44.788 15111:15111 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:45:55.244 23757:23757 D/SAEffectManager]
*****getNewSoundAliveInstance start*****

[07-19 02:45:55.258 23757:23757 D/SAEffectManager]
*****newSoundAliveEffect create Sucessfully*****

[07-19 02:45:55.258 23757:23757 D/SAEffectManager]
*****getNewSoundAliveInstance end****

[07-19 02:45:55.258 23757:23757 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:45:55.260 23757:23757 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:45:55.260 23757:23757 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:45:55.261 23757:23757 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:45:55.397 23757:23757 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:45:55.398 23757:23757 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:45:55.398 23757:23757 D/SAEffectManager]
*****updateSquareUIsetting()*****

[07-19 02:45:55.398 23757:23757 D/SAEffectManager]
position: 40

[07-19 02:45:55.398 23757:23757 D/SAEffectManager]
*****convPresetIndexToGenreIndex()***** presetIndex : 0 genreIndex : 0

[07-19 02:45:55.402 23757:23757 D/SAEffectManager]
set UHQ-Upscaler as : 0

[07-19 02:45:55.410 23757:23757 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:45:55.410 23757:23757 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:45:55.410 23757:23757 D/SAEffectManager]
*****updateSquareUIsetting()*****

[07-19 02:45:55.410 23757:23757 D/SAEffectManager]
position: 40

[07-19 02:45:55.410 23757:23757 D/SAEffectManager]
*****convPresetIndexToGenreIndex()***** presetIndex : 0 genreIndex : 0

[07-19 02:45:55.412 23757:23757 D/SAEffectManager]
set UHQ-Upscaler as : 0

[07-19 02:45:55.418 23757:23757 D/SAEffectManager]
*****convPresetIndexToGenreIndex()***** presetIndex : 0 genreIndex : 0

[07-19 02:45:55.943 23757:23757 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:45:55.944 23757:23757 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:45:55.944 23757:23757 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:45:55.946 23757:23757 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

[07-19 02:45:56.636 23757:23757 D/SAEffectManager]
*****getNewDolbyInstance start*****

[07-19 02:45:56.637 23757:23757 E/SAEffectManager]
getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19

As you can see, Dolby cant find the "46d279d9-9be7-453d-9d7c-ef937f675587" UUID. After that, i checked my SemDolbyAudioEffect.smali and i think found the right UUID.

# direct methods
.method static constructor <clinit>()V
.registers 2

.line 48
[B]const-string v0, "46d279d9-9be7-453d-9d7c-ef937f675587"[/B]

.line 49
invoke-static {v0}, Ljava/util/UUID;->fromString(Ljava/lang/String;)Ljava/util/UUID;

move-result-object v0

sput-object v0, Landroid/media/audiofx/SemDolbyAudioEffect;->EFFECT_TYPE_DOLBY_AUDIO_PROCESSING:Ljava/util/UUID;

and i set your AudioEffects.config as

# Dolby AudioEffect
dap {
library dap
#uuid 9d4921da-8225-4f29-aefa-39537a04bcaa
uuid [B]46d279d9-9be7-453d-9d7c-ef937f675587[/B]
}

but still i got the same error (getNewDolbyInstance::RuntimeExceptionn - e : java.lang.RuntimeException: Cannot initialize effect engine for type: 46d279d9-9be7-453d-9d7c-ef937f675587 Error: -19)

Do you have a any idea about how can i fix it? Also thank you for such a like this guide. :good: