Renamed osg::ComputeDispatch to osg::DispatchCompute to make sure the nameing between GL and OSG is consistent i.e glDispatchCompute -> osg::DispatchCompute

Updated AUTHORS.txt, NEWS.txt and README.txt for CMakeLists.txt for 3.6.0 release
This commit is contained in:
Robert Osfield
2018-04-07 17:59:55 +01:00
parent 7c7a904315
commit 7ab1208c65
10 changed files with 99 additions and 90 deletions

View File

@@ -10,7 +10,7 @@
#include <osg/StateAttributeCallback>
#include <osg/Texture2D>
#include <osg/Geometry>
#include <osg/ComputeDispatch>
#include <osg/DispatchCompute>
#include <osgDB/ReadFile>
#include <osgGA/StateSetManipulator>
#include <osgViewer/Viewer>
@@ -167,7 +167,7 @@ class ComputeNode : public osg::PositionAttitudeTransform
public:
osg::ref_ptr<osg::ComputeDispatch> _computeDispatch;
osg::ref_ptr<osg::DispatchCompute> _DispatchCompute;
osg::ref_ptr<osg::Program> _computeProgram;
osg::ref_ptr<osg::Shader> _computeShader; //compute and write position data in SSBO
@@ -205,8 +205,8 @@ public:
_vertexShaderSourcePath = "shaders/osgssboVertexShader.vs";
_geometryShaderSourcePath = "shaders/osgssboGeometryShader.gs";
_fragmentShaderSourcePath = "shaders/osgssboFragmentShader.fs";
_computeDispatch=new osg::ComputeDispatch();
addChild(_computeDispatch);
_DispatchCompute=new osg::DispatchCompute();
addChild(_DispatchCompute);
}
};
@@ -625,7 +625,7 @@ void ComputeNode::initComputingSetup()
{
_computeProgram = new osg::Program;
_computeDispatch->setComputeGroups((NUM_ELEMENTS_X / WORK_GROUP_SIZE) <= 1 ? 1 : (NUM_ELEMENTS_X / WORK_GROUP_SIZE), (NUM_ELEMENTS_Y / WORK_GROUP_SIZE) <= 1 ? 1 : (NUM_ELEMENTS_Y / WORK_GROUP_SIZE), 1);
_DispatchCompute->setComputeGroups((NUM_ELEMENTS_X / WORK_GROUP_SIZE) <= 1 ? 1 : (NUM_ELEMENTS_X / WORK_GROUP_SIZE), (NUM_ELEMENTS_Y / WORK_GROUP_SIZE) <= 1 ? 1 : (NUM_ELEMENTS_Y / WORK_GROUP_SIZE), 1);
_computeShader = osgDB::readRefShaderFile(osg::Shader::COMPUTE, _computeShaderSourcePath);
_computeProgram->addShader(_computeShader.get());