It is currently 29 Nov 2021, 23:24

• Featuring Members' Works (Image Attachments) •
1: member
2: member
3: member
4: member
5: member

GIMP/GL:  🡆 Tutorials | Tips | Questions | Interests | Script Requests
Recommendations:  Index | Top 10
Resources:  Python-Fu Plug-ins | Scheme-Fu Scripts | GIMP
Python:  Lessons | Questions | Exercises
The Arts:  GIMPed | GIMPed Photos | Other | Contests | Public Domain Images | Isolated Images | Blender
Inkscape
Social:  Say Hello | Anything Goes | Shares | FCSP
Sponsored content for World Food Program

Displacement Glass/Chrome Effect

GIMP Tutorials
Forum rules
Tutorials must be created by you and your own idea.
If you got idea from elsewhere and revised your own version of tutorial, please include reference and credit original authors.
For example if you found a Photoshop tutorial and wanted to write a GIMP version, you must credit the original Photoshop tutorial.
Espermaschine
GIMP Blogger
38th Place
55 Post(s)

Displacement Glass/Chrome Effect

Post#1 by Espermaschine » 12 Mar 2018, 11:16


After i saw Tim's post on Gimpchat, i decided to share this with you before i write a tutorial for my blog.

Perhaps we can test the method and improve it.

Please dont turn the effect into a script or a pdf tutorial and dont repost it without my permission !


So you have all seen the chrome i posted here:
https://www.gimplearn.net/viewtopic.php ... 89&p=15467

The idea is to use a Displacement Map to distort an image so that it looks like refractions of glass or the reflections of chrome.
Photoshop has a filter dedicated to this effect. I dont know how it exactly works, but i can guess and tried to reverse engineer.

