Results 1 to 4 of 4

Thread: Firefox: bindFramebuffer?

  1. #1
    Member Coolcat's Avatar
    Join Date
    Oct 2009
    Location
    NRW, Germany
    Posts
    75

    Firefox: bindFramebuffer?

    Does anyone have tried to use FramebufferObjects on Firefox yet?

    When calling
    Code :
    gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);
    current Firefox Nightly just says
    Code :
    glBindFramebuffer: invalid target
    gl.FRAMEBUFFER has the correct value 0x8d40 (= 36160), so why do I get this error?

    Any ideas?

  2. #2
    Member Coolcat's Avatar
    Join Date
    Oct 2009
    Location
    NRW, Germany
    Posts
    75

    Re: Firefox: bindFramebuffer?

    The implementation looks a bit strange? What has target to do with LOCAL_GL_*_ATTACHMENT* ? According to spec the only valid value is FRAMEBUFFER.

    Code :
    398 NS_IMETHODIMP
    399 WebGLContext::BindFramebuffer(GLenum target, nsIWebGLFramebuffer *fb)
    400 {
    401     WebGLFramebuffer *wfb = static_cast<WebGLFramebuffer*>(fb);
    402 
    403     if (wfb && wfb->Deleted())
    404         return ErrorMessage("glBindFramebuffer: framebuffer has already been deleted!");
    405 
    406     MakeContextCurrent();
    407 
    408     if (target >= LOCAL_GL_COLOR_ATTACHMENT0 &&
    409         target < (LOCAL_GL_COLOR_ATTACHMENT0 + mBoundColorFramebuffers.Length()))
    410     {
    411         int targetOffset = target - LOCAL_GL_COLOR_ATTACHMENT0;
    412         mBoundColorFramebuffers[targetOffset] = wfb;
    413     } else if (target == LOCAL_GL_DEPTH_ATTACHMENT) {
    414         mBoundDepthFramebuffer = wfb;
    415     } else if (target == LOCAL_GL_STENCIL_ATTACHMENT) {
    416         mBoundStencilFramebuffer = wfb;
    417     } else {
    418         return ErrorMessage("glBindFramebuffer: invalid target");
    419     }
    420 
    421     gl->fBindFramebuffer(target, wfb ? wfb->GLName() : 0);
    422 
    423     return NS_OK;
    424 }

  3. #3
    Member Coolcat's Avatar
    Join Date
    Oct 2009
    Location
    NRW, Germany
    Posts
    75

    Re: Firefox: bindFramebuffer?


  4. #4
    Member Coolcat's Avatar
    Join Date
    Oct 2009
    Location
    NRW, Germany
    Posts
    75

    Re: Firefox: bindFramebuffer?

    Seems like FBOs are working on Firefox now.

Similar Threads

  1. Firefox
    By melissa_schnell in forum Developers Coding:Beginner
    Replies: 3
    Last Post: 12-09-2011, 04:29 AM
  2. 5+ Texture in Firefox
    By super_eggbert in forum OS & Browser specific questions
    Replies: 2
    Last Post: 01-03-2010, 07:20 AM

Posting Permissions

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