CN103729829A - Rendering method and device for color image line drawing - Google Patents
Rendering method and device for color image line drawing Download PDFInfo
- Publication number
- CN103729829A CN103729829A CN201310684284.6A CN201310684284A CN103729829A CN 103729829 A CN103729829 A CN 103729829A CN 201310684284 A CN201310684284 A CN 201310684284A CN 103729829 A CN103729829 A CN 103729829A
- Authority
- CN
- China
- Prior art keywords
- image
- pixel
- module
- gaussian blur
- coloured
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Facsimile Image Signal Circuits (AREA)
- Image Processing (AREA)
Abstract
The invention discloses a rendering method for color image line drawing. The rendering method comprises the steps of obtaining an image A, conducting normalization processing on the image A to obtain an image A1, conducting graying processing on the image A1 to obtain an image a, conducting Gaussian blur on the image a to obtain an image b, combining the image a with the image b to obtain an image c, conducting enhancement processing on the image c to obtain an image B, and outputting the image B. The image processed by the rendering method is strong in edge layering, has high artistry, does not have the invalid black patch effect and can achieve the rendering effect in real time. The basic line drawing method is provided for subsequent unreality feeling rendering processing by wax pencils, pencil drawings, watercolors and the like.
Description
Technical field
The present invention relates to image processing field, relate in particular to rendering intent and device that a kind of coloured image is taken out line.
Background technology
Non-photorealistic rendering is the new research field that computer technology and graphics art combine.Different from the graph rendering of the traditional sense of reality, feeling of unreality graph rendering is not pursued the image that generates similar photo, but by omitting the details irrelevant with figure, simplify the shape of object, even expose the intention of being assigned to express drafting person by the detail portion of blanking.In to feeling of unreality render process, all need to take out line early stage and process, from image, extract essential general profile.
Traditional line method edge stereovision of taking out is poor, and profile is clear not, has large gauge block to strengthen invalid black region for dark areas simultaneously, affects follow-up processing completely.
Summary of the invention
The object of the embodiment of the present invention is to propose the rendering intent that a kind of coloured image is taken out line, and being intended to solve prior art, to take out line method edge stereovision poor, and profile is clear not, and dark areas has the problem of the strong invalid black region of large gauge block.
The embodiment of the present invention is achieved in that a kind of coloured image takes out the rendering intent of line, and described method comprises:
Obtain image A;
Image A is normalized and obtains image A 1;
Image A 1 is carried out to gray processing processing and obtain image a;
Image a is carried out to Gaussian Blur, obtain image b;
Image a and image b are merged and obtain image c;
Image c is strengthened to process and obtain image B;
Output image B.
The second object of the embodiment of the present invention is to propose the rendering device that a kind of coloured image is taken out line, and described device comprises:
Image collection module, for obtaining image A;
Normalized module, obtains image A 1 for image A is normalized;
Gray processing processing module, obtains image a for image A 1 being carried out to gray processing processing;
Gaussian Blur module, for image a is carried out to Gaussian Blur, obtains image b;
Merge module, for image a and image b are merged and obtain image c;
Strengthen processing module, for image c being strengthened process, obtain image B;
Output module, for output image B.
The 3rd object of the embodiment of the present invention is to propose the rendering intent that a kind of coloured image is taken out line, and described method comprises:
Obtain image A;
Image A is carried out to gray processing processing and obtain image a
1;
To image a
1carry out Gaussian Blur, obtain image b
1;
By image a
1with image b
1merge and obtain image c
1;
Output image image c
1.
The 4th object of the embodiment of the present invention is to propose the rendering device that a kind of coloured image is taken out line, and described device comprises:
Image collection module, for obtaining image A;
The second gray processing processing module, obtains image a for image A being carried out to gray processing processing
1;
The second Gaussian Blur module, to image a
1carry out Gaussian Blur, obtain image b
1;
Second merges module, by image a
1with image b
1merge and obtain image c
1;
The second output module, output image image c
1.
Beneficial effect of the present invention
The present invention is automatically generated and takes out the picture after line by substep, for crossing dark excessively bright picture, extracts accurately profile, removes black patch effect.The image border stereovision that adopts the inventive method to process is strong, has very strong artistic feeling, there is no invalid black patch effect, and can real-time implementation rendering effect.For later wax crayon, pencil drawing, watercolor etc. feeling of unreality is played up to process provides a basic line method of taking out.
Accompanying drawing explanation
Fig. 1 is the rendering intent process flow diagram that a kind of coloured image of the preferred embodiment of the present invention is taken out line;
Fig. 2 is the rendering device structural drawing that a kind of coloured image of the preferred embodiment of the present invention is taken out line;
Fig. 3 is the rendering intent process flow diagram that a kind of coloured image of the preferred embodiment of the present invention is taken out line;
Fig. 4 is the rendering device structural drawing that a kind of coloured image of the preferred embodiment of the present invention is taken out line.
Embodiment
In order to make object of the present invention, technical scheme and advantage clearer, below in conjunction with drawings and Examples, the present invention is further elaborated, for convenience of explanation, only show the part relevant to the embodiment of the present invention.Should be appreciated that the specific embodiment that this place is described, only for explaining the present invention, not in order to limit the present invention.
The embodiment of the present invention is automatically generated and takes out the picture after line by substep, for crossing dark excessively bright picture, extracts accurately profile, removes black patch effect.The image border stereovision that adopts embodiment of the present invention method to process is strong, has very strong artistic feeling, there is no invalid black patch effect, and can real-time implementation rendering effect.For later wax crayon, pencil drawing, watercolor etc. feeling of unreality is played up to process provides a basic line method of taking out.
Embodiment mono-
Fig. 1 is the rendering intent process flow diagram that a kind of coloured image of the preferred embodiment of the present invention is taken out line; Said method comprising the steps of:
S101, obtains image A;
S102, is normalized and obtains image A 1 image A;
S103, carries out gray processing processing to image A 1 and obtains image a;
a(i,j)=0.299*A
1(i,j)
R+0.587*A
1(i,j)
G+0.114*A
1(i,j)
B;
Wherein: image is divided to row and column according to pixel, and the i that i is every image is capable; J is the j row of every image; A
1(i, j)
rfor (i, j) some pixel red color component value of image A 1, A
1(i, j)
gfor (i, j) some pixel green component values of image A 1, A
1(i, j)
b(i, j) some pixel blue component value for image A 1; A (i, j) is (i, j) some pixel value of image a;
S104, carries out Gaussian Blur to image a, obtains image b;
Gaussian Blur template size is 5 * 5, variances sigma=1.5, and template is as follows:
With this template and a, carry out convolution operation; ?
represent convolution operator; The method of convolution operation is the common practise of the art, does not repeat them here.
S105, merges image a and image b to obtain image c;
Wherein: b (i, j) is (i, j) some pixel value of image b, c (i, j) is (i, j) some pixel value of image c; K is the real number of [0.5 ,+0.5];
S106, strengthens image c to process obtaining image B;
B(i,j)=p·c(i,j)-q
(i, j) that wherein B (i, j) is image B point pixel value, p be [1 ,+∞) real number; Q is the real number of [2,2];
S107, output image B.
B(i,j)
R=B(i,j)
G=B(i,j)
B,
Wherein: B (i, j)
rfor (i, j) some pixel red color component value of image B, B (i, j)
gfor (i, j) some pixel green component values of image B, B (i, j)
b(i, j) some pixel blue component value for image B.
Embodiment bis-
Fig. 2 is the rendering device structural drawing that a kind of coloured image of the preferred embodiment of the present invention is taken out line; Described device comprises:
Image collection module, for obtaining image A;
Normalized module, obtains image A 1 for image A is normalized;
Gray processing processing module, obtains image a for image A 1 being carried out to gray processing processing;
a(i,j)=0.299*A
1(i,j)
R+0.587*A
1(i,j)
G+0.114*A
1(i,j)
B;
Wherein: image is divided to row and column according to pixel, and the i that i is every image is capable; J is the j row of every image; A
1(i, j)
rfor (i, j) some pixel red color component value of image A 1, A
1(i, j)
gfor (i, j) some pixel green component values of image A 1, A
1(i, j)
b(i, j) some pixel blue component value for image A 1; A (i, j) is (i, j) some pixel value of image a;
Gaussian Blur module, for image a is carried out to Gaussian Blur, obtains image b;
Gaussian Blur template size is 5 * 5, variances sigma=1.5, and template is as follows:
With this template and a, carry out convolution operation; ?
represent convolution operator; The method of convolution operation is the common practise of the art, does not repeat them here.
Merge module, for image a and image b are merged and obtain image c;
Wherein: b (i, j) is (i, j) some pixel value of image b, c (i, j) is (i, j) some pixel value of image c; K is the real number of [0.5 ,+0.5];
Strengthen processing module, for image c being strengthened process, obtain image B;
B(i,j)=p·c(i,j)-q
(i, j) that wherein B (i, j) is image B point pixel value, p be [1 ,+∞) real number; Q is the real number of [2,2];
Output module, for output image B.
B(i,j)
R=B(i,j)
G=B(i,j)
B,
Wherein: B (i, j)
rfor (i, j) some pixel red color component value of image B, B (i, j)
gfor (i, j) some pixel green component values of image B, B (i, j)
b(i, j) some pixel blue component value for image B.
Embodiment tri-
Fig. 3 is the rendering intent process flow diagram that a kind of coloured image of the preferred embodiment of the present invention is taken out line; Said method comprising the steps of:
S301, obtains image A;
S302, carries out gray processing processing to image A and obtains image a
1;
a
1(i,j)=0.299*A(i,j)
R+0.587*A(i,j)
G+0.114*A(i,j)
B;
Wherein: image is divided to row and column according to pixel, and the i that i is every image is capable; J is the j row of every image; A (i, j)
rfor (i, j) some pixel red color component value of image A, A (i, j)
gfor (i, j) some pixel green component values of image A, A (i, j)
b(i, j) some pixel blue component value for image A; a
1(i, j) is image a
1(i, j) some pixel value;
S303, to image a
1carry out Gaussian Blur, obtain image b
1;
Gaussian Blur template size is 5 * 5, variances sigma=1.5, and template is as follows:
With this template and a
1carry out convolution operation; ?
represent convolution operator; The method of convolution operation is the common practise of the art, does not repeat them here.
S304, by image a
1with image b
1merge and obtain image c
1;
Wherein: the i that i is every image is capable; J is the j row of every image; a
1(i, j) is image a
1(i, j) some pixel value, b
1(i, j) is image b
1(i, j) some pixel value, k
1real number for [128 ,+128]; p
1for [255 ,+∞) real number; q
1real number for [510,510]; c
1(i, j) is image c
1(i, j) some pixel value;
S305, output image image c
1.
C
1(i,j)
R=C
1(i,j)
G=C
1(i,j)
B,
Wherein: C
1(i, j)
rfor image c
1(i, j) some pixel red color component value, C
1(i, j)
gfor image c
1(i, j) some pixel green component values, C
1(i, j)
bfor image c
1(i, j) some pixel blue component value.
Embodiment tetra-
Fig. 4 is the rendering device structural drawing that a kind of coloured image of the preferred embodiment of the present invention is taken out line; Described device comprises:
Image collection module, for obtaining image A;
The second gray processing processing module, obtains image a for image A being carried out to gray processing processing
1;
a
1(i,j)=0.299*A(i,j)
R+0.587*A(i,j)
G+0.114*A(i,j)
B;
Wherein: image is divided to row and column according to pixel, and the i that i is every image is capable; J is the j row of every image; A (i, j)
rfor (i, j) some pixel red color component value of image A, A (i, j)
gfor (i, j) some pixel green component values of image A, A (i, j)
b(i, j) some pixel blue component value for image A; a
1(i, j) is image a
1(i, j) some pixel value;
The second Gaussian Blur module, to image a
1carry out Gaussian Blur, obtain image b
1;
Gaussian Blur template size is 5 * 5, variances sigma=1.5, and template is as follows:
With this template and a
1carry out convolution operation; ?
represent convolution operator; The method of convolution operation is the common practise of the art, does not repeat them here.
Second merges module, by image a
1with image b
1merge and obtain image c
1;
Wherein: the i that i is every image is capable; J is the j row of every image; a
1(i, j) is image a
1(i, j) some pixel value, b
1(i, j) is image b
1(i, j) some pixel value, k
1real number for [128 ,+128]; p
1for [255 ,+∞) real number; q
1real number for [510,510]; c
1(i, j) is image c
1(i, j) some pixel value;
Output module, output image c
1.
C
1(i,j)
R=C
1(i,j)
G=C
1(i,j)
B,
Wherein: C
1(i, j)
rfor image c
1(i, j) some pixel red color component value, C
1(i, j)
gfor image c
1(i, j) some pixel green component values, C
1(i, j)
bfor image c
1(i, j) some pixel blue component value.
Those having ordinary skill in the art will appreciate that, the all or part of step realizing in above-described embodiment method can complete by programmed instruction related hardware, described program can be stored in a computer read/write memory medium, and described storage medium can be ROM, RAM, disk, CD etc.
The foregoing is only preferred embodiment of the present invention, not in order to limit the present invention, all any modifications of doing within the spirit and principles in the present invention, be equal to and replace and improvement etc., within all should being included in protection scope of the present invention.
Claims (10)
1. coloured image is taken out a rendering intent for line, it is characterized in that, described method comprises:
Obtain image A;
Image A is normalized and obtains image A 1;
Image A 1 is carried out to gray processing processing and obtain image a;
Image a is carried out to Gaussian Blur, obtain image b;
Image a and image b are merged and obtain image c;
Image c is strengthened to process and obtain image B;
Output image B.
2. coloured image as claimed in claim 1 is taken out the rendering intent of line, it is characterized in that,
Described " image A 1 is carried out to gray processing processing and obtain image a " is specially:
a(i,j)=0.299*A
1(i,j)
R+0.587*A
1(i,j)
G+0.114*A
1(i,j)
B;
Wherein: image is divided to row and column according to pixel, and the i that i is every image is capable; J is the j row of every image; A
1(i, j)
rfor (i, j) some pixel red color component value of image A 1, A
1(i, j)
gfor (i, j) some pixel green component values of image A 1, A
1(i, j)
b(i, j) some pixel blue component value for image A 1; A (i, j) is (i, j) some pixel value of image a.
3. coloured image as claimed in claim 2 is taken out the rendering intent of line, it is characterized in that,
In described " image a is carried out to Gaussian Blur, obtains image b ";
Gaussian Blur template size is 5 * 5, variances sigma=1.5, and template is as follows:
4. coloured image as claimed in claim 3 is taken out the rendering intent of line, it is characterized in that,
Described " image a and image b are merged and obtain image c " is specially:
Wherein: b (i, j) is (i, j) some pixel value of image b, c (i, j) is (i, j) some pixel value of image c; K is the real number of [0.5 ,+0.5].
5. coloured image as claimed in claim 4 is taken out the rendering intent of line, it is characterized in that,
Described " image c is strengthened to process and obtain image B " is specially:
B(i,j)=p·c(i,j)-q
(i, j) that wherein B (i, j) is image B point pixel value, p be [1 ,+∞) real number; Q is the real number of [2,2].
6. coloured image as claimed in claim 5 is taken out the rendering intent of line, it is characterized in that,
Described " output image B " is specially:
B(i,j)
R=B(i,j)
G=B(i,j)
B,
Wherein: B (i, j)
rfor (i, j) some pixel red color component value of image B, B (i, j)
gfor (i, j) some pixel green component values of image B, B (i, j)
b(i, j) some pixel blue component value for image B.
7. coloured image is taken out a rendering device structural drawing for line, it is characterized in that, described device comprises:
Image collection module, for obtaining image A;
Normalized module, obtains image A 1 for image A is normalized;
Gray processing processing module, obtains image a for image A 1 being carried out to gray processing processing;
Gaussian Blur module, for image a is carried out to Gaussian Blur, obtains image b;
Merge module, for image a and image b are merged and obtain image c;
Strengthen processing module, for image c being strengthened process, obtain image B;
Output module, for output image B.
8. coloured image is taken out a rendering intent for line, it is characterized in that, said method comprising the steps of:
Obtain image A;
Image A is carried out to gray processing processing and obtain image a
1;
To image a
1carry out Gaussian Blur, obtain image b
1;
By image a
1with image b
1merge and obtain image c
1;
Output image image c
1.
9. coloured image as claimed in claim 8 is taken out the rendering intent of line, it is characterized in that,
It is described that " image A is carried out to gray processing to be processed and to obtain image a
1" be specially:
a
1(i,j)=0.299*A(i,j)
R+0.587*A(i,j)
G+0.114*A(i,j)
B;
Wherein: image is divided to row and column according to pixel, and the i that i is every image is capable; J is the j row of every image; A (i, j)
rfor (i, j) some pixel red color component value of image A, A (i, j)
gfor (i, j) some pixel green component values of image A, A (i, j)
b(i, j) some pixel blue component value for image A; a
1(i, j) is image a
1(i, j) some pixel value;
Described " to image a
1carry out Gaussian Blur, obtain image b
1" in,
Gaussian Blur template size is 5 * 5, variances sigma=1.5, and template is as follows:
Described " by image a
1with image b
1merge and obtain image c
1" be specially:
Wherein: the i that i is every image is capable; J is the j row of every image; a
1(i, j) is image a
1(i, j) some pixel value, b
1(i, j) is image b
1(i, j) some pixel value, k
1real number for [128 ,+128]; p
1for [255 ,+∞) real number; q
1real number for [510,510]; c
1(i, j) is image c
1(i, j) some pixel value;
Described " output image image c
1" be specially:
C
1(i,j)
R=C
1(i,j)
G=C
1(i,j)
B,
Wherein: C
1(i, j)
rfor image c
1(i, j) some pixel red color component value, C
1(i, j)
gfor image c
1(i, j) some pixel green component values, C
1(i, j)
bfor image c
1(i, j) some pixel blue component value.
10. coloured image is taken out a rendering device for line, it is characterized in that, described device comprises:
Image collection module, for obtaining image A;
The second gray processing processing module, obtains image a for image A being carried out to gray processing processing
1;
The second Gaussian Blur module, to image a
1carry out Gaussian Blur, obtain image b
1;
Second merges module, by image a
1with image b
1merge and obtain image c
1;
The second output module, output image image c
1.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310684284.6A CN103729829A (en) | 2013-12-13 | 2013-12-13 | Rendering method and device for color image line drawing |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310684284.6A CN103729829A (en) | 2013-12-13 | 2013-12-13 | Rendering method and device for color image line drawing |
Publications (1)
Publication Number | Publication Date |
---|---|
CN103729829A true CN103729829A (en) | 2014-04-16 |
Family
ID=50453890
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310684284.6A Pending CN103729829A (en) | 2013-12-13 | 2013-12-13 | Rendering method and device for color image line drawing |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103729829A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105096360A (en) * | 2015-08-27 | 2015-11-25 | 深圳市云宙多媒体技术有限公司 | Image non-photorealistic highlight water color rendering method and apparatus |
WO2017084391A1 (en) * | 2015-11-19 | 2017-05-26 | 广景视睿科技(深圳)有限公司 | Method and system for performing fluorescence processing on an image of a projector |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2011175309A (en) * | 2010-02-23 | 2011-09-08 | Casio Computer Co Ltd | Image processing apparatus and program |
CN103035019A (en) * | 2012-12-11 | 2013-04-10 | 深圳深讯和科技有限公司 | Image processing method and device |
CN103093438A (en) * | 2013-01-30 | 2013-05-08 | 深圳深讯和科技有限公司 | Method and device for generating Chinese painting style image |
CN103093417A (en) * | 2013-01-30 | 2013-05-08 | 深圳深讯和科技有限公司 | Method and device for generating watercolor style image |
-
2013
- 2013-12-13 CN CN201310684284.6A patent/CN103729829A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2011175309A (en) * | 2010-02-23 | 2011-09-08 | Casio Computer Co Ltd | Image processing apparatus and program |
CN103035019A (en) * | 2012-12-11 | 2013-04-10 | 深圳深讯和科技有限公司 | Image processing method and device |
CN103093438A (en) * | 2013-01-30 | 2013-05-08 | 深圳深讯和科技有限公司 | Method and device for generating Chinese painting style image |
CN103093417A (en) * | 2013-01-30 | 2013-05-08 | 深圳深讯和科技有限公司 | Method and device for generating watercolor style image |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105096360A (en) * | 2015-08-27 | 2015-11-25 | 深圳市云宙多媒体技术有限公司 | Image non-photorealistic highlight water color rendering method and apparatus |
WO2017084391A1 (en) * | 2015-11-19 | 2017-05-26 | 广景视睿科技(深圳)有限公司 | Method and system for performing fluorescence processing on an image of a projector |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Hou et al. | Context-aware image matting for simultaneous foreground and alpha estimation | |
CN104038807B (en) | A kind of figure layer mixed method and device based on OpenGL | |
CN107045729B (en) | A kind of image rendering method and device | |
US11054969B2 (en) | Method and device for displaying page of electronic book, and terminal device | |
CN105046658A (en) | Low-illumination image processing method and device | |
CN104517265A (en) | Intelligent buffing method and intelligent buffing device | |
CN103985098A (en) | Method and system for removing highlight of certificate image | |
CN103093437A (en) | Method and device for generating pencil drawing style image | |
CN103914862A (en) | Pencil sketch simulating method based on edge tangent stream | |
CN102024156A (en) | Method for positioning lip region in color face image | |
CN104658030A (en) | Secondary image mixing method and apparatus | |
CN106709964A (en) | Gradient correction and multi-direction texture extraction-based sketch generation method and device | |
CN105096358A (en) | Line enhanced simulation method for pyrography artistic effect | |
CN105513025A (en) | Improved rapid demisting method | |
CN105574814A (en) | Portrait paper-cut special effect generation method | |
CN103093417B (en) | Generate method and the device of watercolor style image | |
CN103729829A (en) | Rendering method and device for color image line drawing | |
CN103116898B (en) | Generate method and the device of ink and wash style image | |
CN103455974B (en) | Image sketching style processing method | |
CN103035019A (en) | Image processing method and device | |
CN105719335A (en) | Map image rendering method and device, and vehicle-mounted terminal | |
CN105373798A (en) | K neighbor image matting and mathematical morphology-based calligraphy character extracting method | |
CN103729866A (en) | Water color style non-photorealistic rendering method and device | |
CN102306097B (en) | Method for performing real-time image processing on scene images in MultiGen-Vega | |
CN104102911A (en) | Image processing for AOI (automated optical inspection)-based bullet appearance defect detection system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C53 | Correction of patent of invention or patent application | ||
CB02 | Change of applicant information |
Address after: The central Shenzhen city of Guangdong Province, 518057 Keyuan Road, Nanshan District science and Technology Park No. 15 Science Park Sinovac A Building 1 unit 403, No. 405 unit Applicant after: Shenzhen Yunzhou Multimedia Technology Co., Ltd. Address before: Unit B4 9 building 518057 Guangdong city of Shenzhen province Nanshan District high in the four EVOC Technology Building No. 31 Applicant before: Shenzhen Yunzhou Multimedia Technology Co., Ltd. |
|
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20140416 |
|
RJ01 | Rejection of invention patent application after publication |