Home
last modified time | relevance | path

Searched refs:sample (Results 1 – 25 of 289) sorted by relevance

12345678910>>...12

/frameworks/opt/net/voip/src/jni/rtp/
DG711Codec.cpp51 int sample = samples[i]; in encode() local
52 int sign = (sample >> 8) & 0x80; in encode()
53 if (sample < 0) { in encode()
54 sample = -sample; in encode()
56 sample += 132; in encode()
57 if (sample > 32767) { in encode()
58 sample = 32767; in encode()
60 int exponent = gExponents[sample >> 8]; in encode()
61 int mantissa = (sample >> (exponent + 3)) & 0x0F; in encode()
77 int sample = (((mantissa << 3) + 132) << exponent) - 132; in decode() local
[all …]
/frameworks/av/media/libstagefright/codecs/mp3dec/src/
Dpvmp3_polyphase_filter_window.h93 __inline int16 saturate16(int32 sample) in saturate16() argument
99 mov a, sample, asr#15 in saturate16()
100 teq a, sample, asr b in saturate16()
101 eorne sample, MAX_16BITS_INT, sample, asr#31 in saturate16()
103 return sample ; in saturate16()
108 inline int16 saturate16(int32 sample)
111 if ((sample >> 15) ^(sample >> 31))
113 sample = MAX_16BITS_INT ^(sample >> 31);
115 return sample;
/frameworks/av/media/libmedia/
DSoundPool.cpp206 sp<Sample> sample = new Sample(++mNextSampleID, path); in load() local
207 mSamples.add(sample->sampleID(), sample); in load()
208 doLoad(sample); in load()
209 return sample->sampleID(); in load()
217 sp<Sample> sample = new Sample(++mNextSampleID, fd, offset, length); in load() local
218 mSamples.add(sample->sampleID(), sample); in load()
219 doLoad(sample); in load()
220 return sample->sampleID(); in load()
223 void SoundPool::doLoad(sp<Sample>& sample) in doLoad() argument
225 ALOGV("doLoad: loading sample sampleID=%d", sample->sampleID()); in doLoad()
[all …]
DSoundPoolThread.cpp106 sp <Sample> sample = mSoundPool->findSample(sampleID); in doLoadSample() local
108 if (sample != 0) { in doLoadSample()
109 status = sample->doLoad(); in doLoadSample()
/frameworks/av/media/libeffects/testlibs/
DAudioCommon.h73 inline int16_t audio_sample_t_to_s15(audio_sample_t sample) { in audio_sample_t_to_s15() argument
74 return int16_t((sample + (1 << 8)) >> 9); in audio_sample_t_to_s15()
78 inline int16_t audio_sample_t_to_s15_clip(audio_sample_t sample) { in audio_sample_t_to_s15_clip() argument
80 if (CC_UNLIKELY(sample >= (0x7FFF << 9))) { in audio_sample_t_to_s15_clip()
82 } else if (CC_UNLIKELY(sample <= -(0x8000 << 9))) { in audio_sample_t_to_s15_clip()
85 return audio_sample_t_to_s15(sample); in audio_sample_t_to_s15_clip()
/frameworks/base/core/java/android/gesture/
DInstance.java44 private Instance(long id, float[] sample, String sampleName) { in Instance() argument
46 vector = sample; in Instance()
51 float[] sample = vector; in normalize() local
54 int size = sample.length; in normalize()
56 sum += sample[i] * sample[i]; in normalize()
61 sample[i] /= magnitude; in normalize()
DInstanceLearner.java50 Instance sample = instances.get(i); in classify() local
51 if (sample.vector.length != vector.length) { in classify()
56 … distance = GestureUtils.minimumCosineDistance(sample.vector, vector, orientationType); in classify()
58 distance = GestureUtils.squaredEuclideanDistance(sample.vector, vector); in classify()
66 Double score = label2score.get(sample.label); in classify()
68 label2score.put(sample.label, weight); in classify()
DGestureUtils.java93 float[] sample = new float[bitmapSize * bitmapSize]; in spatialSampling() local
94 Arrays.fill(sample, 0); in spatialSampling()
159 plot(segmentStartX, segmentStartY, sample, bitmapSize); in spatialSampling()
168 plot(xpos, ypos, sample, bitmapSize); in spatialSampling()
177 plot(xpos, ypos, sample, bitmapSize); in spatialSampling()
188 plot(xpos, ypos, sample, bitmapSize); in spatialSampling()
197 plot(xpos, ypos, sample, bitmapSize); in spatialSampling()
206 return sample; in spatialSampling()
209 private static void plot(float x, float y, float[] sample, int sampleSize) { in plot() argument
220 if (sample[index] < 1){ in plot()
[all …]
/frameworks/ml/bordeaux/service/src/android/bordeaux/services/
DLearning_MulticlassPA.java35 private IntFloatArray splitIntFloatArray(List<IntFloat> sample) { in splitIntFloatArray() argument
37 ArrayList<IntFloat> s = (ArrayList<IntFloat>)sample; in splitIntFloatArray()
72 public void TrainOneSample(List<IntFloat> sample, int target) { in TrainOneSample() argument
73 IntFloatArray splited = splitIntFloatArray(sample); in TrainOneSample()
82 public int Classify(List<IntFloat> sample) { in Classify() argument
83 IntFloatArray splited = splitIntFloatArray(sample); in Classify()
DBordeauxClassifier.java44 private ArrayList<IntFloat> getArrayList(final HashMap<Integer, Float> sample) { in getArrayList() argument
46 for (Map.Entry<Integer, Float> x : sample.entrySet()) { in getArrayList()
78 public boolean update(final HashMap<Integer, Float> sample, int target) { in update() argument
82 mClassifier.TrainOneSample(getArrayList(sample), target); in update()
90 public int classify(final HashMap<Integer, Float> sample) { in classify() argument
95 return mClassifier.Classify(getArrayList(sample)); in classify()
DBordeauxRanker.java45 private ArrayList<StringFloat> getArrayList(final HashMap<String, Float> sample) { in getArrayList() argument
47 for (Map.Entry<String, Float> x : sample.entrySet()) { in getArrayList()
107 public float scoreSample(final HashMap<String, Float> sample) { in scoreSample() argument
111 return mRanker.ScoreSample(getArrayList(sample)); in scoreSample()
118 public boolean setPriorWeight(final HashMap<String, Float> sample) { in setPriorWeight() argument
122 return mRanker.SetModelPriorWeight(getArrayList(sample)); in setPriorWeight()
DILearning_MulticlassPA.aidl27 void TrainOneSample(in List<IntFloat> sample, int target); in TrainOneSample() argument
28 int Classify(in List<IntFloat> sample); in Classify() argument
DBordeauxAggregatorManager.java141 private Map<String, String> getMap(final List<StringString> sample) { in getMap() argument
143 for (int i =0; i < sample.size(); i++) { in getMap()
144 map.put(sample.get(i).key, sample.get(i).value); in getMap()
DLearning_StochasticLinearRanker.java75 public float ScoreSample(List<StringFloat> sample) { in ScoreSample() argument
76 ArrayList<StringFloat> temp = (ArrayList<StringFloat>)sample; in ScoreSample()
88 public boolean SetModelPriorWeight(List<StringFloat> sample) { in SetModelPriorWeight() argument
89 ArrayList<StringFloat> temp = (ArrayList<StringFloat>)sample; in SetModelPriorWeight()
/frameworks/base/media/tests/audiotests/
Dshared_mem_test.cpp139 long sample; in Generate() local
156 long sample; in ComputeSine() local
159 sample = (amplitude*sin1024[(phi>>22) & 0x3ff]) >> 15; in ComputeSine()
165 sample = sample + l0; in ComputeSine()
167 return (short)sample; in ComputeSine()
/frameworks/base/docs/html-intl/ja/training/multiscreen/
Dscreensizes.jd58 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
128 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
132 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
148 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
152 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
222 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
225 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
228 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
231 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes_narrow.xml all}
236 {@sample development/samples/training/multiscreen/newsreader/res/values/layouts.xml all}
[all …]
/frameworks/base/docs/html-intl/ko/training/multiscreen/
Dscreensizes.jd58 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
128 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
132 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
148 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
152 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
222 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
225 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
228 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
231 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes_narrow.xml all}
236 {@sample development/samples/training/multiscreen/newsreader/res/values/layouts.xml all}
[all …]
/frameworks/base/docs/html-intl/zh-cn/training/multiscreen/
Dscreensizes.jd58 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
128 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
132 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
148 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
152 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
222 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
225 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
228 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
231 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes_narrow.xml all}
236 {@sample development/samples/training/multiscreen/newsreader/res/values/layouts.xml all}
[all …]
/frameworks/av/services/audioflinger/
DAudioResamplerCubic.cpp76 int32_t sample; in resampleStereo16() local
142 int32_t sample; in resampleMono16() local
147 sample = interp(&left, x); in resampleMono16()
148 out[outputIndex++] += vl * sample; in resampleMono16()
149 out[outputIndex++] += vr * sample; in resampleMono16()
/frameworks/base/docs/html-intl/ru/training/multiscreen/
Dscreensizes.jd58 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
128 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
132 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
148 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
152 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
222 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
225 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
228 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
231 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes_narrow.xml all}
236 {@sample development/samples/training/multiscreen/newsreader/res/values/layouts.xml all}
[all …]
/frameworks/av/media/libstagefright/
DFLACExtractor.cpp109 MediaBuffer *readBuffer(FLAC__uint64 sample) { in readBuffer() argument
110 return readBuffer(true, sample); in readBuffer()
148 MediaBuffer *readBuffer(bool doSeek, FLAC__uint64 sample);
626 MediaBuffer *FLACParser::readBuffer(bool doSeek, FLAC__uint64 sample) in readBuffer() argument
632 if (!FLAC__stream_decoder_seek_absolute(mDecoder, sample)) { in readBuffer()
633 ALOGE("FLACParser::readBuffer seek to sample %llu failed", sample); in readBuffer()
636 ALOGV("FLACParser::readBuffer seek to sample %llu succeeded", sample); in readBuffer()
738 FLAC__uint64 sample; in read() local
740 sample = 0LL; in read()
743 sample = (seekTimeUs * mParser->getSampleRate()) / 1000000LL; in read()
[all …]
/frameworks/base/docs/html/google/play/billing/v2/
Dbilling_integrate.jd26 implementation tasks, using the sample application as an example.</p>
36 <li><a href="#billing-download">Download the in-app billing sample application</a>.</li>
51 <p>The in-app billing sample application shows you how to perform several tasks that are common to
62 <p>The sample application includes an application file (<code>Dungeons.java</code>), the AIDL file
67 <p>Table 1 lists the source files that are included with the sample application.</p>
68 <p class="table-caption" id="source-files-table"><strong>Table 1.</strong> In-app billing sample
124 <td>Defines various Google Play constants and sample application constants. All constants that
136 <p>The in-app billing sample application is available as a downloadable component of the Android
137 SDK. To download the sample application component, launch the Android SDK Manager and then
144 <strong>Figure 1.</strong> The Google Market Billing package contains the sample application and
[all …]
/frameworks/rs/scriptc/
Drs_allocation.rsh245 * @param a 1D allocation to sample from
247 * @param location to sample from
253 * @param a 1D allocation to sample from
255 * @param location to sample from
256 * @param lod mip level to sample from, for fractional values
265 * @param a 2D allocation to sample from
267 * @param location to sample from
274 * @param a 2D allocation to sample from
276 * @param location to sample from
277 * @param lod mip level to sample from, for fractional values
/frameworks/av/media/libeffects/loudness/
DEffectLoudnessEnhancer.cpp79 static inline int16_t clamp16(int32_t sample) in clamp16() argument
81 if ((sample>>15) ^ (sample>>31)) in clamp16()
82 sample = 0x7FFF ^ (sample>>31); in clamp16()
83 return sample; in clamp16()
/frameworks/base/docs/html/training/multiscreen/
Dscreensizes.jd37 the sample app</a>
67 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane_with_bar.xml all}
69 <p>Notice how the sample uses <code>"wrap_content"</code> and <code>"match_parent"</code>
78 <p class="img-caption"><strong>Figure 1.</strong> The News Reader sample app in portrait (left)
165 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
169 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
198 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
202 {@sample development/samples/training/multiscreen/newsreader/res/layout/twopanes.xml all}
278 benefit from adjustments. In the News Reader sample app, here is how the layout
297 {@sample development/samples/training/multiscreen/newsreader/res/layout/onepane.xml all}
[all …]

12345678910>>...12