Home
last modified time | relevance | path

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

12345678910>>...16

/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/support/v7/palette/src/androidTest/java/android/support/v7/graphics/
DBucketTests.java42 final Bitmap sample = loadSampleBitmap(); in testSourceBitmapNotRecycled() local
44 Palette.from(sample).generate(); in testSourceBitmapNotRecycled()
45 assertFalse(sample.isRecycled()); in testSourceBitmapNotRecycled()
71 final Bitmap sample = loadSampleBitmap(); in testRegionWhole() local
73 Palette.Builder b = new Palette.Builder(sample); in testRegionWhole()
74 b.setRegion(0, 0, sample.getWidth(), sample.getHeight()); in testRegionWhole()
81 final Bitmap sample = loadSampleBitmap(); in testRegionUpperLeft() local
83 Palette.Builder b = new Palette.Builder(sample); in testRegionUpperLeft()
84 b.setRegion(0, 0, sample.getWidth() / 2, sample.getHeight() / 2); in testRegionUpperLeft()
91 final Bitmap sample = loadSampleBitmap(); in testRegionBottomRight() local
[all …]
/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/docs/html/preview/
Dsamples.jd19 <img src="{@docRoot}preview/images/sample-multiwindow.png" style="float: left; padding-right: 0.5em…
21 This sample demonstrates how to take advantage of multiple window
31 <img src="{@docRoot}preview/images/sample-activenotifications.png" style="float: left; padding-righ…
33 This is a pre-existing sample which shows a simple service that sends
38 This sample has been updated to take advantage of new notification features
48 <img src="{@docRoot}preview/images/sample-messagingservice.png" style="float: left; padding-right: …
50 This is a pre-existing sample which demonstrates how to use
55 This sample has been updated to take advantage of new notification features
65 <img src="{@docRoot}preview/images/sample-directboot.png" style="float: left; padding-right: 0.5em"…
67 This sample demonstrates how to store and access data in a device encrypted
[all …]
/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/base/docs/html/about/versions/marshmallow/
Dsamples.jd9 Download or browse sample projects to get started with Android 6.0
12 Samples</b> menu option and pick the sample you want.
22 <a href="{@docRoot}samples/ActiveNotifications/index.html">Active Notification</a>: This sample dem…
29 (API level 23) introduces automatic backup for app settings. This sample demonstrates how to add
34 <a href="{@docRoot}samples/Camera2Raw/index.html">Camera 2 Raw</a>: This sample demonstrates how to
40 <a href="{@docRoot}samples/ConfirmCredential/index.html">Confirm Credential</a>: This sample
45 sample demonstrates how to use the device owner features to manage and
50 This sample demonstrates how to provide the
58 This sample demonstrates how to recognize registered fingerprints to
64 This sample demonstrates how to use the <a href=
[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()
/frameworks/base/media/jni/soundpool/
DSoundPool.cpp229 sp<Sample> sample = new Sample(sampleID, fd, offset, length); in load() local
230 mSamples.add(sampleID, sample); in load()
231 sample->startLoad(); in load()
263 sp<Sample> sample(findSample_l(sampleID)); in play() local
264 if ((sample == 0) || (sample->state() != Sample::READY)) { in play()
283 channel->play(sample, channelID, leftVolume, rightVolume, priority, loop, rate); in play()
705 void SoundChannel::play(const sp<Sample>& sample, int nextChannelID, float leftVolume, in play() argument
717 this, sample->sampleID(), nextChannelID, leftVolume, rightVolume, in play()
723 mNextEvent.set(sample, nextChannelID, leftVolume, rightVolume, priority, loop, rate); in play()
738 int numChannels = sample->numChannels(); in play()
[all …]
/frameworks/base/docs/html/samples/new/
Dindex.jd23 This sample demonstrates how to use the {@link
35 sample demonstrates how to add filtering rules to an app to manage settings
44 This sample demonstrates how to use the
56 This sample demonstrates how to use device credentials as an authentication method in your app.
64 This sample demonstrates how to use the device owner features to manage and
73 This sample demonstrates how to provide the
85 This sample demonstrates how to recognize registered fingerprints to
94 This sample demonstrates how to use the <a href=
104 This sample demonstrates how to use the <a href=
114 This sample demonstrates how to use NFC to provision other devices with a
[all …]
/frameworks/base/docs/html/ndk/guides/audio/
Dinput-latency.jd51 <li> Be prepared to handle nominal sample rates of 44,100 and 48,000 Hz as reported by
55 PROPERTY_OUTPUT_SAMPLE_RATE</a>. Other sample rates are possible, but rare.</li>
77 even when both sides use the same sample rate. Your application should buffer the data with
80 <li>Don't assume that the actual sample rate exactly matches the nominal sample rate. For
81 example, if the nominal sample rate is 48,000 Hz, it is normal for the audio clock to advance
85 <li>Don't assume that the actual playback sample rate exactly matches the actual capture sample
87 the on-device microphone at 48,000 Hz nominal sample rate, and playing on USB audio
88 at 48,000 Hz nominal sample rate, the actual sample rates are likely to be slightly different
92 <p>A consequence of potentially independent audio clocks is the need for asynchronous sample rate
93 conversion. A simple (though not ideal for audio quality) technique for asynchronous sample rate
/frameworks/base/media/tests/audiotests/
Dshared_mem_test.cpp152 long sample; in ComputeSine() local
155 sample = (amplitude*sin1024[(phi>>22) & 0x3ff]) >> 15; in ComputeSine()
161 sample = sample + l0; in ComputeSine()
163 return (short)sample; in ComputeSine()
/frameworks/av/services/audioflinger/
DFastMixerDumpState.cpp105 wall.sample(wallNs); in dump()
107 loadNs.sample(sampleLoadNs); in dump()
112 kHz.sample(sampleCpukHz >> 4); in dump()
116 loadMHz.sample(adjMHz); in dump()
150 left.sample(tail[i]); in dump()
151 right.sample(tail[n - (i + 1)]); in dump()
/frameworks/base/docs/html-intl/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/base/docs/html-intl/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/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/samples/
Dindex.jd7 <p>Welcome to code samples for Android developers. Here you can browse sample code and learn how to
11 <p>Each sample is a fully functioning Android app. You can browse the resources, source files and
21 <p>To import a code sample into Android Studio:<p>
26 <li>Select a sample to import and click <strong>Next</strong>.</li>
29 <p>The sample project opens in a new Android Studio project.</p></li>
34 Android code sample</strong> in the Welcome to Android Studio wizard to import a sample project
66 downloaded sample project.
/frameworks/base/docs/html-intl/intl/ja/preview/
Dsamples.jd19 <img src="{@docRoot}preview/images/sample-multiwindow.png" style="float: left; padding-right: 0.5em…
31 <img src="{@docRoot}preview/images/sample-activenotifications.png" style="float: left; padding-righ…
48 <img src="{@docRoot}preview/images/sample-messagingservice.png" style="float: left; padding-right: …
65 <img src="{@docRoot}preview/images/sample-directboot.png" style="float: left; padding-right: 0.5em"…
77 <img src="{@docRoot}preview/images/sample-scopeddirectoryaccess.png" style="float: left; padding-ri…
/frameworks/base/docs/html-intl/intl/ru/preview/
Dsamples.jd19 <img src="{@docRoot}preview/images/sample-multiwindow.png" style="float: left; padding-right: 0.5em…
31 <img src="{@docRoot}preview/images/sample-activenotifications.png" style="float: left; padding-righ…
48 <img src="{@docRoot}preview/images/sample-messagingservice.png" style="float: left; padding-right: …
65 <img src="{@docRoot}preview/images/sample-directboot.png" style="float: left; padding-right: 0.5em"…
77 <img src="{@docRoot}preview/images/sample-scopeddirectoryaccess.png" style="float: left; padding-ri…
/frameworks/base/docs/html-intl/intl/ko/preview/
Dsamples.jd19 <img src="{@docRoot}preview/images/sample-multiwindow.png" style="float: left; padding-right: 0.5em…
31 <img src="{@docRoot}preview/images/sample-activenotifications.png" style="float: left; padding-righ…
48 <img src="{@docRoot}preview/images/sample-messagingservice.png" style="float: left; padding-right: …
65 <img src="{@docRoot}preview/images/sample-directboot.png" style="float: left; padding-right: 0.5em"…
77 <img src="{@docRoot}preview/images/sample-scopeddirectoryaccess.png" style="float: left; padding-ri…
/frameworks/base/docs/html-intl/intl/zh-cn/preview/
Dsamples.jd19 <img src="{@docRoot}preview/images/sample-multiwindow.png" style="float: left; padding-right: 0.5em…
31 <img src="{@docRoot}preview/images/sample-activenotifications.png" style="float: left; padding-righ…
48 <img src="{@docRoot}preview/images/sample-messagingservice.png" style="float: left; padding-right: …
65 <img src="{@docRoot}preview/images/sample-directboot.png" style="float: left; padding-right: 0.5em"…
77 <img src="{@docRoot}preview/images/sample-scopeddirectoryaccess.png" style="float: left; padding-ri…

12345678910>>...16