Archive for April, 2011

Initial plan

The plan has two branches that aren’t related, so if there’s a roadblock
in one, the other can be continued until a solution pops up.

In more detail:

  • Port to GLSL

    The first task in this branch is to port Jimenez’ implementation of MLAA
    to GLSL. I will aim to support the most hardware, if there’s a choice.

  • Create a client-side test app

    To test the port, I’ll then create a client-side app. I’ll be using
    Irrlicht, because that’s what I’m most familiar with, and will get the
    convenience it brings (image loaders, etc.).

    Without a command-line arg, the app will show some simple object in rainbow
    colors. This mode will have a Maya-style camera.
    With an image at the command line, it will show that, with a static
    camera.

    In both modes there will be a FPS counter in the title bar, and MLAA can
    be toggled on/off with ‘m’, default off.

    The image is to be able to test different conditions, and to compare
    with the official implementation.

  • Test that functionality is intact

    With the client-side app, the port should be functionally equivalent to
    the original HLSL version. This will be tested with the comparison
    images posted at iryoku.com, from the official implementation.

    The app will also be tested with many drivers. Once it works for me,
    I’ll post about it with some pics, and ask for testing and comments from
    the general community.


  • Design the queue

    Starting the other branch is designing the post-processing queue for
    Gallium. Will need to discuss the goals, desired complexity/configurability etc.

  • Implement the queue

    First part of coding inside Mesa ;)

    Hooks for one driver (softpipe).

  • Create test shaders

    For first testing, I’ll create some very simple shaders, three that each
    just remove one color channel (“nored”, “nogreen”, “noblue”). Using them
    it will be easy to see that chaining works.

  • Test none, one, combos

    Heavier testing of the queue. It should have no measurable overhead when
    not enabled. No leaks should be there no matter the number of filters,
    and all filters should work properly alone and in combination.


  • Unify

    To get here, both branches need to be done. Basically just adding the
    GLSL port to the post-processing infrastructure.

  • Finishing touches

    Adding all configurability (driconf for semi-permanent, per-app/global
    toggle; environment variables for per-run control).

    Cleanups, and running the code through all static analyzers available :)

  • Hooks for other drivers

    As the last task in the official plan, adding hooks to other drivers.
    Beyond softpipe, I can test llvmpipe and r600g, so those will be done
    here, in that order.


There’s the initial plan in total. I don’t really want to estimate timescales.

If there’s time left after this plan is fully done and code merged, the remaining time should be used to investigate usage in classic drivers (‘sup Intel).

April 27, 2011cand No Comments »
FILED UNDER :Meta , Progress