Results 1 to 4 of 4

Thread: Read Colour Idx From BitMap

  1. #1
    Junior Member
    Join Date
    Apr 2010
    Posts
    2

    Read Colour Idx From BitMap

    Hello

    I'm just wandering why I can't use my own values in texture2D() like below :

    texture2D(uSampler, vec2(0.25, 0.25));

    I would like to be able to use colour maps from bitmaps (1D or 2D) in rendering Mandelbrot fractals.

    The full Code is take from (https://developer.mozilla.org/samples/w ... index.html)

    Can this be done ... Examples AnyOne ??! ...

  2. #2
    Member
    Join Date
    Oct 2009
    Location
    London, UK
    Posts
    90

    Re: Read Colour Idx From BitMap

    Hi FlemsSolo,

    I'm a bit confused -- is the code that you give not working for you? It looks fine.


    Cheers,

    Giles

  3. #3
    Junior Member
    Join Date
    Apr 2010
    Posts
    2

    Re: Read Colour Idx From BitMap

    Hi Giles

    Sorry for not returning so often to look for replies .... And may I just say, that I look in on your LearningWebGL Blog several times a day .... it's a great place for tutorials and news from the WebGl community ... Outstanding work ...

    Yes, the referenced code is okay, but if I want to use my own parameters/variables for texture lookup, as for example the following code 'texture2D(uSampler, vec2(0.25, 0.25));' ... I get an error ...

    But maybe I should dig a little deeper into OpenGl to see if I can approach the problem from a wider perspective than that of the 'Rookie' ....

    Keep up the good work ....

    FlemsSolo, The Rotten State Of Denmark ....

  4. #4
    Member
    Join Date
    Oct 2009
    Location
    London, UK
    Posts
    90

    Re: Read Colour Idx From BitMap

    Hi FlemsSolo,

    Quote Originally Posted by FlemsSolo
    Sorry for not returning so often to look for replies ....
    Sorry for not replying here sooner!

    Quote Originally Posted by FlemsSolo
    And may I just say, that I look in on your LearningWebGL Blog several times a day .... it's a great place for tutorials and news from the WebGl community ... Outstanding work ...
    Thanks!

    Quote Originally Posted by FlemsSolo
    Yes, the referenced code is okay, but if I want to use my own parameters/variables for texture lookup, as for example the following code 'texture2D(uSampler, vec2(0.25, 0.25));' ... I get an error ...
    That sounds odd, I'd certainly expect that to work. What's the exact error message?


    Cheers,

    Giles

Similar Threads

  1. Bitmap Input to eglCreateImageKHR
    By shathie in forum OpenGL ES general technical discussions
    Replies: 1
    Last Post: 06-11-2012, 10:29 PM
  2. Open GL ES - Drawing bitmap
    By ychmin in forum OpenGL ES general technical discussions
    Replies: 1
    Last Post: 12-16-2010, 06:42 PM
  3. Bitmap texture
    By ifool in forum OpenGL ES general technical discussions
    Replies: 11
    Last Post: 01-04-2005, 09:59 PM

Posting Permissions

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