[MOD][FIX][July/09/2016] OnePlus 3 Audio Mods

Search This thread

chdloc

Senior Member
Jul 19, 2010
1,140
1,724
Can confirm this, the default audio route used to record audio in camcorder is audio-record, rather than handset-stereo-dmic-ef, resulting with crappy, muffled audio:

Code:
<snip>
07-09 20:35:21.416  2762 18471 I msm8974_platform: platform_set_codec_backend_cfg:becf: afe: bitwidth 16, samplerate 48000 channels 2 format 0, backend_idx 7 device (handset-stereo-dmic-ef)
07-09 20:35:21.416  2762 18471 D audio_hw_primary: check_usecases_capture_codec_backend:becf: force routing 0
07-09 20:35:21.416  2762 18471 D hardware_info: hw_info_append_hw_type : device_name = handset-stereo-dmic-ef
07-09 20:35:21.416  2762 18471 D msm8974_platform: platform_split_snd_device: snd_device(115) num devices(0) new_snd_devices(0)
07-09 20:35:21.416  2762 18471 D audio_hw_primary: enable_snd_device: snd_device(115: handset-stereo-dmic-ef)
<snip>
The audio route selected is, indeed, audio-record, and the audio device used is handset-stereo-dmic-ef.
This has apparently changed from speaker-stereo-dmic-ef audio device used previously. At a very minimum, audio_platform_info.xml would have to be modified to reflect that change. I would start adding the following lines between the <acdb_ids> tags:
Code:
<device name="SND_DEVICE_IN_HANDSET_STEREO_DMIC_EF" acdb_id="69"/>
<device name="SND_DEVICE_IN_HANDSET_STEREO_DMIC" acdb_id="69"/>
Reboot after making those changes, or change the installer directly.
It is possible that you may need to change the acdb_id from 69 to something else (via trial-and-error) to get a clean audio signal back.
 

FullWipe

Senior Member
Jul 3, 2014
943
1,996
Milano
@chdloc

I have the same problem....the recorded audio is completely distorted, especially during a concert.
(My girlfriend has the iphone and the recorded audio is perfect without distortion even in a concert).

Could you give a practical example of the change to be made please?
This is my audio_platform_info.xml file
(op3t with Oreo Resurrection Remix).

<audio_platform_info>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="15"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED" acdb_id="124"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER" acdb_id="15" />
</acdb_ids>
<bit_width_configs>
<device name="SND_DEVICE_OUT_SPEAKER" bit_width="24"/>
</bit_width_configs>
<config_params>
<param key="spkr_1_tz_name" value="wsatz.11"/>
<param key="spkr_2_tz_name" value="wsatz.12"/>
<!-- In the below value string, first parameter indicates size -->
<!-- followed by perf lock options -->
<param key="perf_lock_opts" value="2, 0x101, 0x20F"/>
<param key="native_audio_mode" value="src"/>
<param key="input_mic_max_count" value="4"/>
</config_params>
<backend_names>
<device name="SND_DEVICE_OUT_HEADPHONES" backend="headphones" interface="SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_LINE" backend="headphones" interface="SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_ANC_HEADSET" backend="headphones" interface="SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_HEADPHONES" backend="speaker-and-headphones" interface="SLIMBUS_0_RX-and-SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_LINE" backend="speaker-and-headphones" interface="SLIMBUS_0_RX-and-SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_SPEAKER_AND_ANC_HEADSET" backend="speaker-and-headphones" interface="SLIMBUS_0_RX-and-SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_VOICE_HEADPHONES" backend="headphones" interface="SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_VOICE_ANC_HEADSET" backend="headphones" interface="SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_VOICE_LINE" backend="headphones" interface="SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_VOICE_TTY_FULL_HEADPHONES" backend="headphones" interface="SLIMBUS_6_RX"/>
<device name="SND_DEVICE_OUT_VOICE_TTY_VCO_HEADPHONES" backend="headphones" interface="SLIMBUS_6_RX"/>

<device name="SND_DEVICE_OUT_SPEAKER" backend="quat_i2s"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER" backend="quat_i2s"/>
</backend_names>
<pcm_ids>
<usecase name="USECASE_AUDIO_RECORD_LOW_LATENCY" type="in" id="19" />
<usecase name="USECASE_AUDIO_PLAYBACK_ULL" type="out" id="19" />
</pcm_ids>
</audio_platform_info>


