• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# IImageProvider类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中IImageProvider的典型用法代码示例。如果您正苦于以下问题:C# IImageProvider类的具体用法?C# IImageProvider怎么用?C# IImageProvider使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IImageProvider类属于命名空间,在下文中一共展示了IImageProvider类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: ComponentManager

 public ComponentManager(IComponentConfiguration configuration, IImageProvider imageProvider,
     ICameraDevice cameraDevice)
 {
     device = cameraDevice;
     provider = imageProvider;
     componentConfiguration = configuration;
 }
开发者ID:rachwal,项目名称:RTM-Tools,代码行数:7,代码来源:ComponentManager.cs


示例2: LensTiltDepthOfFieldEffect

		/// <summary>
		/// Creates and initializes a new lens tilt depth-of-field effect.
		/// </summary>
		/// <param name="source">The source image to be blurred.</param>
		/// <param name="focusBand">The band that represents the focus area in the image. Pixels within this band won't be blurred. 
		/// Areas outside of the area will be progressively more blurred as the distance from the focus band increases..</param>
		/// <param name="blurStrengthAtEdge1">Strength of the blur on the Edge1 side of the focus band.</param>
		/// <param name="blurStrengthAtEdge2">Strength of the blur on the Edge2 side of the focus band.</param>
		public LensTiltDepthOfFieldEffect(IImageProvider source, FocusBand focusBand, double strengthAtEdge1, double strengthAtEdge2, DepthOfFieldQuality quality)
			: base(source, quality)
		{
			FocusBand = focusBand;
			StrengthAtEdge1 = strengthAtEdge1;
			StrengthAtEdge2 = strengthAtEdge2;
		}
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:15,代码来源:LensTiltDepthOfFieldEffect.cs


示例3: GetEffectInternalAsync

        protected override MaybeTask<IImageProvider> GetEffectInternalAsync(IImageProvider source, Size sourceSize, Size renderSize)
        {
            m_radialGradient.CenterPoint = new Point(m_centerX, m_centerY);
            m_radialGradient.EllipseRadius = new EllipseRadius(m_radiusX, m_radiusY);

            return new MaybeTask<IImageProvider>(m_gradientImageSource);
        }
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:7,代码来源:RadialGradientSourceEffectProcessor.cs


示例4: PrepareGroup

		protected sealed override IImageProvider PrepareGroup(IImageProvider groupSource)
		{
			m_mustGetNewSize = true;

			var blurCanBeApplied = TryPrepareLensBlurProperties();

			if (!blurCanBeApplied)
			{
				return Source;
			}

			LensBlurEffect.Source = groupSource;
			LensBlurEffect.KernelMap = KernelMapSource;
			LensBlurEffect.BlendKernelWidth = LensBlurEffect.Kernels.Max(w => w.Size) / 2;

			switch (Quality)
			{
				case DepthOfFieldQuality.Preview:
					LensBlurEffect.Quality = GetQualityForPreview();
					break;

				case DepthOfFieldQuality.Full:
					LensBlurEffect.Quality = GetQualityForFull();
					break;

				default:
					throw new NotImplementedException(String.Format("Quality {0} currently unsupported", Quality.ToString()));
			}

			m_quality.Reset();

			return LensBlurEffect;
		}
开发者ID:nagyistoce,项目名称:Lumia-Imaging-SDK-Extras,代码行数:33,代码来源:DepthOfFieldEffect.cs


示例5: WallpaperComposerParameters

 /// <summary>
 /// Initializes the WallpaperComposerParameters with a set of properties
 /// </summary>
 /// <param name="imageProvider">ImageProvider to be used by the WallpaperComposer</param>
 /// <param name="imageResizer">ImageResizer to be used by the WallpaperComposer</param>
 /// <param name="wallpaperProcessor">WallpaperProcessor to be used by the WallpaperComposer</param>
 public WallpaperComposerParameters(IImageProvider imageProvider,
     IImageResizer imageResizer, IWallpaperProcessor wallpaperProcessor)
 {
     this.ImageProvider = imageProvider;
     this.ImageResizer = imageResizer;
     this.WallpaperProcessor = wallpaperProcessor;
 }
开发者ID:mnstrspeed,项目名称:adhesive,代码行数:13,代码来源:WallpaperComposerParameters.cs


示例6: ClaudiaIDE

 /// <summary>
 /// Creates a square image and attaches an event handler to the layout changed event that
 /// adds the the square in the upper right-hand corner of the TextView via the adornment layer
 /// </summary>
 /// <param name="view">The <see cref="IWpfTextView"/> upon which the adornment will be drawn</param>
 /// <param name="imageProvider">The <see cref="IImageProvider"/> which provides bitmaps to draw</param>
 /// <param name="setting">The <see cref="Setting"/> contains user image preferences</param>
 public ClaudiaIDE(IWpfTextView view, IImageProvider imageProvider, Setting setting)
 {
     try
     {
         _dispacher = Dispatcher.CurrentDispatcher;
         _imageProvider = imageProvider;
         _view = view;
         _positionHorizon = setting.PositionHorizon;
         _positionVertical = setting.PositionVertical;
         _imageOpacity = setting.Opacity;
         _fadeTime = setting.ImageFadeAnimationInterval;
         _image = new Image
         {
             Opacity = setting.Opacity,
             IsHitTestVisible = false
         };
         _adornmentLayer = view.GetAdornmentLayer("ClaudiaIDE");
         _view.ViewportHeightChanged += delegate { RepositionImage(); };
         _view.ViewportWidthChanged += delegate { RepositionImage(); };
         _view.ViewportLeftChanged += delegate { RepositionImage(); };
         _imageProvider.NewImageAvaliable += delegate { _dispacher.Invoke(ChangeImage); };
         ChangeImage();
     }
     catch (Exception)
     {
     }
 }
