On Friday, 3 February 2017 at 17:20:43 UTC, WhatMeWorry wrote:
---------------------file post_processor.d ----------
module post_processor;
class PostProcessor
{
...
GLuint FBO;
....
}
---------------------file game.d -------------------
module game;
PostProcessor postProc; // just a declaration (no memory
allocation)
class Game
{
...
void initGame(){
...
PostProcessor postProc = new PostProcessor(...);
The error is in this line. Instead of assigning to the `postProc`
at module scope, you are defining a new local variable and
assigning to it.
...
}
...
void update(GLfloat deltaTime){
...
writeln("Right Before");
writeln("postProcesor.FBO = ", postProc.FBO);
writeln("Right After);
...
}
...
}