View Issue Details

IDProjectCategoryView StatusLast Update
0006014Spring engineGeneralpublic2018-07-16 08:50
Reporterlhog Assigned Toabma  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionno change required 
Product Version104.0 +git 
Summary0006014: Arrayed version of fbo.drawbuffers doesn't seem to work
DescriptionI'm using two version of the same code, the only exception being the the way fbo.drawbuffers are specified

One has:
fbo = gl.CreateFBO({color0 = blabla})
fbo.drawbuffers = GL_COLOR_ATTACHMENT0_EXT
and it works ok

Another has:
fbo = gl.CreateFBO({color0 = blabla})
fbo.drawbuffers = {GL_COLOR_ATTACHMENT0_EXT}
and then, the texture is becoming pitch black

I put some LOG_L traces into bool LuaFBOs::ApplyDrawBuffers(lua_State* L, int index) and found out that despite "else if (lua_istable(L, index) && GLEW_ARB_draw_buffers)" check is successful, attempts to read the table content result in zero read items. I also tried to rewrite the function a bit to https://hastebin.com/irikoqucuy.pl Isn't successful either.

I'm a bit lost why table content is empty...
Steps To Reproduce1. Create a texture blabla
2. Create an FBO using "fbo.drawbuffers = GL_COLOR_ATTACHMENT0_EXT"
3. Render something into the "blabla" texture while having the gl.ActiveFBO(fbo ...)
4. gl.Texture(0, blabla)
5. Draw it to the screen somehow
6. Observe success.
7. Change "fbo.drawbuffers = {GL_COLOR_ATTACHMENT0_EXT}"
8. Restart widget/gadget, observe black screen instead of the supposed content of "blabla"
TagsNo tags attached.
Checked infolog.txt for Errors

Activities

lhog

2018-07-16 01:38

reporter   ~0019237

Here is the example gadget, where line 0000051 makes drawing work, and line 0000050 instead of 0000051 make it does nothing:

https://hastebin.com/dovolekaze.bash

lhog

2018-07-16 01:40

reporter   ~0019238

No edit here :(

Here is the example gadget, where line 51 makes drawing work, and line 50 instead of 51 make it does nothing:

https://hastebin.com/dovolekaze.bash

lhog

2018-07-16 01:50

reporter   ~0019239

Disregard and close.
I'm stupid.

Issue History

Date Modified Username Field Change
2018-07-16 01:34 lhog New Issue
2018-07-16 01:38 lhog Note Added: 0019237
2018-07-16 01:40 lhog Note Added: 0019238
2018-07-16 01:50 lhog Note Added: 0019239
2018-07-16 08:50 abma Assigned To => abma
2018-07-16 08:50 abma Status new => closed
2018-07-16 08:50 abma Resolution open => no change required