Thank you :)
 

chdloc

Senior Member
Jul 19, 2010
1,140
1,724
@chdloc
I have the same problem....the recorded audio is completely distorted, especially during a concert.
(My girlfriend has the iphone and the recorded audio is perfect without distortion even in a concert).
It is not quite clear from your description whether you are referring to distortions due to the noise suppression algorithm employed or due to the microphones clipping with loud incoming sounds.
You can disable noise suppression by doing what I suggested three posts above this one. In your case, replace
Code:
<audio_platform_info>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="15"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED" acdb_id="124"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER" acdb_id="15" />
</acdb_ids>
{snip}
by
Code:
<audio_platform_info>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="15"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED" acdb_id="124"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER" acdb_id="15" />
<device name="SND_DEVICE_IN_HANDSET_STEREO_DMIC_EF" acdb_id="69"/>
<device name="SND_DEVICE_IN_HANDSET_STEREO_DMIC" acdb_id="69"/>
</acdb_ids>
{snip}
and reboot. This assumes that the camcorder uses the "handset-stereo-dmic" or "handset-stereo-dmic-ef" device, which you can look for in logcat while shooting a video.

If your microphone is clipping during a concert, the only thing you can do is to lower the microphone gain in the mixer. A satisfactory solution to this problem is very complicated.

I'd start by trying to get rid of noise suppression first and see how the audio comes out in a concert environment.
 
  • Like
Reactions: FullWipe

FullWipe

Senior Member
Jul 3, 2014
943
1,996
Milano
It is not quite clear from your description whether you are referring to distortions due to the noise suppression algorithm employed or due to the microphones clipping with loud incoming sounds.

I suppose with this video it's clearer what i mean and maybe your help could be even more focused :)


As you can listen, it's impossible to record a good sound during a concert......It's really crap :(

TIA :good:

edit: This is logcat...
Screenshot_Nova_Launcher_20180711-170813.png
 
Last edited:

chdloc

Senior Member
Jul 19, 2010
1,140
1,724
I suppose with this video it's clearer what i mean and maybe your help could be even more focused :)
https://www.youtube.com/watch?v=95Yi6oSWa-g&feature=youtu.be

As you can listen, it's impossible to record a good sound during a concert......It's really crap :(
The YouTube link does not work for me, but your playback device is different from the previous poster.
Try replacing
Code:
<audio_platform_info>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="15"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED" acdb_id="124"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER" acdb_id="15" />
</acdb_ids>
{snip}
with
Code:
<audio_platform_info>
<acdb_ids>
<device name="SND_DEVICE_OUT_SPEAKER" acdb_id="15"/>
<device name="SND_DEVICE_OUT_SPEAKER_PROTECTED" acdb_id="124"/>
<device name="SND_DEVICE_OUT_VOICE_SPEAKER" acdb_id="15" />
[COLOR="Red"]<device name="SND_DEVICE_IN_HANDSET_MIC" acdb_id="69"/>[/COLOR]
</acdb_ids>
{snip}
and reboot. You may have to play around with the device id (acdb_id). If 69 does not improve the audio quality try 62. If that does not work, either, you will have to revert to trial-and-error. Note that you will have to reboot your phone every time you make a change (or re-install the mod with the new value).
 
  • Like
Reactions: FullWipe

FullWipe

Senior Member
Jul 3, 2014
943
1,996
Milano
The YouTube link does not work for me

Try now please :)

EDIT: Another question....if i wanted to increase the bluetooth volume?
The latest Resurrection Remix versions have greatly decreased the Bluetooth volume and i would like to bring it back to an acceptable volume.
 
Last edited:

chdloc

Senior Member
Jul 19, 2010
1,140
1,724
There is a lot of clipping, so the microphone gain is too high. It is hard to say whether there is also distortion due to excessive noise suppression.

EDIT: Another question....if i wanted to increase the bluetooth volume?
The latest Resurrection Remix versions have greatly decreased the Bluetooth volume and i would like to bring it back to an acceptable volume.
I have never played with Bluetooth audio and I have not run across a settings file in /system or /vendor that would allow for Bluetooth gain adjustment.
You may need to dig into the Android sources.

This in combination with the microphone clipping issue would have me look at switching ROMs, depending of course how important audio is to you.
I do not have (and never had) a OnePlus device, so I cannot comment on what you might want to try.
 
  • Like
Reactions: FullWipe

FullWipe

Senior Member
Jul 3, 2014
943
1,996
Milano
@chdloc I tried to set 69 then 62 or 50 and reduced microphone gain through EX kernel as well. Nothing change....recorded sound clipping like hell during a concert or in a presence of strong bass. It's very difficult to find a solution to this annoying issue.
I will try to change value but i think there's no solution due to hardware limitations.

If someone has found a solution, please share it. Thanks

Mentioning for attention @abhi08638

EDIT: if i wanted to completely disable NS, which value i need to set? 0?
 
Last edited:

chdloc

Senior Member
Jul 19, 2010
1,140
1,724
@chdloc I tried to set 69 then 62 or 50 and reduced microphone gain through EX kernel as well. Nothing change....recorded sound clipping like hell during a concert or in a presence of strong bass. It's very difficult to find a solution to this annoying issue.
I will try to change value but i think there's no solution due to hardware limitations.

If someone has found a solution, please share it. Thanks

Mentioning for attention @abhi08638

EDIT: if i wanted to completely disable NS, which value i need to set? 0?

As the ACDB values are undocumented, there is no way to find out other than trial-and-error.
I would suggest two things:
  1. to find out whether we are really dealing with a noise suppression issue, make a recording of running water (fountain, kitchen or bathroom sink, etc) and share the recording
  2. ask others in this thread whether they are experiencing the same issue(s) and consider switching ROMs if they don't
 

Markster93

Senior Member
Feb 10, 2011
59
13
Erchie (BR) / Bari
@chdloc I tried to set 69 then 62 or 50 and reduced microphone gain through EX kernel as well. Nothing change....recorded sound clipping like hell during a concert or in a presence of strong bass. It's very difficult to find a solution to this annoying issue.
I will try to change value but i think there's no solution due to hardware limitations.

If someone has found a solution, please share it. Thanks

Mentioning for attention @abhi08638

EDIT: if i wanted to completely disable NS, which value i need to set? 0?

Ciao FullWipe, hai mai risolto il tuo problema con l'eccessivo rumore nell'audio dei video registrati con il OnePlus 3/3T? Ho lo stesso identico problema e non so come risolverlo.
(Hi FullWipe, have you ever solved your problem with the extreme noise in the audio from the clips recorded with your OnePlus 3/3T? I have the same problem and I don't know how to solve it.)
 

gps3dx

Senior Member
Jan 24, 2010
792
401
HTC Desire
Samsung Galaxy Tab 10.1
Guys if you want dual mono speaker mod do it the DIY method. Please notice that the provided mixer_paths_tasha.xml in the flashable zip has very different file size compared to the file found in your rom.
Your stock mixer path file will either be in /system/etc or /vendor/etc.
Been doing this on lineage 14.1, omni oreo & now on sultanxda's los and never faced any issue.

Much obliged !
Indeed doing the manual guide from the OP on my RR Oreo (8.1) for getting the "Mono Surround Sound
" - IS WORKING.
few notes: vs Nougat, on RR oreo mixer_path_tasha.xml is indeed under '/system/vendor/etc/'.
the other note is that one I performed the mod, I have to restart the UI after each full restart - not a big deal to me, as this happened as well after I made the mod on RR nougat.

Thanks !
 

FullWipe

Senior Member
Jul 3, 2014
943
1,996
Milano
Tried flashing the mono surround sound in TWRP and get error 1
Extract the mixer_paths_tasha.xml file from the zip, copy it manually in the path system/vendor/etc using a file manager and reboot. That's it.

Before copying the new xml file, i suggest you to rename the original one in mixer_paths_tasha.xml.old

If you will stuck in a bootloop, reboot in recovery, delete the new xml through TWRP file manager, rename the old one by removing .old and reboot.
 

fmasiglat

Member
Nov 2, 2018
7
4
Need help understanding the acdb_id and DEC volumes

I have made progress in being able to adjust the volume input while recording using the Video camera - after tweaking the system files.

I am still using the trial and error method. And, I am hoping to post my progress soon so other people can benefit too. I am doing bass test and actual sound test and analysis of wave forms too.

However, I need help in understanding the ff:
- What are the acdb_ids? What does it mean and do specifically? What are the values? I used it in tweaking the 'audio_platform_info' but I do not understand what it does.

- What are the DEC1 to DEC10 Volume/s? What do they mean & do and what are their range of values? I used them also for the 'mixer_paths_tasha.xml' but I want to optimize my use of it? Are they referring to equalizer bands?

I will appreciate your help a lot. Please, I would like to understand it.
 
  • Like
Reactions: weriwd

fmasiglat

Member
Nov 2, 2018
7
4
Hello, I would just like to share what I have used to fix the audio in my OnePlus 3T with Oxygen OS 5.0.6. The main issue is when I go to concerts or in the presence of loud bass the phone cannot record anything - I have solved by modifying only the mixer_paths_tasha.xml which can be found in vendor/etc.

I will highlight the lines of code I added in BLUE below:

Code:
    <path name="speaker-stereo-dmic-ef">
        <path name="speaker-dmic-endfire" />
<!-- #ifdef VENDOR_EDIT -->
<!-- /*zhiguang.su@MultiMedia.AudioDrv , 2016/04/19, mic power high level mode and add adc volume*/  -->
		<ctl name="ADC4 Volume" value="11" />
        <ctl name="ADC5 Volume" value="11" />
        <ctl name="AMIC_3_4 PWR MODE" value="HIGH_PERF" />
        <ctl name="AMIC_5_6 PWR MODE" value="HIGH_PERF" />
<!-- #endif -->
	[COLOR="blue"][B]<ctl name="DEC4 Volume" value="69" />
        <ctl name="DEC5 Volume" value="69" />
[/B][/COLOR] 
</path>

<!-- #ifdef VENDOR_EDIT -->
<!--  [lifei][Multimedia] , 5/7/2017, for recoder stereo control -->
    <path name="speaker-stereo-dmic-ef-other">
        <ctl name="AIF1_CAP Mixer SLIM TX4" value="1"/>
        <ctl name="AIF1_CAP Mixer SLIM TX5" value="1"/>
        <ctl name="SLIM TX5 MUX" value="DEC5" />
        <ctl name="ADC MUX5" value="AMIC" />
[B][COLOR="blue"]        <!--<ctl name="AMIC MUX5" value="ADC4" />-->
	<ctl name="AMIC MUX5" value="ADC5" />[/COLOR][/B]
        <ctl name="SLIM TX4 MUX" value="DEC4" />
        <ctl name="ADC MUX4" value="AMIC" />
	[COLOR="blue"][B]<!--<ctl name="AMIC MUX4" value="ADC5" />-->
        <ctl name="AMIC MUX4" value="ADC4" />[/B][/COLOR]
        <ctl name="SLIM_0_TX Channels" value="Two" />
<!-- #ifdef VENDOR_EDIT -->
<!-- /*zhiguang.su@MultiMedia.AudioDrv , 2016/04/19, mic power high level mode and add adc volume*/  -->
        <ctl name="ADC4 Volume" value="11" />
        <ctl name="ADC5 Volume" value="11" />
        <ctl name="AMIC_3_4 PWR MODE" value="HIGH_PERF" />
        <ctl name="AMIC_5_6 PWR MODE" value="HIGH_PERF" />
	[COLOR="blue"][B]<ctl name="DEC4 Volume" value="69" />
        <ctl name="DEC5 Volume" value="69" />							   [/B][/COLOR]
<!-- #endif -->
    </path>
<!-- #endif -->

This is all that I changed in the said file. Just make sure to reset your phone to have the changes take effect.

I hope this helps. :good:
 

FullWipe

Senior Member
Jul 3, 2014
943
1,996
Milano
I would just like to share what I have used to fix the audio in my OnePlus 3T with Oxygen OS 5.0.6.

Hi mate, thanks for sharing :good:

I tried to edit the mixer_paths_tasha.xml file of my rom (Resurrection Remix) but i can not find some strings.
If i attach the file could you help me to solve this problem that has afflicted my phone for a long time?

Thank you very much!
 

Attachments

  • mixer_paths_tasha.xml
    105.7 KB · Views: 34

fmasiglat

Member
Nov 2, 2018
7
4
Hi mate, thanks for sharing :good:

I tried to edit the mixer_paths_tasha.xml file of my rom (Resurrection Remix) but i can not find some strings.
If i attach the file could you help me to solve this problem that has afflicted my phone for a long time?

Thank you very much!

I checked your "mixer_paths_tasha.xml" file and it seems we really have different lines. But, here's the section which I think might help - I added the ones in blue.

Code:
	<path name="speaker-stereo-dmic-ef">
		<path name="speaker-dmic-endfire"/>
		<!--  #ifdef VENDOR_EDIT  -->
		<!--
 /*zhiguang.su@MultiMedia.AudioDrv , 2016/04/19, mic power high level mode and add adc volume*/  
-->
		<ctl name="ADC4 Volume" value="11"/>
		<ctl name="ADC5 Volume" value="11"/>
		<ctl name="AMIC_3_4 PWR MODE" value="HIGH_PERF"/>
		<ctl name="AMIC_5_6 PWR MODE" value="HIGH_PERF"/>
		<!--  #endif  -->
                [COLOR="Blue"]<ctl name="DEC4 Volume" value="69" />
                <ctl name="DEC5 Volume" value="69" />[/COLOR]		
	</path>

Please do reboot after making the change. And, test it with some big speaker and loud bass or anything that may replicate concert sounds - to see if it has any effect.

However, if that does not do the trick. I suggest maybe you can try using Logcat while trying to record a video on your phone and check what device id's are used by your phone for that task. (Note: Please filter it already on your own since it will be long) Then, perhaps I can try helping you a bit more. :good:
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 44
    ** Added Mono + Disable Camera NS

    What is this?
    This post is a collection of all the audio related mods I have created from the OnePlus 3. The mods so far are: Mono surround sound, Camcorder Mic Gain, Cam Mic Gain plus Mono Surround sound, and various Camera recording tests. The cam disable NS is the latest for fixing the noise suppression on video recordings. If you have a request, then make it here and I'll try to make it if I can.

    Various Mod Explanations

    What is it?***Mono Surround***

    This mod will activate you front earpiece speaker in conjunction with the bottom main speaker any time Speaker mode is used for example playing music, watching movies, shows, you tube and so on, creating an almost surround sound type of effect. This will not effect notifications because that is a different setting that I don't really care about.

    Mono Surround Sound
    This version plays all audio through one channel. This basically means that you now have 2 mono speakers. Fair Warning, I find the sound very underwhelming. WARNING: MESSING WITH YOUR EQ WILL ALSO EFFECT THE EARPIECE. IT COULD POTENTIALLY BLOW IT OUT IF YOU INCREASE THE VOLUME OR BASS TOO MUCH

    Camcorder Mic Gain
    This version increases the microphone gain for the audio recorded through the camcorder only. I did this as a workaround for the way too aggressive noise cancellation that happens. This won't fix the problem but hopefully make it more bearable. If I find a better way to fix this, I will update this mod.

    Camcorder Mic Fix Test 1
    This version uses a different stereo microphone path to record audio for the camcorder. This is a test and I don't know if it's better than stock or not. Please test and use the poll so I can see if its working or not

    Camcorder Disable NS v4
    V1: This version attempts to disable the noise suppression for the camcorder in the audio_platform_info.xml.
    V2: It also increases the mic gain by 12db for the camcorder only on CM
    V3: switches to stereo recording for CM
    V4: Increases gain for OOS by 12 db


    Prerequisites and installation instructions
    • MUST be rooted
    • MUST be on CM (OOS is untested)
    • MUST have TWRP installed
    • Flash one of the zips below
    • reboot

    This mod modifies the mixer_path_tasha.xml in the /system/etc folder. I have only tested this on CM13. I don't guarantee it will work for your rom, because this is based off Blisspop rom. Although the worst that'll happen is you'll lose sound and mic. If you do lose sound, flash the revert zip to restore your original file. In a worst case scenario where you messed up the permissions and are in a bootloop, dirty flash your rom.

    DIY
    Background:
    OnePlus is using deep buffering for their audio processing to conserve battery life. If you want to disable deep buffering, go to your build.prop and edit this line to false
    Note: Changing this will change the sound mapping in the mixer_paths_tasha
    Code:
    audio.deep_buffer.media=true

    audio_platform_info.xml
    Speaker is referenced as "quat_i2s" with the interface "SLIMBUS_0_RX"

    mixer_paths_tasha.xml
    Audio playback for music
    Code:
    <path name="deep-buffer-playback quat_i2s">
             <ctl name="QUAT_MI2S_RX Audio Mixer MultiMedia1" value="1" />
    </path>

    Audio playback for notifications
    Code:
    <path name="low-latency-playback quat_i2s">
            <ctl name="QUAT_MI2S_RX Audio Mixer MultiMedia5" value="1" />
    </path>

    Note: If deep buffering is enabled, all sound will go through the low latency playback path.

    Mono Surround Sound
    Code:
    <path name="deep-buffer-playback quat_i2s">
            <ctl name="SLIMBUS_0_RX Audio Mixer MultiMedia1" value="1" />
            <ctl name="SLIM RX0 MUX" value="AIF_MIX1_PB" />
            <ctl name="SLIM_0_RX Channels" value="One" />
            <ctl name="RX INT0_1 MIX1 INP0" value="RX0" />
            <ctl name="RX INT0 DEM MUX" value="CLSH_DSM_OUT" />
            <ctl name="EAR PA Gain" value="G_8_DB" />
            <ctl name="RX0 Digital Volume" value="95" />
            <ctl name="QUAT_MI2S_RX Audio Mixer MultiMedia1" value="1" />
    </path>
    To change the volume of the earpiece for audio playback, change RX0 Digital Volume to a value from 1 to 128. Anything above 95 might be dangerous

    To disable the speaker and only use the earpiece for audio playback, delete the line <ctl name="QUAT_MI2S_RX Audio Mixer MultiMedia1" value="1" />

    Earpiece Volume
    Code:
    <path name="handset">
            <ctl name="SLIM RX0 MUX" value="AIF_MIX1_PB" />
            <ctl name="SLIM_0_RX Channels" value="One" />
            <ctl name="RX INT0_1 MIX1 INP0" value="RX0" />
            <ctl name="RX INT0 DEM MUX" value="CLSH_DSM_OUT" />
            <ctl name="EAR PA Gain" value="G_6_DB" />
        </path>

    To modify the earpiece volume for anything that uses the earpiece for output add the line inside the path and modify the volume to your liking from 1 to 128
    Code:
    <ctl name="RX0 Digital Volume" value="95" />
    to this path

    Earpiece Mic
    Code:
    <path name="handset-mic">
            <path name="adc4" />
    </path>
    Add the following line inside the path and change the value to your liking from 1 to 124 where 84 is the default. Each increase by 1 corresponds to 1db of gain.
    Code:
    <ctl name="DEC4 Volume" value="84" />


    Headphones Volume
    This might be the headphones path that is being used but I haven't tested it.
    Code:
    <path name="headphones">
            <ctl name="SLIM RX5 MUX" value="AIF4_PB" />
            <ctl name="SLIM RX6 MUX" value="AIF4_PB" />
            <ctl name="SLIM_6_RX Channels" value="Two" />
            <!-- #ifdef VENDOR_EDIT-->
            <!-- guoguangyi@MultiMedia,2016/4/7,use 24bits to get rid of 16bits innate noise  -->
            <ctl name="SLIM_0_RX Format" value="S24_LE" />
            <!-- #endif VENDOR_EDIT-->
            <ctl name="RX INT1_2 MUX" value="RX5" />
            <ctl name="RX INT2_2 MUX" value="RX6" />
            <ctl name="RX INT1 DEM MUX" value="CLSH_DSM_OUT" />
            <ctl name="RX INT2 DEM MUX" value="CLSH_DSM_OUT" />
    <!-- #ifdef VENDOR_EDIT -->
    <!-- /*zhiguang.su@MultiMedia.AudioDrv , 2016/02/19, add for hw require*/  -->
            <ctl name="HPHL Volume" value="19" />
            <ctl name="HPHR Volume" value="19" />
    <!-- #endif -->
    </path>
    Feel free to play around with the volume values


    Adjusting Camera Mic Volume
    This is only if you have flashed the disable NS Camera Fix

    Code:
        <path name="speaker-stereo-dmic-ef">
            <path name="speaker-dmic-endfire" />
    <!-- #ifdef VENDOR_EDIT -->
    <!-- /*zhiguang.su@MultiMedia.AudioDrv , 2016/04/19, mic power high level mode and add adc volume*/  -->
            <ctl name="ADC4 Volume" value="11" />
            <ctl name="ADC5 Volume" value="11" />
            <ctl name="AMIC_3_4 PWR MODE" value="HIGH_PERF" />
            <ctl name="AMIC_5_6 PWR MODE" value="HIGH_PERF" />
            <ctl name="DEC4 Volume" value="96" />
            <ctl name="DEC5 Volume" value="96" />
    <!-- #endif -->
        </path>

    DEC4 and DEC5 correspond to different channels. If you want to increase the gain equally, adjust DEC4 and DEC5 volume to whatever you like. 84 is the default value which means 0db gain. Each increment by 1 indicates a 1db gain for the corresponding channel. DEC volume ranges from 1 to 124.

    Credits
    All credits go to @chdloc for disabling the noise suppression and @mhoppi for testing

    Flashable Zips are below
    6
    1. Added mono plus Camera NS
    2. Added DIY for Mic volume
    3. Didn't really see any difference in quality when increasing the bitrate so I didnt add a zip for it. If anyone is interested let me know.
    6
    @abhi08638 I request your help to find out the handset mic values and handset speaker values (not earpiece), as I couldn't find them similar to many others mixer_paths.XML files which I have been modifying for several of my Android devices like OPO, OPT, Mi3 etc. Basically I want to increase the speaker and mic volumes of the phone. Can you just point me in the right direction? Already checked the mixer_path_tasha.xml but couldn't find anything! TIA.

    This mixer paths is very odd, I don't know how to change the speaker volume since there is only an enable/disable option for speaker sounds. Ex: there's a different value for speaker notifications than audio playback because onePlus is using deep buffering to increase battery life. I'll look more into it and update the OP detailing the values and what they correspond to later today.

    As for the handset, the handset is defined as the earpiece and there is conflict with the handset and speaker paths since they both use slimbus 0 for the path. The mic values are always tx values since they stand for transmit. The handset uses adc4 and if you want to control the mic gain you would have to do something like adc4 volume=20 inside the path of the handset mic or the mix part itself. I usually only make new paths and replace the old ones with the new paths just so I have a reference point.

    @abhi08638 is there a way to turn DOWN overall volume? I work in an office and even the lowest volume is quite high... Thanks!

    I would appreciate more choices in lower speaker volumes as well. The lowest speaker volume is too loud for 90% of the environments/situations I operate in. thanks for considering it,

    Sorry guys but I don't know how yet, I'll keep trying though. The only thing I would be able to do at this point is to route all audio to the earpiece since its Max volume is lower and configurable.

    On a side note I tried getting stereo sound to work but this is extremely difficult since it is not a normal mixer file. I'll keep trying it have no guarantees
    5
    It definitely seems to b able to turn it on/off but only with the patch in place. I do recall testing that option when i first noticed the NS.

    I haven't tested that app before and after the patch as i just reinstalled it after factory resetting last night.
    It's a good thing to note in the OP.
    V4 uploaded, new revert uploaded.

    Things to do:
    1. Add DIY for camcorder volume
    2. Merge mono sound with cam fix
    3. Increase video and audio bitrate for 1080p recordings
    4. Stereo mod
    4
    Camcorder Mic Gain
    This version increases the microphone gain for the audio recorded through the camcorder only. I did this as a workaround for the way too aggressive noise cancellation that happens. This won't fix the problem but hopefully make it more bearable. If I find a better way to fix this, I will update this mod.

    I have not been able to locate a sample of the camcorder audio produced by the Oneplus 3, but it sounds like it suffers from the same problem as the Nexus 5, for which I've come up with an effective workaround. I'm guessing the same can be done for the Oneplus 3.

    As a first step, I suggest you try this.

    Edit: Depending on what software you are running you may need to play around with another device, i.e. SND_DEVICE_IN_SPEAKER_STEREO_DMIC (produces a stereo recording), instead of SND_DEVICE_IN_CAMCORDER_MIC (produces a mono recording) and assign different numbers to acdb_id. Note that I found the acdb_id for the Nexus 5 by looking at the audio HAL sources (hardware/qcom/audio/hal/msm8974/platform.c, see here for the Oneplus 3) and trial-and-error.