开发者ID:brogowski,项目名称:ClaudiaIDE,代码行数:34,代码来源:ClaudiaIDE.cs


示例7: GameViewModel

        public GameViewModel(int totalQuestions, IImageProvider imageProvider, IStorageProvider storageProvider)
        {
            _imageProvider = imageProvider;
            _storageProvider = storageProvider;

            // register all the events
            CommandEvents.ContinueButtonPressed += new EventHandler(ContinueButtonPressed);
            CommandEvents.AnswerButtonPressed += new EventHandler(AnswerButtonPressed);
            CommandEvents.HighScoreContinueButtonPressed += new EventHandler(HighScoreContinueButtonPressed);
            DisplayHighScore += new EventHandler(DisplayScore);

            // check to see whether any game state is already loaded
            if (_storageProvider.GameStateExists())
            {
                _game = _storageProvider.LoadGameState();

                // check if the player was in the middle of a question
                if (_game.CurrentQuestion.Answered)
                {
                    DisplayQuestion();
                    ContinueButtonPressed(this, new EventArgs());
                }
                else
                {
                    DisplayQuestion();
                }
            }
            else
            {
                _game = new Game(totalQuestions);
                ContinueButtonPressed(this, new EventArgs());
            }
        }
开发者ID:simonguest,项目名称:wp7-flagmatch,代码行数:33,代码来源:GameViewModel.cs


示例8: ColorAdjustEffect

 public ColorAdjustEffect(IImageProvider source, double red = 0, double green = 0, double blue = 0)
     : base(source)
 {
     m_RedPercentage = red;
     m_GreenPercentage = green;
     m_BluePercentage = blue;
 }
开发者ID:Nokia-Developer-Community-Projects,项目名称:real-time-filter-demo,代码行数:7,代码来源:ColorAdjustEffect.cs


示例9: CreateFakeLayerContext

 private LayerContext CreateFakeLayerContext(Layer backgroundLayer, IImageProvider backgroundImage, Layer layer)
 {
     var invariants = new LayerContext.Invariants(backgroundLayer, new MaybeTask<IImageProvider>(backgroundImage), new Size(0, 0));
     var layerContext = new LayerContext(invariants, backgroundLayer, layer, 1);
     layerContext.PreviousImage = layerContext.BackgroundImage;
     return layerContext;
 }
开发者ID:nagyistoce,项目名称:Lumia-Imaging-SDK-Extras,代码行数:7,代码来源:AdjustmentLayerTest.cs


示例10: GetEffectInternalAsync

        protected override MaybeTask<IImageProvider> GetEffectInternalAsync(IImageProvider source, Size sourceSize, Size renderSize)
        {
            m_linearGradient.StartPoint = new Point(m_startX, m_startY);
            m_linearGradient.EndPoint = new Point(m_endX, m_endY);

            return new MaybeTask<IImageProvider>(m_gradientImageSource);
        }
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:7,代码来源:LinearGradientGradientSourceEffectProcessor.cs


示例11: RecipeCSharpEffect

        public RecipeCSharpEffect(IImageProvider source, double factor)
            : base(source)
        {
            effect = new CSharp.MyEffect(source, factor);

             SetPipelineBeginEnd(effect, effect);
        }
开发者ID:Nokia-Developer-Community-Projects,项目名称:wp8-sample,代码行数:7,代码来源:RecipeCSharpEffect.cs


示例12: ClaudiaIDE

        /// <summary>
        /// Creates a square image and attaches an event handler to the layout changed event that
        /// adds the the square in the upper right-hand corner of the TextView via the adornment layer
        /// </summary>
        /// <param name="view">The <see cref="IWpfTextView"/> upon which the adornment will be drawn</param>
        /// <param name="imageProvider">The <see cref="IImageProvider"/> which provides bitmaps to draw</param>
        /// <param name="setting">The <see cref="Setting"/> contains user image preferences</param>
        public ClaudiaIDE(IWpfTextView view, List<IImageProvider> imageProvider, Setting setting)
		{
		    try
		    {
		        _dispacher = Dispatcher.CurrentDispatcher;
                _imageProviders = imageProvider;
                _imageProvider = imageProvider.FirstOrDefault(x=>x.ProviderType == setting.ImageBackgroundType);
                _setting = setting;
                if (_imageProvider == null)
                {
                    _imageProvider = new SingleImageProvider(_setting);
                }
                _view = view;
                _image = new Image
                {
                    Opacity = setting.Opacity,
                    IsHitTestVisible = false
                };
                _adornmentLayer = view.GetAdornmentLayer("ClaudiaIDE");
				_view.ViewportHeightChanged += delegate { RepositionImage(); };
				_view.ViewportWidthChanged += delegate { RepositionImage(); };     
                _view.ViewportLeftChanged += delegate { RepositionImage(); };
                _setting.OnChanged += delegate { ReloadSettings(); };

                _imageProviders.ForEach(x => x.NewImageAvaliable += delegate { InvokeChangeImage(); });

                ChangeImage();
            }
			catch
			{
			}
		}
