Results 1 to 5 of 5

Thread: Anaglyph - is it possible to preserve colors?

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,153
    Rep Power
    736

    Anaglyph - is it possible to preserve colors?

    Dear friends,

    you might noticed increased level of talk regarding various 3D technologies recently. There are multiple solutions available, like nvidia 3D glasses, special "3D" monitors and projectors.

    And then there is the good old anaglyph we've been playing in TBGL for some time. It provided nice illusion of depth, but the colors were just completely wrong. Also lot of talk over net cited impossibility to maintain colors with red cyan glasses.

    I was experimenting with this, wanted to break this color fidelity problem. I got some nice results, but then I realised ... somebody did this before me ... and better.

    Anyway this was nice challenge, and I present you here little program implementing algorithms from the mentioned source. It is application allowing to combine two images to one anaglyph.

    This is very nice task for ThinBASIC, as the script could take advantage of:
    • Calling function by name
    • Built-in matrix handling
    • Canvas and TImage module


    The first one is used for simple thing - all image processing functions start with "PA_", so I can automatically detect them from source and add them as option in the dialog automagically.

    Built-in matrix handling allows to perform quite fast per pixel operations.

    Canvas serves as display of the images, while TImage allows to load images of various formats.

    The script itself is far from perfect - it could use some speed tuning (I don't recommend images over 640x480 unless you have fast PC) and it seems the TImage module sometimes makes image "upside down".

    But I hope you will like this experiment, and maybe it will be you who will discover even better technique to maintain good level of color fidelity with anaglyph.

    The images you get with the script are photos taken by me using normal camera - you just shoot one frame, focusing on some point on the object, then shift the camera while still keeping the same part of object in focus and grab other frame. This should simulate view of left and right eye. I will appreciate any left-right images from you, as I think the mine do not demonstrate the 3D effect to the edge yet.

    Last word - the latest beta is a must to have for fast and proper execution of the script.


    Have fun,
    Petr
    Attached Images Attached Images
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

Similar Threads

  1. colors and console_printat
    By sandyrepope in forum Console
    Replies: 4
    Last Post: 22-02-2007, 17:59

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

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