Ejemplo n.º 1
0
//----------------------------------------------------------------------------//
Texture& Direct3D9Renderer::createTexture(const String& name, const Sizef& size)
{
    throwIfNameExists(name);

    Direct3D9Texture* tex = new Direct3D9Texture(*this, name, size);
    d_textures[name] = tex;

    logTextureCreation(name);

    return *tex;
}
Ejemplo n.º 2
0
//----------------------------------------------------------------------------//
Texture& Direct3D10Renderer::createTexture(const String& name)
{
    throwIfNameExists(name);

    Direct3D10Texture* tex = new Direct3D10Texture(*d_device, name);
    d_textures[name] = tex;

    logTextureCreation(name);

    return *tex;
}
Ejemplo n.º 3
0
//----------------------------------------------------------------------------//
Texture& NullRenderer::createTexture(const String& name, const Sizef& size)
{
    throwIfNameExists(name);

    NullTexture* t = new NullTexture(name, size);
    d_textures[name] = t;

    logTextureCreation(name);

    return *t;
}
Ejemplo n.º 4
0
//----------------------------------------------------------------------------//
Texture& NullRenderer::createTexture(const String& name, const String& filename,
                                     const String& resourceGroup)
{
    throwIfNameExists(name);

    NullTexture* t = new NullTexture(name, filename, resourceGroup);
    d_textures[name] = t;

    logTextureCreation(name);

    return *t;
}
Ejemplo n.º 5
0
//----------------------------------------------------------------------------//
Texture& Direct3D9Renderer::createTexture(const String& name,
                                          LPDIRECT3DTEXTURE9 texture)
{
    throwIfNameExists(name);

    Direct3D9Texture* tex = new Direct3D9Texture(*this, name, texture);
    d_textures[name] = tex;

    logTextureCreation(name);

    return *tex;
}
Ejemplo n.º 6
0
//----------------------------------------------------------------------------//
Texture& DirectFBRenderer::createTexture(const CEGUI::String& name)
{
    if (d_textures.find(name) != d_textures.end())
        CEGUI_THROW(AlreadyExistsException(
            "A texture named '" + name + "' already exists."));

    DirectFBTexture* tex = new DirectFBTexture(d_directfb, name);
    d_textures[name] = tex;

    logTextureCreation(tex);

    return *tex;
}
Ejemplo n.º 7
0
//----------------------------------------------------------------------------//
Texture& OpenGLRendererBase::createTexture(const String& name, const Sizef& size)
{
    if (d_textures.find(name) != d_textures.end())
        CEGUI_THROW(AlreadyExistsException(
            "A texture named '" + name + "' already exists."));

    OpenGLTexture* tex = CEGUI_NEW_AO OpenGLTexture(*this, name, size);
    d_textures[name] = tex;

    logTextureCreation(name);

    return *tex;
}
Ejemplo n.º 8
0
//----------------------------------------------------------------------------//
Texture& OpenGL3Renderer::createTexture(const String& name)
{
    if (d_textures.find(name) != d_textures.end())
        CEGUI_THROW(AlreadyExistsException(
            "A texture named '" + name + "' already exists."));

    OpenGL3Texture* tex = new OpenGL3Texture(*this, name);
    d_textures[name] = tex;

    logTextureCreation(name);

    return *tex;
}
Ejemplo n.º 9
0
//----------------------------------------------------------------------------//
Texture& Direct3D9Renderer::createTexture(const String& name,
                                          const String& filename,
                                          const String& resourceGroup)
{
    throwIfNameExists(name);

    Direct3D9Texture* tex =
        new Direct3D9Texture(*this, name, filename, resourceGroup);
    d_textures[name] = tex;

    logTextureCreation(name);

    return *tex;
}
Ejemplo n.º 10
0
//----------------------------------------------------------------------------//
Texture& OpenGLRenderer::createTexture(const String& name, GLuint tex,
                                       const Sizef& sz)
{
    if (d_textures.find(name) != d_textures.end())
        CEGUI_THROW(AlreadyExistsException(
            "A texture named '" + name + "' already exists."));

    OpenGLTexture* t = new OpenGLTexture(*this, name, tex, sz);
    d_textures[name] = t;

    logTextureCreation(name);

    return *t;
}