Skip to content

Commit

Permalink
ver. 1.3.1 - Added new rendering engine features also to WebGL version
Browse files Browse the repository at this point in the history
  • Loading branch information
BrutPitt committed Sep 2, 2019
1 parent 5f7d4a8 commit 24a08d5
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 8 deletions.
Binary file modified src/msBuilds/vs2017.sln/.vs/Particles/v16/.suo
Binary file not shown.
7 changes: 3 additions & 4 deletions src/src/ShadersClasses.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -993,7 +993,6 @@ void postRenderingClass::bindRender()
#else
glActiveTexture(GL_TEXTURE0 + renderEngine->getAO()->getFBO().getTex(0));
glBindTexture(GL_TEXTURE_2D, renderEngine->getAO()->getFBO().getTex(0));
glUniform1i(getLocAOTex(), renderEngine->getAO()->getFBO().getTex(0));

// for Chrome76 message: "texture is not renderable" if only zBuffer... need ColorBuffer
// FireFox68 Works fine also only with zBuffer w/o ColorBuffer
Expand All @@ -1004,7 +1003,6 @@ void postRenderingClass::bindRender()
#else
glActiveTexture(GL_TEXTURE0 + renderEngine->getShadow()->getFBO().getTex(0));
glBindTexture(GL_TEXTURE_2D, renderEngine->getShadow()->getFBO().getTex(0));
glUniform1i(getLocShadowTex(), renderEngine->getShadow()->getFBO().getTex(0));
#endif
#endif

Expand Down Expand Up @@ -1113,6 +1111,9 @@ void ambientOcclusionClass::create() {
locKernelTexture = getUniformLocation("ssaoSample");
uniformBlocksClass::bindIndex(getProgram(), "_particlesData");
renderEngine->getTMat()->blockBinding(getProgram());

glUniform1i(locKernelTexture, ssaoKernelTex);
glUniform1i(locNoiseTexture, noiseTexture);
#endif
//setUniform3fv(getUniformLocation("ssaoSamples"), kernelSize, (const GLfloat*)ssaoKernel.data());
}
Expand All @@ -1136,8 +1137,6 @@ void ambientOcclusionClass::bindRender()
glActiveTexture(GL_TEXTURE0 + ssaoKernelTex);
glBindTexture(GL_TEXTURE_2D, ssaoKernelTex);

glUniform1i(locKernelTexture, ssaoKernelTex);
glUniform1i(locNoiseTexture, noiseTexture);
#endif
}

Expand Down
2 changes: 1 addition & 1 deletion src/src/appDefines.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
//#define APP_DEBUG_GUI_INTERFACE


//#define GLAPP_IMGUI_VIEWPORT
#define GLAPP_IMGUI_VIEWPORT

#ifdef __EMSCRIPTEN__
#define DOT_TEXT_SHFT 1
Expand Down
2 changes: 1 addition & 1 deletion src/src/configFile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ void getRenderMode(Config &c, particlesBaseClass *ptr)


ptr->useShadow( c.get_or("ShadowEnabled" , false ));
ptr->setShadowBias( c.get_or("ShadowBias" , 0.0 ));
ptr->setShadowBias( c.get_or("ShadowBias" , 0.015 ));
ptr->setShadowDarkness( c.get_or("ShadowDarkness" , 0.0 ));
ptr->setShadowRadius( c.get_or("ShadowRadius" , 2.0 ));
ptr->setShadowGranularity( c.get_or("ShadowGranularity" , 1.0 ));
Expand Down
1 change: 0 additions & 1 deletion src/src/libs/glfw/buildOSX/lib/libglfw.3.3.dylib
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
libglfw.3.dylib
4 changes: 4 additions & 0 deletions src/src/ui/uiAttractorsDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,11 @@ void attractorDlgClass::view()

const float border = DLG_BORDER_SIZE;
//const float oldWindowPadding = style.WindowPadding.x;
#if !defined(GLCHAOSP_LIGHTVER)
const int szX = 600, szY = 270;
#else
const int szX = 450, szY = 200;
#endif
ImGui::SetNextWindowSize(ImVec2(szX, szY), ImGuiCond_FirstUseEver);
{
int w,h; glfwGetWindowSize(theApp->getGLFWWnd(), &w, &h);
Expand Down
2 changes: 1 addition & 1 deletion src/src/ui/uiMainDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1207,7 +1207,7 @@ void particlesDlgClass::view()
bool psSelected = theWnd->getParticlesSystem()->whichRenderMode==RENDER_USE_POINTS || theWnd->getParticlesSystem()->getRenderMode() == RENDER_USE_BOTH;

#if !defined(GLCHAOSP_LIGHTVER) || defined(GLCHAOSP_LIGHTVER_EXPERIMENTAL)
const int wSZ = 300, hSZ = 1020;
const int wSZ = 270, hSZ = 1020;
#else
const int wSZ = theApp->isTabletMode() ? 300 : 270, hSZ = theApp->isTabletMode() ? 900 : 820;
#endif
Expand Down

0 comments on commit 24a08d5

Please sign in to comment.