internal void FromColorFilter(ColorFilter cf) { this.SetAllNull(); if (cf.FormatId != null) this.FormatId = cf.FormatId.Value; if (cf.CellColor != null && !cf.CellColor.Value) this.CellColor = cf.CellColor.Value; }
void Awake() { playerScript = GameObject.Find("Player").GetComponent<PlayerScript>(); playerAnimator = GameObject.Find("Player").GetComponent<Animator>(); normalSpeed = Time.timeScale; colorFilter = GameObject.Find("ColorFilter").GetComponent<ColorFilter>(); }
internal ColorFilter ToColorFilter() { ColorFilter cf = new ColorFilter(); if (this.FormatId != null) cf.FormatId = this.FormatId.Value; if (this.CellColor != null && !this.CellColor.Value) cf.CellColor = this.CellColor.Value; return cf; }
private ColorComponentFilter _CreateFilter(ColorFilter colorFilter) { switch(colorFilter) { case ColorFilter.Red: return new RedFilter(); case ColorFilter.Green: return new GreenFilter(); case ColorFilter.Blue: return new BlueFilter(); case ColorFilter.Yellow: return new YellowFilter(); case ColorFilter.White: return new WhiteFilter(); default: return new NoFilter(); } }
public ColorData() { FilterOrder = new ColorFilter[0]; }
void Awake() { //フィルターのキャッシュを作成 filter = GameObject.Find("ColorFilter").GetComponent<ColorFilter>(); }
public override void SetColorFilter(ColorFilter cf) { paint.SetColorFilter(cf); }
public override void SetColorFilter(ColorFilter cf) { }
public override void SetColorFilter(ColorFilter cf) { // do nothing }
void Unloaded(object sender, VisualTreeAttachmentEventArgs e) => _filter = null;
/// <summary> /// Gets a rectangle containing the minimap with the non-minimap corners set to false /// </summary> /// <param name="filter">the filter to use on the minimap</param> /// <returns>true for the pixels on the minimap that match the filter</returns> public bool[,] MinimapFilter(ColorFilter filter) { Point offset; return(MinimapFilter(filter, out offset)); }
private async Task <List <Color> > DynamicSelect(IQueryable <ColorDAO> query, ColorFilter filter) { List <Color> Colors = await query.Select(q => new Color() { Id = filter.Selects.Contains(ColorSelect.Id) ? q.Id : default(long), Code = filter.Selects.Contains(ColorSelect.Code) ? q.Code : default(string), Name = filter.Selects.Contains(ColorSelect.Name) ? q.Name : default(string), }).ToListAsync(); return(Colors); }
/// <summary> /// Creates a series of test images to visual how a color filter works /// </summary> /// <param name="filter">color filter to test</param> /// <param name="directory">directory in which to save test images</param> /// <param name="name">base name for test images</param> /// <param name="readWindow">Set to true to always read the window</param> protected void MaskTest(ColorFilter filter, string name = "maskTest", string directory = "C:\\Projects\\Roboport\\test_pictures\\mask_tests\\", bool readWindow = false) { Screen.MakeSureWindowHasBeenRead(); bool[,] thing = Vision.ColorFilter(filter); DebugUtilities.TestMask(Screen.Bitmap, Screen, filter, thing, directory, name); }