Here is how i think it works.
Lets remember how displacement maps work:
white displaces up and to the left, while black displaces down and to the right.
Gray (#808080) doesnt displace at all.

We can use this information to get a displacement map, that imitates the reflections of a (non plane) mirror.

1. Type your text in 50ies gray (#808080). The red background is just so you can better see what im doing and not necessary for the effect.

2. We need two versions of this text for the displacement so duplicate it and make a backup path for selection purposes (Text To Path)

3. Bevel this text. One version so that the higlight is at the bottom, and one so that the white is on the right side.
We want the top of the text to reflect the sky (down), and the bottom of the text to reflect up.

[sorry, image no longer availalbe]

4. Give this text a slight blur.

5. Apply a curve to both text layers, like this:

[sorry, image no longer availalbe]

6. Open an image (i got mine form pexels.com) that might work for the effect and blur it a bit (think of a blind mirror when you choose the blur value).

[sorry, image no longer availalbe]
7. Apply a displacement (Filters -> Map -> Displace) to the image with the maps we just made. Y is for up and down, X for the sides.
The values depend on the image, stop when the image begins to rip. The more you pre-blurred it, the less it rips.

[sorry, image no longer availalbe]
8. Bam, glass effect !

9. Apply G'MIC Anisotropic smoothing to smooth out some of the jagged edges. Apart from the values i used, you can vary the Sharpness value.

[sorry, image no longer availalbe]
10. Refine with overlays to make it look cooler.

You get a desaturated image by putting a black layer in 'Saturation' Mode on top.
Its also good to sharpen the image a bit. I used a High Pass Filter.
Making the effect look more vibrant or metallic depends on the image. Apply some clever blendmodes or use curves.

[sorry, image no longer availalbe]

If you want to study how i did all that, download the xcf:
http://www.mediafire.com/file/7tjvm0h07 ... ome.xcf.gz
Last edited by Espermaschine on 12 Mar 2018, 14:40, edited 2 times in total.

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#2 by Issabella » 12 Mar 2018, 14:11


Thank you so much Esper for this "Master Tutorial" :gimp_clap:
I'm still learning this kind of treatment on texts. I've learnt so much from your tutorial.
These are my first tries. One is the real result, and the other more colourful after layer mode. :happy_purple:
(image from public domine)
Attachments
sunrise-2705265_Esper Tutorial_Reflect_R.JPG
sunrise-2705265_Esper Tutorial_Reflect_R.JPG # (38.08 KiB) Viewed 7191 times (Thumbnail | Recognize | Sq Tile | LNFI)
sunrise-2705265_Esper Tutorial_Reflect.JPG
sunrise-2705265_Esper Tutorial_Reflect.JPG # (53.48 KiB) Viewed 7191 times (Thumbnail | Recognize | Sq Tile | LNFI)
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

Espermaschine
GIMP Blogger
38th Place
55 Post(s)

Post#3 by Espermaschine » 12 Mar 2018, 14:24


Nice one Issabella ! :red_heart:

I think it would look even better if you didnt place it over the dark parts.
But clouds in general are a good choice for this effect.

Here is my take (with added G'MIC - Deformation - Random)
Beauty.jpg
Beauty.jpg # (57.51 KiB) Viewed 7178 times (Thumbnail | Recognize | Sq Tile | LNFI)
Last edited by Espermaschine on 12 Mar 2018, 15:11, edited 1 time in total.

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#4 by Issabella » 12 Mar 2018, 15:04


You are right, Esper. I was so impatient to practise what you said in your tutorial that I didn't choose the right image. I'll do more tries on better images. Thanks a lot. :happy_purple:
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

Espermaschine
GIMP Blogger
38th Place
55 Post(s)

Post#5 by Espermaschine » 12 Mar 2018, 15:09


Issabella wrote:
12 Mar 2018, 15:04
You are right, Esper. I was so impatient to practise what you said in your tutorial that I didn't choose the right image.
I think generally this horizon in the middle trick is a good idea, as this is what real chrome does.
Its just in your case, there is not enough contrast between the dark text and the dark background.
10735167_894431510569194_1719468255_n.jpg
10735167_894431510569194_1719468255_n.jpg # (38.32 KiB) Viewed 7177 times (Thumbnail | Recognize | Sq Tile | LNFI)

Issabella
Script Tester
3rd Place
3587 Post(s)

Post#6 by Issabella » 12 Mar 2018, 15:13


I understand what you said. I'll have that in mind. Thanks a lot.
Issabella

Don’t be afraid to start over. It’s a new chance to rebuild what you want.

tim
GL Blogger
1st Place
5623 Post(s)

Post#7 by tim » 12 Mar 2018, 15:36


This is awesome!
It got me thinking about the displacement part since for example now, if you had a bright value it would displace based on say 1*X_displacement, 1*Y_displacement if you had a bright value between pure white and 50% gray, it would displace something like 0.5*X_displacement, 0.5*Y_displacement.
What if displacement was based on height difference like hack out the slope part based on a height map (like my reflect script).
and then pull a pixel based on that slope... that way depending on slope it'll grab pixels from not just direct X/Y but depending on slope.
I am curious to see what results it gets.
aka Tin
World Food Program | Good Deeds Forum

         

Ella
Tutorial Creator
8th Place
1732 Post(s)

Post#8 by Ella » 12 Mar 2018, 15:58


Not quite satisfied with my first try, but it's a beginning...
Attachments
displacement_glass_chrome_effect.JPG
displacement_glass_chrome_effect.JPG # (46.93 KiB) Viewed 7080 times (Thumbnail | Recognize | Sq Tile | LNFI)
Ella's gallery My Blender work - Ella
My Blog - Le temps perdu


There is a crack in everything. That's how the light gets in.
(Leonard Cohen)

Espermaschine
GIMP Blogger
38th Place
55 Post(s)

Post#9 by Espermaschine » 12 Mar 2018, 16:15


tim wrote:
12 Mar 2018, 15:36
What if displacement was based on height difference like hack out the slope part based on a height map (like my reflect script).
and then pull a pixel based on that slope... that way depending on slope it'll grab pixels from not just direct X/Y but depending on slope.
I am curious to see what results it gets.
I have no idea what this means.
All i can say is i spend literally a year+ to figure this out and its still not 100% like i want it.
Did lot of research into displacement maps. Tried normalmaps, which i think, use the R and G channel instead of grayscale, but the results dont seem that different.
I also tried to bump a Satin layer, and some complicated actions of offsetting two layers in different directions, with one layer set to 'Grain Extract' to get an emboss effect, until i realized, thats basically like a bevel.

I think in some early versions of Photoshop a displacement map was required that had to consist of two maps. One for the red channel and one for the green.
Thats when i came up with the idea of two different maps going in seperate directions.

I think the most important detail is to have the displacement to the centre, because thats what a concave surface would do when it reflects.
DisplacementDirection.png
DisplacementDirection.png # (12.17 KiB) Viewed 7075 times (Thumbnail | Recognize | Sq Tile | LNFI)



Ella wrote:
12 Mar 2018, 15:58
Not quite satisfied with my first try, but it's a beginning...
I think it looks great. The refractions on the dot of the letter 'i' look especially nice with the little swirls !

Maybe the colours are a bit unusual for what you would expect from glass to look like ?
Last edited by Espermaschine on 12 Mar 2018, 16:23, edited 3 times in total.

tim
GL Blogger
1st Place
5623 Post(s)

Post#10 by tim » 12 Mar 2018, 16:22


I am trying to get help with the math calculation on stackexchange game development for calculation of slope and reflect.
My reflect script was a hack that i made which isn't based on any real true reflection.
Displacement currently (at least I think so) just displaces based on gray value which is a one dimension distance defined by user's X and Y displacement definition.
If I can get help with the math I'll script it to reflect based on heightmap like as if the image was placed directly above heightmap at a user's defined/input distance...
aka Tin
World Food Program | Good Deeds Forum

         


GIMP/GL:  🡆 Tutorials | Tips | Questions | Interests | Script Requests
Recommendations:  Index | Top 10
Resources:  Python-Fu Plug-ins | Scheme-Fu Scripts | GIMP
Python:  Lessons | Questions | Exercises
The Arts:  GIMPed | GIMPed Photos | Other | Contests | Public Domain Images | Isolated Images | Blender
Inkscape
Social:  Say Hello | Anything Goes | Shares | FCSP

Post Reply New Topic
  • Similar Topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 5 guests