php gd library to reveal background image - overlay

I have two identical sized images that I would like to work with. One image is in color, the other is in black and white. I need assistance on stacking the color image directly over the black and white image. After that, I would like to be able to remove sections of the top photo to reveal the image underneath.
Can someone point me in the right direction on how to accomplish this?

Here is something that may help:
http://forums.devshed.com/php-development-5/how-do-i-merge-various-images-into-one-using-gd-502604.html
Especially the part that talks about adding watermarking.
You will have to add transparent areas to the top image before combining them.
lee

Related

Getting a round blur halo around a square button in order to place over an image

I updated this with an image of what I am trying to achieve, its a blur on a image which adds a touch of shading and even white on white is visible. I am basically working on putting buttons of various kinds on top of images and welcome's any and all assistance on best practices. I know facebook does this in some way as an app example.
To summarize what I am trying to achieve. I have an image that takes up the full screen and I would like to place a button on top of that image that does something like blur around it with padding so that it looks clean on top of the image. My button is a heart png, red outline with clear inside, and is represented as a square because of the irregular shape. I would like the heart to be on top of a circle that does something like blur the image so it can always be seen.
I found a number of similar solutions to this problem using UIBlurEffect but nothing that specifically addresses the "square image" and how I would control making the blur circle larger/smaller in terms of the padding around the square. I tinkered with creating a UIView that was transparent, placing a circle with a blur into there and then adding the button with their centers aligned but this seems like an incorrect approach and wasn't quite working. I suspect that for people with expertise this is something where I just need to have the correct usage of the UIBlurEffect.

Unity sprites don't render properly

I recently came across a problem I can't solve which involves not being able to draw my sprites properly. I have tried a lot of different things and couldn't find any solution.
Here is how the image should look like in unity:
And here is how it actually looks like:
If someone could tell me how to fix this, I would be very grateful.
Presumably the top image is a screenshot of your image manipulation program, many of which use the chequerboard pattern to mean transparency. As such, the image you have exported is a gradient going from almost solid white at the bottom to transparent at the top. This is why the image appears as such in Unity.
Also, if you're wondering why the image appears as though it has bands of different colours, this is due to a problem called colour banding. This can be fixed by using a technique called Dither (which adds some noise to the image), but how you do so will depend on which image manipulation program you are using.

Why images in XIB are different?

At left there's the original image (after imported in Xcode), at right the image inside UIImageView. It's more dark.
Why this? It's a very annoying problem.
Man! Its just an illusion.
Don't ask "magic" related questions here. Ask only program related questions ;-)
Both images are of same color. They look different because their background colors are different. Use Photoshop or some other tool to find the colors of those two. They should be the same.
Its because the background colours are different and the stroke on the image is the same / similar colour to the background.
Change the background colour of the view to white, and it will look normal.

thick shadow with no blur on UILabel

I am trying to add a thick shadow to a UILabel, without any blur. In photoshop I would use the "Spread" option to make the shadow look like this. It's for a comic book themed UI in an app I am developing. I cannot use images as the text is dynamic and different for each user.
Here is what I am after (on the left) and here is as far as I have gotten so far with CGShadowWithColor (on the right):
Anyone know how I can achieve this result?
A quick hack to try would be to have several black UILabels below the white one, each offset slightly.

Free bitmaps for iOS custom buttons and sliders?

First, I'm not talking about icon libraries or mockup tools/libraries.
I'm familiar with various icon libraries that people have created, but other than the stuff from the example code like UICatalog, I'm wondering if anyone knows of anyone who has created free libraries of custom button bitmaps (stretchable button images), slider handle/track bitmaps, etc Basically bitmaps to customize the look of standard controls for those controls (like buttons and sliders) that allow you to specify such bitmaps.
I'm also interested in any photoshop tutorials/templates on/for creating stretchable custom button images, bitmaps for slider parts, etc. (Afraid I'm not a huge PS god or anything.)
Anyone know of any resources like this for fancying up the standard controls?
I've been able to find several stretchable buttons by searching through my collections of sample code for: "stretchableImageWithLeftCapWidth"
From the Apple sample code, the UICatalog, BubbleLevel, iPhoneMultichannelMixerTest, avTouch, AQOffilineRenderTest, and TouchCells sample code all contain buttons with stretchable images.
Hope this helps!
Stretchable buttons is no problem - there's nothing special you need to do in Photoshop. Just make the image of the button stretchable and set the radius to that of any rounded corners you have on the button graphic.
Slider parts - I'm pretty sure you'd have to make your own UIControl from scratch.
To make a button in Photoshop, create a new file with transparent background, select the Shape tool, rectangle near the bottom of the tools, drag out a rectangle. Size doesn't matterâ„¢. For a rounded rectangle, click and hold the same tool, choose the rounded rect shape and set a corner radies (same radius as in stretchableImage later).
Double-click the layer right of the layer name to get the layer style popup. Check Color Overlay and set the color you want. Check Inner Bevel and make its size somewhere below half the height of the rectangle - I think 90 degrees for the Global Angle works well. A lower opacity and larger size makes the bevel look less chunky.
Ctrl-click (option-click) the graphics rectangle in your layer to select the button's outline. Deselect the bottom half of it by using the marquee tool (M) at the top of the tools. Select a light gray foreground color, nearly white. Create a new layer with the square icon under the layer list (Windows->Layers if not visible). Fill the selection of the new layer with the paint bucket, and drag down opacity for the layer until the 'matte laquer' effect of it looks right.
A simple button, but that's the gist of it.