开发者ID:liange,项目名称:ClaudiaIDE,代码行数:39,代码来源:ClaudiaIDE.cs


示例13: GetChain

        private List<IImageProvider> GetChain(IImageProvider tail)
        {
            List<IImageProvider> chain = new List<IImageProvider>();

            if (tail == null)
                return chain;

            chain.Add(tail);
            var imageConsumer = tail as IImageConsumer;

            while (imageConsumer != null)
            {
                var imageProvider = imageConsumer.Source;

                if (imageProvider == null)
                    break;

                chain.Add(imageProvider);

                imageConsumer = imageProvider as IImageConsumer;
            }

            chain.Reverse();

            return chain;
        }
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:26,代码来源:LayerListTest.cs


示例14: GetEffectInternalAsync

        protected override MaybeTask<IImageProvider> GetEffectInternalAsync(IImageProvider source, Size sourceSize, Size renderSize)
        {
            ((IImageConsumer)Effect).Source = source;
            ((SpotlightEffect)Effect).Position = new Windows.Foundation.Point(sourceSize.Width / 2, sourceSize.Height / 2);

            return new MaybeTask<IImageProvider>(Effect);
        }
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:7,代码来源:SpotlightFilterProcessor.cs


示例15: RecipeCSharpFilter

        public RecipeCSharpFilter(IImageProvider source, double factor)
            : base(source)
        {
            effect = new FilterEffect(source);
            effect.Filters = new IFilter[]{new CSharp.MyFilter (factor)};

             SetPipelineBeginEnd(effect, effect);
        }
开发者ID:Nokia-Developer-Community-Projects,项目名称:wp8-sample,代码行数:8,代码来源:RecipeCSharpFilter.cs


示例16: GrayscaleNegativeEffect

 public GrayscaleNegativeEffect(IImageProvider source, double red = 0.2126, double green = 0.7152, double blue = 0.0722)
     : base(source)
 {
     // Self correct negative percentages to just zero them out and ensure no percentage goes above 1.0 (100%)
     m_RedPercentage = (red < 0.00) ? 0.00 : (red > 1.00) ? 1.00 : red;
     m_GreenPercentage = (green < 0.00) ? 0.00 : (green > 1.00) ? 1.00 : green;
     m_BluePercentage = (blue < 0.00) ? 0.00 : (blue > 1.00) ? 1.00 : blue;
 }
开发者ID:Nokia-Developer-Community-Projects,项目名称:real-time-filter-demo,代码行数:8,代码来源:GrayscaleNegativeEffect.cs


示例17: GetEffectInternalAsync

        protected override MaybeTask<IImageProvider> GetEffectInternalAsync(IImageProvider source, Windows.Foundation.Size sourceSize, Windows.Foundation.Size renderSize)
        {
            m_RgbMixerEffect.Source = source;
            

            return new MaybeTask<IImageProvider>(m_RgbMixerEffect);
            
        }
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:8,代码来源:RgbMixerEffectProcessor.cs


示例18: CustomEffectViewModel

 public CustomEffectViewModel(IImageProvider effect)
 {
     Effect = effect;            
     m_writeableBitmap = new WriteableBitmap(100, 100);
     m_renderer = new WriteableBitmapRenderer(Effect, m_writeableBitmap);
     MinValue = 0;
     MaxValue = 1;
 }
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:8,代码来源:CustomEffectViewModel.cs


示例19: QuadTransformation

        public QuadTransformation(IImageProvider source, Size size, QuadDirection direction, EdgePoints edgePoints)
            : base(source)
        {
            Direction = direction;
            Size = size;

            EdgePoints = edgePoints;
        }
开发者ID:Nokia-Developer-Community-Projects,项目名称:real-time-filter-demo,代码行数:8,代码来源:QuadTransformation.cs


示例20: EffectProcessor

 public EffectProcessor(string name, IImageProvider effect, bool canRenderAtPreviewSize = true, bool useCustomRangeEditor = false)
 {
     m_useCustomRangeEditor = useCustomRangeEditor;
     CanRenderAtPreviewSize = canRenderAtPreviewSize;
     Name = name;
     Effect = effect;          
     AddEditors();
 }
开发者ID:modulexcite,项目名称:Lumia-imaging-sdk,代码行数:8,代码来源:FilterProcessor.cs



注:本文中的IImageProvider类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# IImageService类代码示例发布时间:2022-05-24
下一篇:
C# IImageProcessor类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap