Searched refs:color (Results 1 - 25 of 413) sorted by relevance

1234567891011>>

/frameworks/data-binding/extensions/baseAdapters/src/main/java/android/databinding/adapters/
H A DConverters.java24 public static ColorDrawable convertColorToDrawable(int color) { argument
25 return new ColorDrawable(color);
29 public static ColorStateList convertColorToColorStateList(int color) { argument
30 return ColorStateList.valueOf(color);
/frameworks/base/services/core/java/com/android/server/lights/
H A DLight.java41 public abstract void setColor(int color); argument
42 public abstract void setFlashing(int color, int mode, int onMS, int offMS); argument
44 public abstract void pulse(int color, int onMS); argument
H A DLightsService.java55 int color = brightness & 0x000000ff;
56 color = 0xff000000 | (color << 16) | (color << 8) | color;
57 setLightLocked(color, LIGHT_FLASH_NONE, 0, 0, brightnessMode);
62 public void setColor(int color) { argument
64 setLightLocked(color, LIGHT_FLASH_NONE, 0, 0, 0);
69 public void setFlashing(int color, int mode, int onMS, int offMS) { argument
71 setLightLocked(color, mod
81 pulse(int color, int onMS) argument
121 setLightLocked(int color, int mode, int onMS, int offMS, int brightnessMode) argument
243 setLight_native(long ptr, int light, int color, int mode, int onMS, int offMS, int brightnessMode) argument
[all...]
/frameworks/wilhelm/src/itf/
H A DILEDArray.c63 SLHSL color = *pColor; local
64 if (!(0 <= color.hue && color.hue <= 360000))
66 if (!(0 <= color.saturation && color.saturation <= 1000))
68 if (!(0 <= color.lightness && color.lightness <= 1000))
73 thiz->mColors[index] = color;
92 SLHSL color = thiz->mColors[index]; local
94 *pColor = color;
114 SLHSL *color = thiz->mColors; local
[all...]
/frameworks/base/graphics/tests/graphicstests/src/android/graphics/
H A DColorStateListTest.java39 mFailureColor = mResources.getColor(R.color.failColor);
44 ColorStateList colorStateList = mResources.getColorStateList(R.color.color1);
46 int focusColor = colorStateList.getColorForState(focusedState, R.color.failColor);
47 assertEquals(mResources.getColor(R.color.testcolor1), focusColor);
52 ColorStateList colorStateList = mResources.getColorStateList(R.color.color1);
55 assertEquals(mResources.getColor(R.color.testcolor2), defaultColor);
60 int defaultColor = mResources.getColor(R.color.color1);
61 assertEquals(mResources.getColor(R.color.testcolor2), defaultColor);
66 int defaultColor = mResources.getColor(R.color.color_no_default);
67 assertEquals(mResources.getColor(R.color
[all...]
/frameworks/base/graphics/java/android/graphics/
H A DColor.java28 * The Color class defines methods for creating and converting color ints.
31 * stored solely in the alpha component, and not in the color components. The
54 * Return the alpha component of a color int. This is the same as saying
55 * color >>> 24
57 public static int alpha(int color) { argument
58 return color >>> 24;
62 * Return the red component of a color int. This is the same as saying
63 * (color >> 16) & 0xFF
65 public static int red(int color) { argument
66 return (color >> 1
73 green(int color) argument
81 blue(int color) argument
123 luminance(@olorInt int color) argument
191 colorToHSV(@olorInt int color, @Size(3) float hsv[]) argument
239 getHtmlColor(String color) argument
[all...]
H A DPorterDuffColorFilter.java23 * A color filter that can be used to tint the source pixels using a single
24 * color and a specific {@link PorterDuff Porter-Duff composite mode}.
31 * Create a color filter that uses the specified color and Porter-Duff mode.
33 * @param color The ARGB source color used with the specified Porter-Duff mode
40 public PorterDuffColorFilter(@ColorInt int color, @NonNull PorterDuff.Mode mode) { argument
41 mColor = color;
47 * Returns the ARGB color used to tint the source pixels when this filter
60 * Specifies the color t
71 setColor(int color) argument
[all...]
/frameworks/support/v7/palette/src/main/java/android/support/v7/graphics/
H A DColorCutQuantizer.java32 * An color quantizer based on the Median-cut algorithm, but optimized for picking out distinct
35 * The color space is represented as a 3-dimensional cube with each dimension being an RGB
36 * component. The cube is then repeatedly divided until we have reduced the color space to the
37 * requested number of colors. An average color is then generated from each cube.
40 * have roughly the same population, where this quantizer divides boxes based on their color volume.
41 * This means that the color space is divided into distinct colors, rather than representative
90 for (int color = 0; color < hist.length; color++) {
91 if (hist[color] >
434 shouldIgnoreColor(Swatch color) argument
462 quantizeFromRgb888(int color) argument
478 approximateToRgb888(int color) argument
485 quantizedRed(int color) argument
492 quantizedGreen(int color) argument
499 quantizedBlue(int color) argument
[all...]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/cat/
H A DTextAttribute.java34 public TextColor color; field in class:TextAttribute
38 boolean strikeThrough, TextColor color) {
47 this.color = color;
36 TextAttribute(int start, int length, TextAlignment align, FontSize size, boolean bold, boolean italic, boolean underlined, boolean strikeThrough, TextColor color) argument
/frameworks/support/v17/leanback/src/android/support/v17/leanback/graphics/
H A DColorFilterCache.java23 * Cache of {@link ColorFilter}s for a given color at different alpha levels.
33 * Get a ColorDimmer for a given color. Only the RGB values are used; the
34 * alpha channel is ignored in color. Subsequent calls to this method
35 * with the same color value will return the same cache.
37 * @param color The color to use for the color filters.
38 * @return A cache of ColorFilters at different alpha levels for the color.
40 public static ColorFilterCache getColorFilterCache(int color) { argument
41 final int r = Color.red(color);
[all...]
/frameworks/base/packages/WallpaperCropper/src/com/android/gallery3d/glrenderer/
H A DGLPaint.java25 public void setColor(int color) { argument
26 mColor = color;
/frameworks/base/libs/hwui/
H A DFloatColor.h28 void set(uint32_t color) { argument
29 a = ((color >> 24) & 0xff) / 255.0f;
30 r = a * ((color >> 16) & 0xff) / 255.0f;
31 g = a * ((color >> 8) & 0xff) / 255.0f;
32 b = a * ((color ) & 0xff) / 255.0f;
/frameworks/base/core/java/com/android/internal/util/
H A DUserIcons.java34 R.color.user_icon_1,
35 R.color.user_icon_2,
36 R.color.user_icon_3,
37 R.color.user_icon_4,
38 R.color.user_icon_5,
39 R.color.user_icon_6,
40 R.color.user_icon_7,
41 R.color.user_icon_8
68 int colorResId = light ? R.color.user_icon_default_white : R.color
[all...]
H A DNotificationColorUtil.java81 * @return True if the bitmap is grayscale; false if it is color or too large to examine.
119 * @return True if the bitmap is grayscale; false if it is color or too large to examine.
158 * @return True if the bitmap is grayscale; false if it is color or too large to examine.
178 * @return The color inverted text.
206 // Allocate a new array so we don't change the colors in the old color state
225 private int processColor(int color) { argument
226 return Color.argb(Color.alpha(color),
227 255 - Color.red(color),
228 255 - Color.green(color),
229 255 - Color.blue(color));
242 findContrastColor(int color, int other, boolean findFg, double minRatio) argument
274 ensureLargeTextContrast(int color, int bg) argument
282 ensureTextContrast(int color, int bg) argument
289 ensureTextBackgroundColor(int color, int textColor, int hintColor) argument
303 resolveColor(Context context, int color) argument
392 calculateLuminance(@olorInt int color) argument
429 colorToLAB(@olorInt int color, @NonNull double[] outLab) argument
472 colorToXYZ(@olorInt int color, @NonNull double[] outXyz) argument
[all...]
/frameworks/support/v17/leanback/src/android/support/v17/leanback/widget/
H A DSearchOrbView.java39 * The background color and icon can be customized.
64 * Constructs a color set using the given color for the search orb.
67 * @param color The main search orb color.
69 public Colors(@ColorInt int color) { argument
70 this(color, color);
74 * Constructs a color set using the given colors for the search orb.
77 * @param color Th
80 Colors(@olorInt int color, @ColorInt int brightColor) argument
91 Colors(@olorInt int color, @ColorInt int brightColor, @ColorInt int iconColor) argument
101 public int color; field in class:SearchOrbView.Colors
118 getBrightColor(int color) argument
288 setOrbColor(int color) argument
298 setOrbColor(@olorInt int color, @ColorInt int brightColor) argument
362 setOrbViewColor(int color) argument
[all...]
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/
H A DListItem.java41 TypedValue color = new TypedValue();
42 int colorId = gainFocus ? android.R.attr.colorAccent : android.R.color.transparent;
43 getContext().getTheme().resolveAttribute(colorId, color, true);
45 findViewById(R.id.focus_indicator).setBackgroundColor(color.data);
/frameworks/base/packages/Keyguard/src/com/android/keyguard/
H A DSecurityMessageDisplay.java21 void setNextMessageColor(int color); argument
/frameworks/opt/colorpicker/src/com/android/colorpicker/
H A DColorStateDrawable.java25 * A drawable which sets its color filter to a color specified by the user, and changes to a
26 * slightly darker color when pressed or focused.
34 public ColorStateDrawable(Drawable[] layers, int color) { argument
36 mColor = color;
59 * Given a particular color, adjusts its value by a multiplier.
61 private static int getPressedColor(int color) { argument
63 Color.colorToHSV(color, hsv);
H A DColorPickerSwatch.java27 * Creates a circular swatch of a specified color. Adds a checkmark if marked as checked.
36 * Interface for a callback when a color square is selected.
41 * Called when a specific color square has been selected.
43 public void onColorSelected(int color); argument
46 public ColorPickerSwatch(Context context, int color, boolean checked, argument
49 mColor = color;
55 setColor(color);
60 protected void setColor(int color) { argument
63 mSwatchImage.setImageDrawable(new ColorStateDrawable(colorDrawable, color));
/frameworks/native/services/surfaceflinger/
H A DColorizer.h27 enum color { enum in class:android::Colorizer
41 void colorize(String8& out, color c) {
/frameworks/support/customtabs/tests/src/android/support/customtabs/
H A DCustomTabsIntentTest.java54 int color = Color.RED;
55 Intent intent = new CustomTabsIntent.Builder().setToolbarColor(color).build().intent;
57 assertEquals(color, intent.getIntExtra(CustomTabsIntent.EXTRA_TOOLBAR_COLOR, 0));
62 @ColorRes int colorId = android.R.color.background_dark;
63 int color = InstrumentationRegistry.getContext().getResources().getColor(colorId);
65 assertFalse("The color should not be a resource ID",
66 color == intent.getIntExtra(CustomTabsIntent.EXTRA_TOOLBAR_COLOR, 0));
67 intent = new CustomTabsIntent.Builder().setToolbarColor(color).build().intent;
68 assertEquals(color, intent.getIntExtra(CustomTabsIntent.EXTRA_TOOLBAR_COLOR, 0));
/frameworks/rs/driver/runtime/
H A Drs_convert.c66 float4 color = (float)y * 0.003921569f; local
70 color += fU * yuv_U_values;
71 color += fV * yuv_V_values;
72 color = clamp(color, 0.f, 1.f);
73 return color;
/frameworks/rs/java/tests/ImageProcessing2/src/com/android/rs/image/
H A Dposterize.rs24 uchar4 color;
31 color = hats;
38 return color;
/frameworks/rs/java/tests/ImageProcessing_jb/src/com/android/rs/image/
H A Dposterize.rs24 uchar4 color;
31 color = hats;
38 return color;
/frameworks/base/libs/hwui/tests/common/scenes/
H A DPartialDamageAnimation.cpp44 SkColor color = COLORS[static_cast<int>((y / dp(116))) % 4]; variable
47 [color](RenderProperties& props, TestCanvas& canvas) {
48 canvas.drawColor(color, SkXfermode::kSrcOver_Mode);
62 SkColor color = TestUtils::interpolateColor(
64 canvas.drawColor(color, SkXfermode::kSrcOver_Mode);

Completed in 2149 milliseconds

1234567891011>>