Original: HTML5 Erase effect for eraser Disclaimer: This article is original article, if need reprint, please indicate source waxes, thank you! Recently the project just used this effect, that is, a bit like a scratch card, on the mobile device, a picture is scraped off to show another picture. As follows:Demo Please poke right:demo This is quite common on the Internet, originally wanted to directly online to find a demo to apply his method on the
Text watermark
Text watermark is to add text on the picture, mainly using the Imagefttext method of GD library, and need font file. The effect chart is as follows:
The implementation code is as follows:
Copy Code code as follows:
$dst _path = ' dst.jpg ';
Create an instance of a picture$DST = imagecreatefromstring (file_get_contents ($DST _path));
Make a text$font = './SIMSUN.TTC ';//fo
PS How to use the background eraser Fast Hair (text)
1. Run PS and open a picture that needs to be processed.
2. First pull out the main part of the model, the body part, the edge of hair within the area. (This step-by-step method, in the first lesson of the time has been said, here will not elaborate)
3. After you pull out the main body, press Ctrl+j to copy the newly created selection to the new layer.
4. Go b
The drawing effect of the process has no channel or extraction filter to pull out the graph with high precision. General idea: The author first analyzes the material map, according to the background color divided into several blocks, and then separate the selection out of the eraser and masks and other tools to erase the background, and then combined.
Original
Final effect
1, with Photoshop This will be done to pull the long Mao of the material pic
JS+HTML5 Canvas implementation of the graffiti artboard effects, adjustable brush color | thickness | Eraser, you can save graffiti effect for image coding, very suitable for learning HTML5 canvas, must support HTML5 browser to see the effect.
Copy Code code as follows:
Please select a brush color:
Please select the width of the brush:
These two days to help colleagues test composite pictures and text effect, picture synthesis no problem, but the composition of the text, encountered a little problem, Chinese has been garbled, began to think that no header declaration Utf-8, plus after the discovery or not, Then the text to be generated with iconv turned into utf-8 or not, searched, and finally found that the use of the generated text function has a problem, before the use of this imagestring (), it seems that the function of t
Text Watermark
Text watermark is to add text on the picture, the main use of GD library Imagefttext method, and the need for font files. As follows:
The implementation code is as follows:
Copy the Code code as follows:$dst _path = ' dst.jpg ';
Create an instance of a picture$DST = imagecreatefromstring (file_get_contents ($DST _path));
Make a text.$font = './SIMSUN.TTC ';//font$black = Imagecolorallocate (
Imagema to add a watermark to the image, the watermark image will change the reason: the color space of the picture does not correspond to the watermark is the original CMYK watermark (actually a composite picture) command: Convert e:\1.jpg e:\water.png-gravity Southeast-geometry +10+10-composite e:\1-1.jpg Original
Header ("Content-type:image/png"); /* Notify browser, to output image */
$im = Imagecreate (400, 300); /* Define the size of the image */
$gray = Imagecolorallocate ($im, 235, 235, 235);
$pink = Imagecolorallocate ($im, 255, 128, 255);
$fontfile = "Simkai.ttf";
/* $fontfile the path to the font, depending on the operating system, can be Simhei.ttf (bold), Simkai. TTF (in italics), Simfang. TTF (imitation), SimSun. TTC (Arial XXFarEastFont-Arial) and other GD-s
PHP plus picture watermark, Text watermark Class code, PHP plus watermark class, support the text image watermark Transparency settings, watermark picture background transparent. Write a class of their own, because the development of a set of CMS to use, the total feeling of
/*'-##########################################-|'| Program design: (Green Bamboo Residence) |'| Msn:[email]lzj_zhangjun@hotmail.com[/email] |'| email:cszjun@gmail.com |'| Combine their previous upload and build abbreviations and adapt a'| The old-timers create a picture watermark made this |'| Upload + Generate thumbnails + Generate text watermark and image watermark
Article Description: experience sharing: The key points of watermark camera material design.
Watermark Camera (Professional Edition) has been released for nearly half a year, the watermark has more than 130. In the design process of watermark material, the team often think about what kind of design can get
/*
* Function: PHP image watermark (watermark supports picture or text)
Parameters
* $groundimage background image, that is, need to add a watermark image, temporarily only support gif,jpg,png format;
* $waterpos watermark position, there are 10 kinds of states, 0 is a random position;
* For th
picture plus a store marked watermark is very important! Plus the image of the watermark can not only play a role in emphasizing the attribution of goods, but also can play a role in preventing the theft of photos, this is the real picture of the seller is very important!
I put the watermark into a full map watermark
Insert dense watermark and QR code in Word and Excel, and wordexcel watermark
The customer recently asked to develop a feature:
After a file is uploaded to the system, an intensive watermark and two-dimensional code are automatically added to each page of the document. After printing the paper document, the system scans the two-dimensional code to automatically o
Phpgd2 uploads image text watermark, image watermark, and other proportional thumbnail source code. For more information, see.
The code is as follows:
// Upload file type list
$ Uptypes = array (
'Image/jpg ',
'Image/jpeg ',
'Image/png ',
'Image/pjpeg ',
'Image/GIF ',
'Image/bmp ',
'Image/x-png'
);
$ Max_file_size = 200000; // size limit of uploaded files, in bytes
$ Path_im = "prod_img/"; // generate a l
Everyone knows that the image is stolen is a very angry thing. Many times the hard work of publicity pictures, Taobao product description or merchandise taken photos and so mercilessly stolen after the other people's watermark let us chilling unceasingly. Today to bring you a piece of Photoshop to create a picture watermark tutorial, to facilitate everyone to the picture to play their own unique label.
Fir
The request received is to match the watermark on a graph and replace the original watermark with a new one.The first one to install a library file code is as follows:# Coding=utf-8import Cv2import NumPy as np# expansion algorithm kernel_dilate_kernel = Np.array ([[0, 0, 1, 0, 0], [0, 0, 1, 0, 0], [1, 1, 1, 1, 1], [0, 0, 1, 0, 0], [0, 0, 1, 0, 0]], dtype=np.uint8) class Watermar
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.