示例#1
0
        /// <summary>
        /// Set a 2 sample filter
        /// </summary>
        /// <param name="filter"></param>
        public void SetFilter(ref Filter2Sample filter)
        {
            this.filter[0] = new Vector3(filter.PixelOffset0, filter.Weight0);
            this.filter[1] = new Vector3(filter.PixelOffset1, filter.Weight1);

            kernelSize = 2;
        }
		/// <summary>
		/// Set a 2 sample filter
		/// </summary>
		/// <param name="filter"></param>
		public void SetFilter(ref Filter2Sample filter)
		{
			this.filter[0] = new Vector3(filter.PixelOffset0, filter.Weight0);
			this.filter[1] = new Vector3(filter.PixelOffset1, filter.Weight1);

			kernelSize = 2;
		}
示例#3
0
 /// <summary>
 /// Creates a single pass 2 sample filter
 /// </summary>
 /// <param name="source">soure texture to filter</param>
 /// <param name="target">target to filter</param>
 /// <param name="filter">Filter to apply</param>
 public SinglePassTextureFilter(DrawTargetTexture2D source, DrawTargetTexture2D target, Filter2Sample filter)
     : this(source, target)
 {
     SetFilter(ref filter);
 }
		/// <summary>
		/// Creates a single pass 2 sample filter
		/// </summary>
		/// <param name="source">soure texture to filter</param>
		/// <param name="target">target to filter</param>
		/// <param name="filter">Filter to apply</param>
		public SinglePassTextureFilter(DrawTargetTexture2D source, DrawTargetTexture2D target, Filter2Sample filter)
			: this(source, target)
		{
			SetFilter(ref filter);
		}