Image overlayed five consecutive times on a live video in vc++ - overlay

I m trying to overlay an image on a live video.I have used alpha blending method to overlay image on the video. On overlaying the image, it gets overlayed five times rather than one as expected.
Both frame data and the image data is taken as BYTE* for overlaying and displaying it.
The image used is a bitmap image.
The data (BYTE*) of both the video and the image is overlayed and the resultant is stored back in the variable of the video and den drawn on the picture control of vc++.
The video resolution is 640x480.
The image I m overlaying is 128x128.
The IDE used is visual studio professional.The code is developed using c++.
How do I overlay the bitmap image as a single image on the live video at a specific position.

Related

How can i crop a specific area of image using python

I wanted to crop a specific area of images, the images uploaded are of different dimensions but all have these areas so i want a python script that can crop actually that part and make a new image.
I am uploading the original pics too and the pics after cropping too, the output I want to achieve actually.
First original image
First cropped image
Sceond Original Image
Second cropped Image

Superimpose masked video onto video in Matlab

I currently have a video that has been selected out with a mask and saved as a separate video. The surrounded regions of the mask are all black. I want to superimpose this mask video onto another video of the same dimensions, replacing the black pixels with the pixels in the underlying video. Is this sort of thing possible in Matlab?
Any help would be greatly appreciated!
One easy way out could be to extract frames from both the videos and replace all the black pixels of the first video with the corresponding pixel values from the second video.

Image getting stretched when creating MBTiles using TileMills to use as an Image on Whirly Globe Framework

I am struck with issue .
I want to use My personal Image as an image on whirly globe.I used a Jpeg file and changed into .tiff file and added to Tile Mills as a Layer (Following the rules specified in the crash course of tile mills).Now i am facing an issue while exporting the image as MbTiles .
I looked into this Link for taking reference on what should be 'Dimensions' of the image to be used on whirly globe.
Right now i have an image whose dimensions are 10184X7638. But this image is not able to wrap the complete Whirly Globe.
Please guide me on
what the dimensions should be there of the image to be used for whirly globe.
can i use this values while creating a frame for the image as the image gets strected when is added to the globe .Image1
.
This is the Image i am talking about it has a dimensions of 10184 X 7638 pixels and when i select these bounds as specified Image1 (-180,-85.11,180,85).then i get this Image2
. Here you can see the image is not able to cover the complete bounds and hence the globe also is not fully wrapped with this image.
Thanks!!
The image is less about dimensions and more about mapping it to geographic coordinates so that it can completely cover the globe. You need to make sure the image takes up your whole TileMill map if you want it to completely cover the globe in WhirlyGlobe.

Use scaled and moved image from IPhone UIImagePickerController to match marks on overlay image and still match them after choose and merge them both

UIImagePickerController on edit in preview screen with an overlay image, after scale and move the taken or selected image, to match marks on overlay image, the result edited image don't seems to maintain aspect so when merge both, overlay image and edited image, the edited image don't match the marks on overlay image, like on preview after scale and move.
How can i make the edited image still match the marks of the overlay image, when merged into a single image?
I managed to do this without enable the edit on UIImagePickerController, when i take a picture with the iPhone camera, i can see the overlay image on screen, take the picture so it match the marks on the overlay image, and when i merge them both, the taken picture still match the marks on the overlay image. (I control the orientation and scale for the merge to be successful).
I also manage to get an overlay image on the preview screen(Scale and Move), after selecting a picture from device image library.
I'm using the info dictionary to obtain the UIImagePickerControllerEditedImage, when enable the allowsEditing property of the UIImagePickerController. Also am aware of the existence of the UIImagePickerControllerCropRect in the info dictionary and the differences between images taken by the device camera and saved images in device library, not necessarily taken with device.

iphone reduce large image loading time

Anybody know how to load the large image to become a blur image first and then only slowly load the full size of image. This will at least let the user to preview the image first other than waiting for a few second to load the full size image.
Thanks
You have to prepare two images, one is for blur image, and one is for the full size of image. As for the JPEG image with EXIF, it contains a thumbnail image inside. So the digital camera will show the thumbnail images when browsing.
Somehow I remember in Image processing class, professor told us that when browsing the web, the server would send your browser a blur image A, and another image B, after you getting both, your computer will be doing image computation on A&B to produce an intermediate image C and do computation on A&C produce another image...this procedure goes on for a couple times to get the original image. That's why you are seeing blurred image at the first place. This procedure theoretically reduce image size linearly.