Module FBO

FBO


See also:

Functions

gl.CreateFBO
gl.DeleteFBO
gl.IsValidFBO
gl.ActiveFBO
gl.BlitFBO
needs GLEW_EXT_framebuffer_blit
gl.BlitFBO
needs GLEW_EXT_framebuffer_blit

Tables

attachment
fbo
User Data FBO

Functions

gl.CreateFBO(data)

Parameters:

  1. data

gl.DeleteFBO(fbo)

This doesn't delete the attached objects!

Parameters:

  1. fbo fbo

gl.IsValidFBO(fbo[, target])

Parameters:

  1. fbo fbo
  2. target number (optional)

Returns:

  1. bool valid
  2. optional number status

gl.ActiveFBO(fbo[, target[, identities[, lua_function[, arg1[, arg2[, argn]]]]]])

Parameters:

  1. fbo fbo
  2. target number (optional)
  3. identities bool (optional)
  4. lua_function func (optional)
  5. arg1 (optional)
  6. arg2 (optional)
  7. argn (optional)

gl.BlitFBO(x0Src, y0Src, x1Src, y1Src, x0Dst, y0Dst, x1Dst, y1Dst[, mask=GL_COLOR_BUFFER_BIT[, filter=GL_NEAREST]])

needs `GLEW_EXT_framebuffer_blit`

Parameters:

  1. x0Src number
  2. y0Src number
  3. x1Src number
  4. y1Src number
  5. x0Dst number
  6. y0Dst number
  7. x1Dst number
  8. y1Dst number
  9. mask number (default GL_COLOR_BUFFER_BIT)
  10. filter number (default GL_NEAREST)

gl.BlitFBO(fboSrc, x0Src, y0Src, x1Src, y1Src, fboDst, x0Dst, y0Dst, x1Dst, y1Dst[, mask=GL_COLOR_BUFFER_BIT[, filter=GL_NEAREST]])

needs `GLEW_EXT_framebuffer_blit`

Parameters:

  1. fboSrc fbo
  2. x0Src number
  3. y0Src number
  4. x1Src number
  5. y1Src number
  6. fboDst fbo
  7. x0Dst number
  8. y0Dst number
  9. x1Dst number
  10. y1Dst number
  11. mask number (default GL_COLOR_BUFFER_BIT)
  12. filter number (default GL_NEAREST)

Tables

attachment

attachment ::= luaTex or `RBO.rbo` or nil or { luaTex [, num target [, num level ] ] }

fbo

User Data FBO

Fields:

  1. depth attachment
  2. stencil attachment
  3. color0 attachment
  4. color1 attachment
  5. color2 attachment
  6. colorn attachment
  7. color15 attachment
  8. drawbuffers table { GL_COLOR_ATTACHMENT0_EXT, GL_COLOR_ATTACHMENT3_EXT, ..}
  9. readbuffer table GL_COLOR_ATTACHMENT0_EXT