gs-rendertarget: Add function to get texture directly
This commit is contained in:
parent
a6f9451654
commit
fd14fd62a6
|
|
@ -57,6 +57,11 @@ gs_texture_t* gs::rendertarget::get_object()
|
||||||
return tex;
|
return tex;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::shared_ptr<gs::texture> gs::rendertarget::get_texture()
|
||||||
|
{
|
||||||
|
return std::make_shared<gs::texture>(get_object(), false);
|
||||||
|
}
|
||||||
|
|
||||||
void gs::rendertarget::get_texture(gs::texture& tex)
|
void gs::rendertarget::get_texture(gs::texture& tex)
|
||||||
{
|
{
|
||||||
tex = gs::texture(get_object(), false);
|
tex = gs::texture(get_object(), false);
|
||||||
|
|
|
||||||
|
|
@ -47,6 +47,8 @@ namespace gs {
|
||||||
|
|
||||||
gs_texture_t* get_object();
|
gs_texture_t* get_object();
|
||||||
|
|
||||||
|
std::shared_ptr<gs::texture> get_texture();
|
||||||
|
|
||||||
void get_texture(gs::texture& tex);
|
void get_texture(gs::texture& tex);
|
||||||
|
|
||||||
void get_texture(std::shared_ptr<gs::texture>& tex);
|
void get_texture(std::shared_ptr<gs::texture>& tex);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue