volume

AVAudioRecorder normalize volume

你离开我真会死。 提交于 2019-12-04 10:06:46
I've got an app that records audio. I'm wondering how I can increase the gain. is there a way to normalize the audio or amplify it somehow? thanks, howie Looks like I found a solution. According to the documentation the AVAudioPlayer volume can be between 0.0 and 1.0. Apparently it can be set to a value greater than 1.0. By increasing the volume I was able to achieve the same desired result. While it's not normalized, the gain is increased. #import <AudioToolbox/AudioServices.h> UInt32 audioRouteOverride = kAudioSessionOverrideAudioRoute_Speaker; AudioSessionSetProperty (kAudioSessionProperty

docker之volume 挂载h5文件到容器出现403

拈花ヽ惹草 提交于 2019-12-04 07:52:40
在linux上运行docker,并借助volume将虚拟机主机上当前目录下的h5文件挂载到容器内部指定目录下时,出现403错误,如下 具体情况如下: 1.跳转至包含h5文件的目录下,其对应目录树如下 2.使用docker run -v 命令将当前目录下的html文件夹(内部包含h5文件)挂载到容器指定目录下,并使用-p命令将容器内部使用的网络端口映射到主机指定端口上 3.运行完毕后,使用curl命令查看主机上指定端口,出现如下403错误 进入容器内部指定的文件夹下,被提示无访问权限 4.经过查询发现,需要在挂载命令之后多加一个权限参数 5.使用cat命令查看虚拟机主机的h5文件,内容与curl所得一致 6.使用vi命令对主机下h5文件内容进行修改,容器内部内容同样发生变动。通过volume实现了不对容器进行修改保存即可完成容器内部文件修改的操作 Note: 1.关于docker run 的privilege参数可以参照这篇博文: https://blog.csdn.net/halcyonbaby/article/details/43499409#commentBox 大体意思是:超级用户root在未获得privilege权限时,在docker容器内部相当于一个普通用户,权限比较有限。 2.使用docker help run 命令即可查看docker run 各个参数含义 .....

Modify volume gain on audio sample buffer

二次信任 提交于 2019-12-04 07:27:26
I want to increase a volume on buffer with voice data. The point is I'm using DirectSound and I have one primary and one secondary buffer - all streams mixing is done by hand. In a voice chat all participants can have independent volume levels. I multiply each stream data by a value (gain) and sum it to one buffer. Everything works fine but when I try to multiply data by a value greater than 1.0f - I hear some clipping or what. I've tried using Audacity effect compressor but this doesn't help reducing the strange noise. Probably I should modify gain in some other way? Or just use another post

docker volume

北城以北 提交于 2019-12-04 01:49:15
Volume概念 众所周知,Docker Image可以理解成多个只读文件叠加而成,因此Docker Image是只读的。 当我们将其运行起来,就相当于在只读的Image外包裹了一层读写层变成了容器。 当你删除容器之后,使用这个镜像重新创建一个容器,此时的镜像的只读层还和原来的一样,但是你在读写层的修改全部都会丢失。 那么问题就来了,如果想要持久化在读写层的数据,该怎么利用docker做到呢? docker使用volume实现数据的持久化,不仅如此volume还能帮助容器和容器之间,容器和host之间共享数据。 Volume如何在mac上持久化数据 如果想要持久化数据,就必须将读写层的数据暂存在host machine,因此当你使用: docker run .... -v /data docker volume create --name ** 以上两种指令都可以帮助你创建一个Volume,其实是在host machine上创建一个directory。 常在mac上用docker的人应该知道,和Linux不同,在mac上用docker会在mac上启动一个虚拟机运行docker,因此volume创建的directory并不在你的machine上,而是在虚拟机中。 那么如何知道我的volume创建在host machine的什么位置呢? docker volume ls

Audio output level in a form that can be converted to decibel

放肆的年华 提交于 2019-12-03 21:24:18
I need to find a way to get the current audio output volume while the phone is making noise on the headphones, this value will be converted to a decibel level. The android API does not appear to have any way of accessing a constant volume level other than a seemingly arbitrary volume setting level, but I dont see a way to convert that to a standard decibel level or "loudness" measurement. I have seen some ways to use the mic for this, but that wont work with headsets very well. Does anyone know a way to measure either the maximum possible decibel (or some standard) output level to compare

iPhone how hide volume overlay when press volume key

↘锁芯ラ 提交于 2019-12-03 21:07:51
I have do lots to solve it,like add MPVolumeView,someone says that system volume HUD will hide if you add a instance of MPVolumeView in current,but that not work i add obsever to observe the volume's change,and take picture but now i lost in how hide the volume HUD I had tried the solution that add MPVolumeView instance but won't WORK please give me another way to solve it Any suggestions would be appreciated. Julian Król You need to put volume overlay like this: MPVolumeView *volumeView = [[MPVolumeView alloc] initWithFrame: CGRectZero]; [self.view addSubview: volumeView]; Now the custom

How do I calculate the volume of an object stored in STL files?

大城市里の小女人 提交于 2019-12-03 20:23:38
问题 I have .stl (STL is a file format native to the stereolithography CAD software created by 3D Systems) files, from which I must calculate the volume. How do I do this? I'm using the calculation below but the volume is not equal to that calculated by other software float x1,y1,z1; float x2,y2,z2; float x3,y3,z3; The above are the vertices. triangles is just a data structure holding an object with the vertices of each triangle. totalVolume += currentVolume = (triangles[i].x1*triangles[i].y2

How do I edit the Default Volume?

这一生的挚爱 提交于 2019-12-03 17:31:11
I'd like to set the default audio volume on the wordpress mediaelement.js player to be at 100% volume. It appears that the default is somewhere around 80%. Can anyone tell me which bit of code I need to change in order to do this? It'd be great if future versions of Wordpress come with a basic 'Settings' function for the now native player so we can alter thing like default volume and colours. Got interested too with that question. So you have to go to your folder like: /wordpress/wp-includes/js/mediaelement/ File name: mediaelement-and-player.min.js Ctrl+F and search for - startVolume It found