SFML community forums

Help => Graphics => Topic started by: angelpopangel on October 09, 2018, 07:45:50 am

Title: Copy of view in a second smaller control
Post by: angelpopangel on October 09, 2018, 07:45:50 am
Hi,
is it possible with SFML to have an exact copy of the output view and display it at a smaller size inside a second view? Like getting a copy of the complete output, scale it down and display it in another control.

I have a two monitor setup.
Monitor 1 has the user GUI and Monitor 2 views the output of SFML fullscreen.
I want to show a duplicate of the output in a smaller preview window/control on Monitor 1.

Thanks,
Angel

P.S.: BTW. using C# with Windows Forms
Title: Re: Copy of view in a second smaller control
Post by: tomvidm on October 09, 2018, 10:27:30 am
I'm only making a guess here, as I have not tried it yet.
But SFML has a feature called RenderTexture, which you can draw onto instead of the window. By doing this, you should be able to draw your scene onto the render texture, use it as a texture and render onto a larger rectangle and then render onto a smaller rectangle.

Again, I'm not sure, but these forums are not heavy on activity. If I'm completely off track here, try the IRC or Discord channel  :)
Title: Re: Copy of view in a second smaller control
Post by: angelpopangel on October 09, 2018, 10:46:50 am
Thanks tomvidm  :D

I thought about this method already but was unsure if it'd be the right way.
I will give it a try.

Cheers,
Angel