Commit 2534cd73 authored by Robert Menzel's avatar Robert Menzel

started renaming controler to creator

parent c70e1f03
......@@ -11,14 +11,14 @@
#ifdef ACGL_INCLUDE_DEPRECATED_FUNCTIONALITY
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Objects/ArrayBuffer.hh>
#include <ACGL/OpenGL/GL.hh>
namespace ACGL{
namespace OpenGL{
class ArrayBufferControl : public Resource::BasicCreateController<ArrayBuffer>
class ArrayBufferControl : public Resource::BasicCreateInterface<ArrayBuffer>
{
// ==================================================================================================== \/
// ============================================================================================ STRUCTS \/
......
......@@ -8,7 +8,7 @@
#define ACGL_OPENGL_CONTROLLER_ARRAYBUFFERCONTROLFILE_HH
#ifdef ACGL_INCLUDE_DEPRECATED_FUNCTIONALITY
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/Resource/SingleFileBasedCreator.hh>
#include <ACGL/OpenGL/Objects/ArrayBuffer.hh>
#include <ACGL/OpenGL/Controller/DataControlFile.hh>
......@@ -18,7 +18,7 @@
namespace ACGL{
namespace OpenGL{
class ArrayBufferControlFile : public Resource::FileController<ArrayBuffer>
class ArrayBufferControlFile : public Resource::SingleFileBasedCreator<ArrayBuffer>
{
// ===================================================================================================== \/
// ============================================================================================ TYPEDEFS \/
......@@ -34,7 +34,7 @@ public:
template<typename CONTROLLER>
ArrayBufferControlFile(const CONTROLLER& _fileController)
: Resource::FileController<ArrayBuffer>(_fileController.getFilename(), Base::Settings::the()->getFullGeometryPath()),
: Resource::SingleFileBasedCreator<ArrayBuffer>(_fileController.getFilename(), Base::Settings::the()->getFullGeometryPath()),
mDataController(new CONTROLLER(_fileController))
{}
virtual ~ArrayBufferControlFile(void) {}
......
......@@ -11,7 +11,7 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/Resource/SingleFileBasedCreator.hh>
#include <ACGL/Base/Settings.hh>
#include <ACGL/OpenGL/Objects/ArrayBuffer.hh>
#include <ACGL/OpenGL/Objects/ShaderProgram.hh>
......@@ -20,14 +20,14 @@
namespace ACGL{
namespace OpenGL{
class ArrayBufferControlFileATB : public Resource::FileController<ArrayBuffer>
class ArrayBufferControlFileATB : public Resource::SingleFileBasedCreator<ArrayBuffer>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
// ========================================================================================================= \/
public:
ArrayBufferControlFileATB(const std::string& _filename)
: Resource::FileController<ArrayBuffer>(_filename, Base::Settings::the()->getFullGeometryPath()),
: Resource::SingleFileBasedCreator<ArrayBuffer>(_filename, Base::Settings::the()->getFullGeometryPath()),
mpShaderProgram()
{}
virtual ~ArrayBufferControlFileATB() {}
......
......@@ -18,7 +18,7 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/Resource/SingleFileBasedCreator.hh>
#include <ACGL/Base/Settings.hh>
#include <ACGL/OpenGL/Data/TextureData.hh>
#include <ACGL/OpenGL/Data/GeometryData.hh>
......@@ -27,7 +27,7 @@ namespace ACGL{
namespace OpenGL{
template<class DATA_FILE_TYPE>
class DataControlFile : public Resource::FileController<DATA_FILE_TYPE>
class DataControlFile : public Resource::SingleFileBasedCreator<DATA_FILE_TYPE>
{
private:
typedef ptr::shared_ptr< DATA_FILE_TYPE > SharedDATA_FILE_TYPE;
......@@ -36,7 +36,7 @@ private:
// ========================================================================================================= \/
public:
DataControlFile(const std::string& _filename, const std::string& _resourcePath)
: Resource::FileController<DATA_FILE_TYPE>(_filename, _resourcePath)
: Resource::SingleFileBasedCreator<DATA_FILE_TYPE>(_filename, _resourcePath)
{}
virtual ~DataControlFile(void) {}
......@@ -52,7 +52,7 @@ private:
public:
virtual SharedDATA_FILE_TYPE create(void)
{
Resource::FileController<DATA_FILE_TYPE>::updateFileModificationTime();
Resource::SingleFileBasedCreator<DATA_FILE_TYPE>::updateFileModificationTime();
SharedDATA_FILE_TYPE texture(new DATA_FILE_TYPE());
......@@ -64,13 +64,13 @@ public:
virtual bool update(SharedDATA_FILE_TYPE& _data)
{
if (Resource::FileController<DATA_FILE_TYPE>::fileIsUpToDate())
if (Resource::SingleFileBasedCreator<DATA_FILE_TYPE>::fileIsUpToDate())
return false;
if(!load(_data))
return false;
Resource::FileController<DATA_FILE_TYPE>::updateFileModificationTime();
Resource::SingleFileBasedCreator<DATA_FILE_TYPE>::updateFileModificationTime();
return true;
}
......
......@@ -9,14 +9,14 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Objects/ElementArrayBuffer.hh>
#include <ACGL/OpenGL/GL.hh>
#ifdef ACGL_INCLUDE_DEPRECATED_FUNCTIONALITY
namespace ACGL{
namespace OpenGL{
class ElementArrayBufferControl : public Resource::BasicCreateController<ElementArrayBuffer>
class ElementArrayBufferControl : public Resource::BasicCreateInterface<ElementArrayBuffer>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......
......@@ -10,7 +10,7 @@
#ifdef ACGL_INCLUDE_DEPRECATED_FUNCTIONALITY
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Objects/FrameBufferObject.hh>
#include <ACGL/OpenGL/Data/LocationMappings.hh>
#include <ACGL/OpenGL/GL.hh>
......@@ -23,7 +23,7 @@
namespace ACGL{
namespace OpenGL{
class FrameBufferObjectControl : public Resource::BasicCreateController<FrameBufferObject>
class FrameBufferObjectControl : public Resource::BasicCreateInterface<FrameBufferObject>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......
......@@ -11,14 +11,14 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Data/LocationMappings.hh>
#include <ACGL/OpenGL/GL.hh>
namespace ACGL{
namespace OpenGL{
class LocationMappingsControl : public Resource::BasicCreateController<LocationMappings>
class LocationMappingsControl : public Resource::BasicCreateInterface<LocationMappings>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......
......@@ -11,14 +11,14 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Objects/RenderBuffer.hh>
#include <ACGL/OpenGL/GL.hh>
namespace ACGL{
namespace OpenGL{
class RenderBufferControl : public Resource::BasicCreateController<RenderBuffer>
class RenderBufferControl : public Resource::BasicCreateInterface<RenderBuffer>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......
......@@ -13,13 +13,13 @@
#include <ACGL/OpenGL/GL.hh>
#if (ACGL_OPENGL_VERSION >= 30)
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/HiLevelObjects/RenderObject.hh>
namespace ACGL{
namespace OpenGL{
class RenderObjectControl : public Resource::BasicCreateController<RenderObject>
class RenderObjectControl : public Resource::BasicCreateInterface<RenderObject>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......
/***********************************************************************
* Copyright 2011-2012 Computer Graphics Group RWTH Aachen University. *
* Copyright 2011-2013 Computer Graphics Group RWTH Aachen University. *
* All rights reserved. *
* Distributed under the terms of the MIT License (see LICENSE.TXT). *
**********************************************************************/
#ifndef ACGL_OPENGL_CONTROLLER_SHADERCONTROLFILE_HH
#define ACGL_OPENGL_CONTROLLER_SHADERCONTROLFILE_HH
#pragma once
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/Base/Settings.hh>
#include <ACGL/OpenGL/Objects/Shader.hh>
#include <ACGL/OpenGL/GL.hh>
#include <ACGL/OpenGL/Creator/ShaderCreator.hh>
namespace ACGL{
namespace OpenGL{
class ShaderControlFile : public Resource::FileController<Shader>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
// ========================================================================================================= \/
public:
ShaderControlFile(const std::string& _filename)
: Resource::FileController<Shader>(_filename, Base::Settings::the()->getFullShaderPath()),
mType(GL_INVALID_ENUM)
{}
virtual ~ShaderControlFile(void) {}
// ==================================================================================================== \/
// ============================================================================================ METHODS \/
// ==================================================================================================== \/
public:
inline ShaderControlFile& type (GLenum _type) { mType = _type; return *this; }
// ===================================================================================================== \/
// ============================================================================================ OVERRIDE \/
// ===================================================================================================== \/
public:
virtual SharedShader create(void);
virtual bool update(SharedShader& shader);
// =================================================================================================== \/
// ============================================================================================ FIELDS \/
// =================================================================================================== \/
protected:
GLenum mType;
struct ImportedShader {
std::string fileName;
Utils::FileHelpers::FileModificationTime modificatonTime;
};
std::vector< ImportedShader > mImportedShaders; // in case the shader imports additional shaders files
};
} // OpenGL
} // ACGL
typedef ACGL::OpenGL::ShaderCreator ShaderControlFile;
#endif // ACGL_OPENGL_CONTROLLER_SHADERCONTROLFILE_HH
}
}
/***********************************************************************
* Copyright 2011-2012 Computer Graphics Group RWTH Aachen University. *
* Copyright 2011-2013 Computer Graphics Group RWTH Aachen University. *
* All rights reserved. *
* Distributed under the terms of the MIT License (see LICENSE.TXT). *
**********************************************************************/
#ifndef ACGL_OPENGL_CONTROLLER_SHADERPROGRAMCONTROLFILES_HH
#define ACGL_OPENGL_CONTROLLER_SHADERPROGRAMCONTROLFILES_HH
#pragma once
/**
* Used to create a ShaderProgram from a given set of file names:
* e.g.:
* SharedShaderProgram prog = ShaderProgramControlFiles("file.vsh").andFile("foobar.fsh").create();
*
* The shadertype will be guessed by the extensions.
*/
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/MultiFileController.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/OpenGL/Objects/ShaderProgram.hh>
#include <ACGL/OpenGL/GL.hh>
#include <ACGL/Base/Settings.hh>
#include <vector>
#include <ACGL/OpenGL/Data/LocationMappings.hh>
#include <ACGL/OpenGL/Creator/ShaderProgramCreator.hh>
namespace ACGL{
namespace OpenGL{
class ShaderProgramControlFiles : public Resource::MultiFileController<ShaderProgram>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
// ========================================================================================================= \/
public:
//! The filenames (sorted and concatenated) will also be the name of the resource (can be changed by setResourceName() below).
//! If the filename has a dot in it (or _type is set), it will be treated as a single file, otherwise all
//! files starting with that string will be used.
ShaderProgramControlFiles(const std::string& _fileName, GLenum _type = GL_INVALID_VALUE )
: Resource::MultiFileController<ShaderProgram>(),
mShaderType(),
mAttributeLocations(new LocationMappings),
mFragmentDataLocations(new LocationMappings),
mUniformBufferLocations(new LocationMappings)
{
// the base path is only needed for updating the time stamps, as the shaders itself get loaded via ShaderControlFiles
// which itself will add the base path! (read: mFileNames will _NOT_ store the base path!)
mBasePath = Base::Settings::the()->getFullShaderPath();
if ( _type != GL_INVALID_VALUE ) {
andFile( _fileName, _type );
return;
}
// only add the first name if it is a valid file name
if ( _fileName.find( "." ) != std::string::npos ) {
andFile( _fileName );
} else {
autoFiles( _fileName );
}
}
virtual ~ShaderProgramControlFiles(void) {}
// ==================================================================================================== \/
// ============================================================================================ METHODS \/
// ==================================================================================================== \/
public:
//
// Adding files:
//
//! adds a single file, the shader type will be guessed by the ending:
inline ShaderProgramControlFiles& andFile (const std::string &_fileName) { addFile( _fileName ); mShaderType.push_back( GL_INVALID_VALUE ); return *this; }
//! adds a single file, the shader type is explicitly given and must be one of:
//! GL_VERTEX_SHADER, GL_TESS_CONTROL_SHADER, GL_TESS_EVALUATION_SHADER, GL_GEOMETRY_SHADER, GL_FRAGMENT_SHADER, GL_COMPUTE_SHADER
inline ShaderProgramControlFiles& andFile (const std::string &_fileName, GLenum _type) { addFile( _fileName ); mShaderType.push_back( _type ); return *this; }
//! adds all files begining with the given name, the shader type will be guessed by the ending:
ShaderProgramControlFiles& autoFiles (const std::string &_fileName);
//
// Adding attribute locations:
//
//! adds an attribute location to the next free location number:
inline ShaderProgramControlFiles& attributeLocation (const std::string &_attributeName) { mAttributeLocations->setLocation(_attributeName); return *this; }
//! adds an attribute location to the given location number:
inline ShaderProgramControlFiles& attributeLocation (const std::string &_attributeName, GLuint _location) { mAttributeLocations->setLocation(_attributeName,_location); return *this; }
//! adds a whole list of mappings
inline ShaderProgramControlFiles& attributeLocations (const SharedLocationMappings &_mapping) { mAttributeLocations->addLocations(_mapping); return *this; }
//! links to the external mapping object, earlyer mapping definitions get ignored, following
//! mappings will also change the external object!
inline ShaderProgramControlFiles& externAttributeLocations (SharedLocationMappings _mapping) { mAttributeLocations = _mapping; return *this; }
//
// Adding fragment output locations:
//
//! adds a fragment output location to the next free location number:
inline ShaderProgramControlFiles& fragmentDataLocation (const std::string &_fragmentDataName) { mFragmentDataLocations->setLocation(_fragmentDataName); return *this; }
//! adds a fragment output location to the given location number:
inline ShaderProgramControlFiles& fragmentDataLocation (const std::string &_fragmentDataName, GLuint _location) { mFragmentDataLocations->setLocation(_fragmentDataName,_location); return *this; }
//! adds a whole list of mappings
inline ShaderProgramControlFiles& fragmentDataLocations(const SharedLocationMappings &_mapping) { mFragmentDataLocations->addLocations(_mapping); return *this; }
//! links to the external mapping object, earlyer mapping definitions get ignored, following
//! mappings will also change the external object!
inline ShaderProgramControlFiles& externFragmentDataLocations (SharedLocationMappings _mapping) { mFragmentDataLocations = _mapping; return *this; }
//
// Adding uniform buffer locations:
//
//! adds an attribute location to the next free location number:
inline ShaderProgramControlFiles& uniformBufferLocation(const std::string &_uniformBufferName) { mUniformBufferLocations->setLocation(_uniformBufferName); return *this; }
//! adds an attribute location to the given location number:
inline ShaderProgramControlFiles& uniformBufferLocation(const std::string &_uniformBufferName, GLuint _location){ mUniformBufferLocations->setLocation(_uniformBufferName,_location);return *this; }
//! adds a whole list of mappings
inline ShaderProgramControlFiles& uniformBufferLocations(SharedLocationMappings _mapping) { mUniformBufferLocations->addLocations(_mapping);return *this; }
inline ShaderProgramControlFiles& externUniformBufferLocations(SharedLocationMappings _mapping) { mUniformBufferLocations = _mapping; return *this; }
//
// Modifying the resource name:
// A ShaderProgram consists of multiple shader files, so associating the ShaderProgram with just one of those file names
// is often not useful.
//
inline ShaderProgramControlFiles& setResourceName(const std::string &_resourceName) { mResourceName = _resourceName; return *this; }
// ===================================================================================================== \/
// ============================================================================================ OVERRIDE \/
// ===================================================================================================== \/
public:
virtual SharedShaderProgram create(void);
virtual bool update(SharedShaderProgram &_shaderProgram);
// =================================================================================================== \/
// ============================================================================================ FIELDS \/
// =================================================================================================== \/
protected:
std::vector<GLenum> mShaderType;
SharedLocationMappings mAttributeLocations;
SharedLocationMappings mFragmentDataLocations;
SharedLocationMappings mUniformBufferLocations;
private:
// set attribute, UBO & fragdata locations and links the program
bool setBindings(SharedShaderProgram &_shaderProgram);
};
} // OpenGL
} // ACGL
typedef ACGL::OpenGL::ShaderProgramCreator ShaderProgramControlFiles;
#endif // ACGL_OPENGL_CONTROLLER_SHADERPROGRAMCONTROLFILES_HH
}
}
......@@ -9,7 +9,7 @@
#ifdef ACGL_INCLUDE_DEPRECATED_FUNCTIONALITY
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/Resource/SingleFileBasedCreator.hh>
#include <ACGL/OpenGL/HiLevelObjects/ShaderProgramObject.hh>
#include <ACGL/OpenGL/GL.hh>
......@@ -18,7 +18,7 @@
namespace ACGL{
namespace OpenGL{
class ShaderProgramObjectControl : public Resource::BasicCreateController<ShaderProgramObject>
class ShaderProgramObjectControl : public Resource::BasicCreateInterface<ShaderProgramObject>
{
// ==================================================================================================== \/
// ============================================================================================ STRUCTS \/
......@@ -48,7 +48,7 @@ public:
// ========================================================================================================= \/
public:
ShaderProgramObjectControl(const ConstSharedShaderProgram& _shaderProgram)
: Resource::BasicCreateController<ShaderProgramObject>(),
: Resource::BasicCreateInterface<ShaderProgramObject>(),
mShaderProgram(_shaderProgram),
mUniformAttachmentDefines(),
mUniformTextureAttachmentDefines()
......
......@@ -16,21 +16,21 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Objects/Texture.hh>
#include <ACGL/OpenGL/GL.hh>
namespace ACGL{
namespace OpenGL{
class TextureControl : public Resource::BasicCreateController<Texture>
class TextureControl : public Resource::BasicCreateInterface<Texture>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
// ========================================================================================================= \/
public:
TextureControl(void)
: Resource::BasicCreateController<Texture>(),
: Resource::BasicCreateInterface<Texture>(),
mWidth(0),
mHeight(0),
mDepth(0),
......
......@@ -15,7 +15,7 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Data/TextureData.hh>
#include <ACGL/OpenGL/Objects/Texture.hh>
#include <ACGL/OpenGL/GL.hh>
......@@ -23,14 +23,14 @@
namespace ACGL{
namespace OpenGL{
class TextureControlCubeMap : public Resource::BasicCreateController<Texture>
class TextureControlCubeMap : public Resource::BasicCreateInterface<Texture>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
// ========================================================================================================= \/
public:
TextureControlCubeMap(void)
: Resource::BasicCreateController<Texture>(),
: Resource::BasicCreateInterface<Texture>(),
mPositiveX(),
mNegativeX(),
mPositiveY(),
......
......@@ -11,14 +11,14 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/Resource/SingleFileBasedCreator.hh>
#include <ACGL/OpenGL/Controller/DataControlFile.hh>
#include <ACGL/OpenGL/Objects/Texture.hh>
namespace ACGL{
namespace OpenGL{
class TextureControlFile : public Resource::FileController<Texture>
class TextureControlFile : public Resource::SingleFileBasedCreator<Texture>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......@@ -29,7 +29,7 @@ public:
template<typename CONTROLLER>
TextureControlFile(const CONTROLLER& _fileController)
: Resource::FileController<Texture>(_fileController.getFilename(), Base::Settings::the()->getFullTexturePath()),
: Resource::SingleFileBasedCreator<Texture>(_fileController.getFilename(), Base::Settings::the()->getFullTexturePath()),
mDataController(new CONTROLLER(_fileController)),
mMinFilter(0),
mMagFilter(0),
......
......@@ -11,7 +11,7 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/HiLevelObjects/Uniform.hh>
#include <ACGL/OpenGL/GL.hh>
......@@ -19,7 +19,7 @@ namespace ACGL{
namespace OpenGL{
template<class UNIFORM>
class UniformControl : public Resource::BasicCreateController<UNIFORM>
class UniformControl : public Resource::BasicCreateInterface<UNIFORM>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......
......@@ -9,7 +9,7 @@
#ifdef ACGL_INCLUDE_DEPRECATED_FUNCTIONALITY
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/Objects/VertexArrayObject.hh>
#include <ACGL/OpenGL/Objects/ArrayBuffer.hh>
#include <ACGL/OpenGL/Objects/ElementArrayBuffer.hh>
......@@ -22,7 +22,7 @@
namespace ACGL{
namespace OpenGL{
class VertexArrayObjectControl : public Resource::BasicCreateController<VertexArrayObject>
class VertexArrayObjectControl : public Resource::BasicCreateInterface<VertexArrayObject>
{
// ===================================================================================================== \/
// ============================================================================================ TYPEDEFS \/
......
......@@ -9,7 +9,7 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/FileController.hh>
#include <ACGL/Resource/SingleFileBasedCreator.hh>
#include <ACGL/OpenGL/Controller/DataControlFile.hh>
#include <ACGL/OpenGL/Objects/VertexArrayObject.hh>
#include <ACGL/OpenGL/Data/LocationMappings.hh>
......@@ -19,7 +19,7 @@
namespace ACGL{
namespace OpenGL{
class VertexArrayObjectControlFile : public Resource::FileController<VertexArrayObject>
class VertexArrayObjectControlFile : public Resource::SingleFileBasedCreator<VertexArrayObject>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......@@ -30,7 +30,7 @@ public:
template<typename CONTROLLER>
VertexArrayObjectControlFile(const CONTROLLER& _fileController)
: Resource::FileController<VertexArrayObject>(_fileController.getFilename(), Base::Settings::the()->getFullGeometryPath()),
: Resource::SingleFileBasedCreator<VertexArrayObject>(_fileController.getFilename(), Base::Settings::the()->getFullGeometryPath()),
mDataController(new CONTROLLER(_fileController)),
mAttributeLocations()
{}
......
......@@ -11,13 +11,13 @@
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/BasicCreateController.hh>
#include <ACGL/Resource/BasicCreateInterface.hh>
#include <ACGL/OpenGL/GL.hh>
namespace ACGL{
namespace OpenGL{
class ViewportControl : public Resource::BasicCreateController<Viewport>
class ViewportControl : public Resource::BasicCreateInterface<Viewport>
{
// ========================================================================================================= \/
// ============================================================================================ CONSTRUCTORS \/
......
/***********************************************************************
* Copyright 2011-2013 Computer Graphics Group RWTH Aachen University. *
* All rights reserved. *
* Distributed under the terms of the MIT License (see LICENSE.TXT). *
**********************************************************************/
#pragma once
/**
* Can create one Shader from one file.
* Most of the time using this directly is not useful as the creation
* of a whole ShaderProgam is desired.
*
* See ShaderProgramCreator for more information!
*/
#include <ACGL/ACGL.hh>
#include <ACGL/Resource/SingleFileBasedCreator.hh>
#include <ACGL/Base/Settings.hh>
#include <ACGL/OpenGL/Objects/Shader.hh>
#include <ACGL/OpenGL/GL.hh>
namespace ACGL{
namespace OpenGL{
class ShaderCreator : public Resource::SingleFileBasedCreator<Shader>
{