Searched refs:sample (Results 1 - 25 of 59) sorted by relevance

123

/frameworks/av/media/libstagefright/codecs/mp3dec/src/
H A Dpvmp3_polyphase_filter_window.h93 __inline int16 saturate16(int32 sample) argument
99 mov a, sample, asr#15 local
100 teq a, sample, asr b local
101 eorne sample, MAX_16BITS_INT, sample, asr#31 local
103 return sample ;
108 inline int16 saturate16(int32 sample) argument
111 if ((sample >> 15) ^(sample >> 31))
113 sample
[all...]
/frameworks/opt/net/voip/src/jni/rtp/
H A DG711Codec.cpp51 int sample = samples[i]; local
52 int sign = (sample >> 8) & 0x80;
53 if (sample < 0) {
54 sample = -sample;
56 sample += 132;
57 if (sample > 32767) {
58 sample = 32767;
60 int exponent = gExponents[sample >> 8];
61 int mantissa = (sample >> (exponen
77 int sample = (((mantissa << 3) + 132) << exponent) - 132; local
102 int sample = samples[i]; local
127 int sample = (exponent == 0 ? (mantissa << 4) + 8 : local
[all...]
/frameworks/av/media/libeffects/testlibs/
H A DAudioCommon.h29 // Audio sample type.
31 // Accumulator type for coef x sample.
40 // Number of fraction bits for audio sample.
42 // Audio sample with the value of 1.0
49 // Multiply a sample by a coefficient to return an accumulator.
54 // Multiply and accumulate sample by a coefficient to return an accumulator.
59 // Convert a sample-coefficient accumulator to a sample.
67 // Convert a S15 sample to audio_sample_t
72 // Convert a audio_sample_t sample t
73 audio_sample_t_to_s15(audio_sample_t sample) argument
78 audio_sample_t_to_s15_clip(audio_sample_t sample) argument
[all...]
/frameworks/base/core/java/android/gesture/
H A DInstance.java21 * An instance represents a sample if the label is available or a query if the
44 private Instance(long id, float[] sample, String sampleName) { argument
46 vector = sample;
51 float[] sample = vector;
54 int size = sample.length;
56 sum += sample[i] * sample[i];
61 sample[i] /= magnitude;
H A DInstanceLearner.java50 Instance sample = instances.get(i);
51 if (sample.vector.length != vector.length) {
56 distance = GestureUtils.minimumCosineDistance(sample.vector, vector, orientationType);
58 distance = GestureUtils.squaredEuclideanDistance(sample.vector, vector);
66 Double score = label2score.get(sample.label);
68 label2score.put(sample.label, weight);
H A DGestureUtils.java93 float[] sample = new float[bitmapSize * bitmapSize];
94 Arrays.fill(sample, 0);
159 plot(segmentStartX, segmentStartY, sample, bitmapSize);
168 plot(xpos, ypos, sample, bitmapSize);
177 plot(xpos, ypos, sample, bitmapSize);
188 plot(xpos, ypos, sample, bitmapSize);
197 plot(xpos, ypos, sample, bitmapSize);
206 return sample;
209 private static void plot(float x, float y, float[] sample, int sampleSize) { argument
220 if (sample[inde
[all...]
/frameworks/support/v7/palette/tests/java/android/support/v7/graphics/
H A DBucketTests.java44 final Bitmap sample = loadSampleBitmap();
46 Palette.from(sample).generate();
47 assertFalse(sample.isRecycled());
73 final Bitmap sample = loadSampleBitmap();
75 Palette.Builder b = new Palette.Builder(sample);
76 b.setRegion(0, 0, sample.getWidth(), sample.getHeight());
83 final Bitmap sample = loadSampleBitmap();
85 Palette.Builder b = new Palette.Builder(sample);
86 b.setRegion(0, 0, sample
[all...]
/frameworks/av/media/libaaudio/src/utility/
H A DAAudioUtilities.cpp93 static float clipAndClampFloatToPcm16(float sample, float scaler) { argument
94 // Clip to valid range of a float sample to prevent excessive volume.
95 if (sample > MAX_HEADROOM) sample = MAX_HEADROOM;
96 else if (sample < MIN_HEADROOM) sample = MIN_HEADROOM;
99 float fval = sample * scaler;
109 float sample = *source++; local
110 *destination++ = clipAndClampFloatToPcm16(sample, scaler);
125 float sample local
172 float sample = *source++; local
196 float sample = *source++ * scaler; local
[all...]
/frameworks/base/media/tests/audiotests/
H A Dshared_mem_test.cpp152 long sample; local
155 sample = (amplitude*sin1024[(phi>>22) & 0x3ff]) >> 15;
161 sample = sample + l0;
163 return (short)sample;
/frameworks/base/media/jni/soundpool/
H A DSoundPoolThread.cpp106 sp <Sample> sample = mSoundPool->findSample(sampleID); local
108 if (sample != 0) {
109 status = sample->doLoad();
H A DSoundPool.cpp230 sp<Sample> sample = new Sample(sampleID, fd, offset, length); local
231 mSamples.add(sampleID, sample);
232 sample->startLoad();
238 // It theoretically possible that sample loads might decode out-of-order.
263 // is sample ready?
264 sp<Sample> sample(findSample_l(sampleID));
265 if ((sample == 0) || (sample->state() != Sample::READY)) {
266 ALOGW(" sample %d not READY", sampleID);
284 channel->play(sample, channelI
719 play(const sp<Sample>& sample, int nextChannelID, float leftVolume, float rightVolume, int priority, int loop, float rate) argument
841 sp<Sample> sample; local
896 sp<Sample> sample = mSample; local
1102 set(const sp<Sample>& sample, int channelID, float leftVolume, float rightVolume, int priority, int loop, float rate) argument
[all...]
/frameworks/av/include/cpustats/
H A DCentralTendencyStatistics.h34 void sample(double x);
H A DThreadCpuUsage.h32 // to demarcate the region(s) of interest, and then call sample() periodically.
74 // Add a sample point, and also enable tracking if needed.
76 // does _not_ add a sample -- it is not possible to add a sample the
79 // then adds a sample for tracked CPU ns since the previous
80 // sample, or since the first call to sampleAndEnable(), enable(), or
81 // setEnabled(true). If there was a previous sample but tracking is
82 // now disabled, then adds a sample for the tracked CPU ns accumulated
85 // by sample() avoids a race condition for the first sample
[all...]
/frameworks/av/media/libcpustats/include/cpustats/
H A DCentralTendencyStatistics.h34 void sample(double x);
H A DThreadCpuUsage.h32 // to demarcate the region(s) of interest, and then call sample() periodically.
74 // Add a sample point, and also enable tracking if needed.
76 // does _not_ add a sample -- it is not possible to add a sample the
79 // then adds a sample for tracked CPU ns since the previous
80 // sample, or since the first call to sampleAndEnable(), enable(), or
81 // setEnabled(true). If there was a previous sample but tracking is
82 // now disabled, then adds a sample for the tracked CPU ns accumulated
85 // by sample() avoids a race condition for the first sample
[all...]
/frameworks/av/media/libaaudio/examples/utils/
H A DAAudioSimpleRecorder.h56 * Also known as "sample rate"
264 float sample; local
271 sample = audioBuffer[frameIndex * samplesPerFrame] * (1.0/32768);
273 if (sample > data->peakLevel) {
274 data->peakLevel = sample;
283 sample = audioBuffer[frameIndex * samplesPerFrame];
285 if (sample > data->peakLevel) {
286 data->peakLevel = sample;
/frameworks/av/media/libaudioprocessing/
H A DAudioResamplerCubic.cpp80 // calculate output sample
91 // time to fetch another sample
107 // advance sample state
145 int32_t sample; local
148 // calculate output sample
150 sample = interp(&left, x);
151 out[outputIndex++] += vl * sample;
152 out[outputIndex++] += vr * sample;
159 // time to fetch another sample
175 // advance sample stat
[all...]
/frameworks/av/media/libcpustats/
H A DCentralTendencyStatistics.cpp21 void CentralTendencyStatistics::sample(double x) function in class:CentralTendencyStatistics
/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/decoder/
H A DAudioTrackDecoder.java91 // Just drop the audio sample.
102 * Fills the argument {@link FrameValue} with an audio sample containing the audio that was
108 AudioSample sample = new AudioSample(
110 audioFrame.setValue(sample);
/frameworks/rs/tests/java_api/SampleTest/src/com/android/rs/sample/
H A Dsample.rs18 #pragma rs java_package_name(com.android.rs.sample)
/frameworks/av/services/audioflinger/
H A DFastMixerDumpState.cpp95 // sample set, we get 99.8% combined, or close to three standard deviations.
105 wall.sample(wallNs);
107 loadNs.sample(sampleLoadNs);
112 kHz.sample(sampleCpukHz >> 4);
116 loadMHz.sample(adjMHz);
150 left.sample(tail[i]);
151 right.sample(tail[n - (i + 1)]);
/frameworks/av/media/libaaudio/examples/loopback/src/
H A DLoopbackAnalyzer.h370 static void printAudioScope(float sample) {
374 if (sample < -1.0) {
375 sample = -1.0;
377 } else if (sample > 1.0) {
378 sample = 1.0;
381 int numSpaces = (int) (((sample + 1.0) * 0.5) * maxStars);
460 for (float sample : s_Impulse) {
461 *outputData = sample;
654 float sample;
661 float sample
[all...]
/frameworks/av/media/libstagefright/
H A DFLACExtractor.cpp113 MediaBuffer *readBuffer(FLAC__uint64 sample) { argument
114 return readBuffer(true, sample);
152 MediaBuffer *readBuffer(bool doSeek, FLAC__uint64 sample);
572 ALOGE("unsupported bits per sample %u", getBitsPerSample());
575 // check sample rate
590 ALOGE("unsupported sample rate %u", getSampleRate());
622 // sample rate is non-zero, so division by zero not possible
651 MediaBuffer *FLACParser::readBuffer(bool doSeek, FLAC__uint64 sample) argument
657 if (!FLAC__stream_decoder_seek_absolute(mDecoder, sample)) {
658 ALOGE("FLACParser::readBuffer seek to sample
766 FLAC__uint64 sample; local
[all...]
/frameworks/av/media/libaaudio/examples/input_monitor/src/
H A Dinput_monitor.cpp145 float sample = data[frameIndex * actualSamplesPerFrame] * (1.0/32768); local
146 if (sample > peakLevel) {
147 peakLevel = sample;
/frameworks/support/frameworks/support/samples/SupportAppNavigation/src/com/example/android/support/appnavigation/app/
H A DAppNavHomeActivity.java69 SampleInfo sample = new SampleInfo(label, target);
70 samples.add(sample);

Completed in 640 milliseconds

123