blur

jQuery blur and the enter key

时光毁灭记忆、已成空白 提交于 2019-12-03 15:04:21
问题 I am trying to update a div dynmically with a googlemap based on a zip code being entered. Its working fine if the user tabs away from the input box (id ZipCode) but if they press enter it doesn't blur the field. I have got a variation on this working with onkeyup, but one event calls the other and its a mess. Is it possible to kick the function off if either event occurs. $(document).ready(function() { $("#ZipCode").blur(function() { $("#dynamic").load('googlemap.php', {zipcode: $('#ZipCode'

AngularJS submit on blur and blur on keypress

倖福魔咒の 提交于 2019-12-03 13:58:54
I want to submit some data to the server when a input field is blurred. The User should also be able to blur the input field by pressing enter. Unfortunately this results in the following: $rootScope:inprog: $apply already in progress error . Plunkr - thanks in advance! Here's what's happening: You press enter ng-keydown triggers (digest begins) You call target.blur() ng-blur triggers and attempts to start another digest cycle Angular complains The blur is executed synchronously and immediately triggers the handler without finishing the first digest. In my opinion, this is not a problem with

How to Blur effect apply on UIView in iOS?

北战南征 提交于 2019-12-03 12:40:03
In my application i want to apply blur effect on uiview.So how can i achive blur effect. I tried by below code: UIGraphicsBeginImageContext(scrollview.bounds.size); [scrollview.layer renderInContext:UIGraphicsGetCurrentContext()]; UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext(); UIGraphicsEndImageContext(); //Blur the UIImage with a CIFilter CIImage *imageToBlur = [CIImage imageWithCGImage:viewImage.CGImage]; CIFilter *gaussianBlurFilter = [CIFilter filterWithName: @"CIGaussianBlur"]; [gaussianBlurFilter setValue:imageToBlur forKey: @"inputImage"]; [gaussianBlurFilter setValue

Blurring effect disappeared on iOS 7.1

送分小仙女□ 提交于 2019-12-03 09:48:10
问题 For some reason the blur effect is gone from my app on iOS 7.1. I'm running the same code on a device with iOS 7.0.x and on another with 7.1. Here's what I see: iOS 7.0.x iOS 7.1 What can be the issue and how to fix this? (obviously I want to keep the blur effect :)) UPDATE: This is the color I set: [UIColor colorWithRed:255.0f/255.0f green:201.0f/255.0f blue:0.0f/255.0f alpha:1.0]; and I set it from the barTintColor property 回答1: Probably the second screenshot is taken from an iPhone 4 ? On

Blur effect using slider Is not working properly

拈花ヽ惹草 提交于 2019-12-03 09:03:11
I have used a slider for blur effect to my image. I am using the following code: let currentFilter = CIFilter(name: "CIGaussianBlur") let beginImage = CIImage(image: imgImage.image!) currentFilter!.setValue(beginImage, forKey: kCIInputImageKey) currentFilter!.setValue(sender.value, forKey: kCIInputRadiusKey) let cropFilter = CIFilter(name: "CICrop") cropFilter!.setValue(currentFilter!.outputImage, forKey: kCIInputImageKey) cropFilter!.setValue(CIVector(cgRect: beginImage!.extent), forKey: "inputRectangle") let output = cropFilter!.outputImage let cgimg = context.createCGImage(output!, from:

Gaussian blur and convolution kernels

筅森魡賤 提交于 2019-12-03 08:52:07
问题 I do not understand what a convolution kernel is and how I would apply a convolution matrix to pixels in an image (I am talking about doing a Gaussian Blur operation on an image). Also could I get an explanation on how to create a kernel for a Gaussian Blur operation? I am reading this article but I cannot seem to understand how things are done... Thanks to anyone who takes time to explain this to me :), ExtremeCoder 回答1: The basic idea is that the new pixels of the image are created by an

CIGaussianBlur image size

一个人想着一个人 提交于 2019-12-03 08:24:24
问题 Hey want to blur my view, and i use this code: //Get a UIImage from the UIView NSLog(@"blur capture"); UIGraphicsBeginImageContext(BlurContrainerView.frame.size); [self.view.layer renderInContext:UIGraphicsGetCurrentContext()]; UIImage *viewImage = UIGraphicsGetImageFromCurrentImageContext(); UIGraphicsEndImageContext(); //Blur the UIImage CIImage *imageToBlur = [CIImage imageWithCGImage:viewImage.CGImage]; CIFilter *gaussianBlurFilter = [CIFilter filterWithName: @"CIGaussianBlur"];

Simple way to check if an image bitmap is blur

青春壹個敷衍的年華 提交于 2019-12-03 07:52:19
问题 I am looking for a "very" simple way to check if an image bitmap is blur. I do not need accurate and complicate algorithm which involves fft, wavelet, etc. Just a very simple idea even if it is not accurate. I've thought to compute the average euclidian distance between pixel (x,y) and pixel (x+1,y) considering their RGB components and then using a threshold but it works very bad. Any other idea? 回答1: Don't calculate the average differences between adjacent pixels. Even when a photograph is

Android, Blur Bitmap instantly?

戏子无情 提交于 2019-12-03 07:43:59
问题 So I'm trying to blur an image as fast as possible(instant feel like), as the activity needs to be updated as I press the Blur button. The problem I am having is that, I cannot find a Blur that works quick enough... Note: The blur, preferably a Gaussian blur, doesn't need to be the best quality at all.. I tried out the following, but it takes a few seconds, is there anyway this code could be made to run quicker in sacrifice of quality ? Or are there any other alternatives? I would look into

Android Blur View (Blur background behind the view)

一世执手 提交于 2019-12-03 07:38:12
问题 I am trying to make the bottom part of an Image blur for the view on top it like in the image. I tried blurring it using Rendenscript but I am not able to blur only the part behind the view. :( I have seen many libraries but almost all of them blur the entire image, but not a part of it. Also, an important part is that I am using this inside a ViewPager and hence needs to be fast and dynamic something like this in IOS which redraws itself the moment image behind it changes. Any help is