Jump to content

  • Log In with Google      Sign In   
  • Create Account

Interested in a FREE copy of HTML5 game maker Construct 2?

We'll be giving away three Personal Edition licences in next Tuesday's GDNet Direct email newsletter!

Sign up from the right-hand sidebar on our homepage and read Tuesday's newsletter for details!


fread

Member Since 04 Dec 2012
Offline Last Active Yesterday, 08:02 AM

Posts I've Made

In Topic: DirectX9 - create cubemap texture from memory?

24 June 2014 - 08:59 AM

thank you guys, i managed to fix it, but when rendering cubemap with shaders (texCube stuff) the corners of my skybox are "cut off". They are black, while the rest of cubemap is drawn valid. What's wrong?


In Topic: Drastic performance loss

09 June 2014 - 01:10 PM

I guess that integer image coordinates are not supported by GPU and they are convertex to floats on the way


In Topic: Cascaded shadow mapping and potential shadow casters

09 June 2014 - 10:16 AM

I'm having similiar troubles as you. I think the topic is covered in GPU gems, but that's not much.


In Topic: sampling a depth cubemap FBO texture results in gl error

05 June 2014 - 08:30 AM

It happens only if I enable a shadow mapping.

 

And I read that:

 

 

GL_INVALID_OPERATION is generated if a non-zero buffer object name is bound to an enabled array or the element array and the buffer object's data store is currently mapped.

buffer object = frame buffer.

currently maped = frame buffer bound for writing

This ain't right?

 

So what is wrong, then? Why is cubemap sampler read giving me invalid operation error and strange shadows?

If I comment out cubemap reading in lighting shader everything is OK. Any ideas?

 

EDIT:
To put it straight, take a look:

 

this code causes this error:


float ShadowMapValue = texture(Sampler_ShadowCubeMap,Vec3ShadowDir).x;

and this code works OK:


float ShadowMapValue = 1.0; //////////*texture(Sampler_ShadowCubeMap,Vec3ShadowDir).x;*/

so something must be related to "texture" function call and Shadow CubeMap sampling


In Topic: sampling a depth cubemap FBO texture results in gl error

05 June 2014 - 02:53 AM

Thank you for pointing this stuff, but my shadows still aren't working.

I think I cleared error flag before glDrawElements, I am calling glGetError very often.

Anyway, here is the entire log of my OpenGL calls, starting from unbinding the FBO (after I have drawn six views to it), and ending with gl error.

 

Please take a look:

11tv0qa.jpg

 

 

EDIT: just note that my old code with the same shadow map cubemap code but for old openGL (without compatilibity mode) is working on the same PC...


PARTNERS