Results 1 to 7 of 7

Thread: Post effects in ClanLib 2.0.1?

  1. #1
    Peasant
    Join Date
    Apr 2009
    Location
    Brazil
    Posts
    6

    Default Post effects in ClanLib 2.0.1?

    Hi,
    I'm making a game with ClanLib 2.0.1 and I want to do the cutscenes in grayscale with an old TV noise.

    Is this possible in ClanLib 2.0.1? Has any example of something like this?


    Thanks,
    Legionaryu

  2. #2
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    If you are using OpenGL (via ClanGL), I would implement it in a GLSL shader.

    Write a custom shader to convert the r,g,b components to greyscale and add some noise using the GLSL noise() function?

    Unfortunately at the moment, ClanLib is lacking in basic examples to do things like this.

    For a starting point, the methane example has a GLSL shader to fade to black.
    You could try playing with its shaders to see what you can come up with.

  3. #3
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Bergen, Norway
    Posts
    588

    Default

    It would be really nice to have a postprocess example in ClanLib. Just a render to a framebuffer and applying a simple shader.

    Since this is cool, and very easy to do in Clanlib, I'll see if I find the time to hack this together

  4. #4
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Bergen, Norway
    Posts
    588

    Default

    I've now coded a Postprocess example in latest ClanLib svn. You find it under Examples\PostProcessing. It does a simple fade-to-blackandwhite effect.

  5. #5
    Peasant
    Join Date
    Apr 2009
    Location
    Brazil
    Posts
    6

    Default

    Thank you, guys!

    Sphair your example is exactly what I wanted to do!

    Rombust, now I will test this GLSL noise() function.


    Thanks, again!

  6. #6
    ClanLib Developer
    Join Date
    Sep 2006
    Location
    Bergen, Norway
    Posts
    588

    Default

    I've just updated the example somewhat adding some scanlines and some noise. The noise didnt end up too good, but its a start if you want to play with it I am unfamiliar with the noise() function of GLSL, perhaps you can use that as rombust suggests.
    Attached Images Attached Images  
    Last edited by sphair; 05-06-2009 at 06:37 PM.

  7. #7
    ClanLib Developer
    Join Date
    May 2007
    Posts
    1,824

    Default

    It may be a bad idea to use GLSL noise(), it seems various graphic cards do not support it fully. See: http://www.opengl.org/discussion_boa...&Number=253271

Similar Threads

  1. post-mortem for MinGW
    By alexv1 in forum Official ClanLib SDK Forums
    Replies: 4
    Last Post: 04-18-2009, 10:55 AM
  2. Please post a basic makefile
    By NVanGogh in forum Official ClanLib SDK Forums
    Replies: 0
    Last Post: 08-14-2008, 06:30 PM
  3. please post copies of directs includes/libs?
    By imnotbncre8ive in forum Official ClanLib SDK Forums
    Replies: 0
    Last Post: 10-29-2007, 07:20 AM
  4. Light flares and magical effects
    By whisperstorm in forum Novashell Game Creation System
    Replies: 2
    Last Post: 02-04-2007, 10:42 AM

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •