image-masking

RGBStroke - Image pixels instead of color (iOS)

狂风中的少年 提交于 2019-12-24 19:09:55
问题 I am implementing a image mask kind of feature in iOS similar to what is offered in the Blender app with two images. Here is my touch move code :- - (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event { UITouch *touch = [touches anyObject]; CGPoint currentPoint = [touch locationInView:staticBG1]; UIGraphicsBeginImageContext(view.frame.size); [image_1 drawInRect:CGRectMake(0, 0, view.frame.size.width, view.frame.size.height)]; CGContextSetLineCap(UIGraphicsGetCurrentContext(),

CSS image mask broken in Cordova for iOS 11.x?

流过昼夜 提交于 2019-12-23 01:45:09
问题 I use -webkit-mask-image in my meteor app, like this: ... background-color: purple; -webkit-mask-image: url('images/user_plum.png'); ... It works fine in all browsers. It works fine in the cordova version on Android. It was working fine in iOS Cordova. Now, only in iOS, all of my icons that use this technique are invisible, even though they are still clickable and functioning. The problem was found on two users' iPhones and I reproduced it in iOS Simulator. My iPhone worked fine. Uninstall

Overlapping happening instead of uploading image on mask

ぃ、小莉子 提交于 2019-12-13 11:29:46
问题 Background I am allowing user to upload an image inside mask image.... Mask image : User uploaded image : Requirement : What I need as below : Issue : What I am getting now as below : The uploaded image is displaying [ overlay ] outside the mask image instead of inside as below. JS Fiddle: http://jsfiddle.net/uLfeaxck/ Here is website url html <h3>Upload Photo</h3> <label id="btn_upload_from_computer" for="fileupload_image" class="button -primary -size-md -full-width"> <svg class="icon

Circular mask in Matlab

我的梦境 提交于 2019-12-13 08:58:48
问题 I create six circle for masking in Matlab. Each of mask's inner and outer radiuses are different. These masks is used to detect parasites on the slide. I have this code (one of the masks) but I want to do white area between to circle that in shared image. How can I do that? or Have another way to do mask that shared picture? MidpointCircle.m resize_factor = 1; inner_rad = 15*4/resize_factor; outer_rad = 20*4/resize_factor; ec_2 = floor(0.5*(outer_rad+inner_rad)*2*pi); center = outer_rad+2;

Create a radial gradient mask to create a hole in the picture

本秂侑毒 提交于 2019-12-12 01:43:54
问题 I want to create a radial gradient mask to create a hole in the picture, so that you can see through the picture. I created an overlaying image with a hole and the image beneath is visible, like below: I am able to create this image using CGImageMaskCreate() successfully. But due to the unusual behaviour of CGImageMaskCreate() in iOS 10.0, I am looking for another solutions. One such solution is to create image mask using the UIView's maskView property. I am able to write the code for

Crop image in swift

家住魔仙堡 提交于 2019-12-11 10:48:05
问题 I am trying to crop image in swift. I'm trying to implement something like, user will capture a photo. Once photo is captured user will be allowed to set the crop area. I'm able to get the image from that crop area, but I want that the crop image should be resized to particular width and height. That is, if particular height or width is smaller then it should be resized. This image should be of frame of it's maximum width and height. Currently it is just adding transparency to the other area.

Using skimage for non-rectangular image areas

纵然是瞬间 提交于 2019-12-11 05:47:26
问题 Let's say I'm concerned with part of an image that I'm wanting to calculate a GLCM for that's not rectangular. How should I go about this? I've made a masking procedure that zeroes out the portion of the image that I don't care about, I just don't know how to take this "masked" image without considering the zeroed out portions of the image... Thanks for your help! 回答1: If you are able to assign the zero intensity value to background pixels, you can obtain the GLCM of the region of interest by

Remove receipt image border using ImageMagick

折月煮酒 提交于 2019-12-07 04:07:17
问题 I'm using ImageMagick service to pre-process the receipt image before using tesseract-OCR engine to extract texts. I need to remove the background of the receipts. I've gone through masking to remove the border here. But I'm unable to create the mask for the receipts. However, I've tried to remove shadows from the receipt images. Initial Image (Example receipt) convert input.png -colorspace gray \ \( +clone -blur 0x2 \) +swap -compose divide -composite \ -linear-stretch 5%x0% photocopy.png

CSS image mask broken in Cordova for iOS 11.x?

若如初见. 提交于 2019-12-06 16:30:31
I use -webkit-mask-image in my meteor app, like this: ... background-color: purple; -webkit-mask-image: url('images/user_plum.png'); ... It works fine in all browsers. It works fine in the cordova version on Android. It was working fine in iOS Cordova. Now, only in iOS, all of my icons that use this technique are invisible, even though they are still clickable and functioning. The problem was found on two users' iPhones and I reproduced it in iOS Simulator. My iPhone worked fine. Uninstall/reinstall of the app, rebuild/restart of the server, etc., nothing changed. Until I updated my phone to

advanced usage of matlab roipoly command

别等时光非礼了梦想. 提交于 2019-12-06 13:54:34
问题 I am new to matlab and am working on Image processing. I am using the roipoly function to create a mask. As I understand I can use it like this : I = imread('eight.tif'); c = [222 272 300 270 221 194]; r = [21 21 75 121 121 75]; BW = roipoly(I,c,r); figure, imshow(I) figure, imshow(BW) The image is shown below : One observation I had was that the interpolation between the adjacent points as specified by the c & r matrix is done by 'Linear Interpolation', in other sense always a straight line