Planetside Software Forums

General => Terragen Discussion => Topic started by: Stormlord on June 21, 2021, 09:14:04 AM

Title: REQUEST - Stay Open button in Render Window
Post by: Stormlord on June 21, 2021, 09:14:04 AM
Might it be possible to implement a "Stay Open" button in the Render Window in the next TG version?
Often I change some settings and when I do, the render window automatically dispaears.
Each time I need to bring it up again to have a look at the render to adjust my settings here and there... this behaviour SUC...S!

THX

STORMLORD
Title: Re: REQUEST - Stay Open button in Render Window
Post by: Dune on June 21, 2021, 12:27:28 PM
F3.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: KlausK on June 21, 2021, 06:11:17 PM
My render view never closes itself. It is just not "on top of everything else".
Do you mean that?
So if you activate the program window the render view goes to the background but is still open.
Alt+Tab would also work to get it back up front.

I have it on a second monitor so I can always see it.

CHeers, Klaus
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 22, 2021, 10:39:40 AM
I would think that is intentional behavior: If I want to make settings in Terragen while a job is being rendered, the render window has to go into the background so you can work. unless you have multiple screens or multiple desktops (Mac).

I would like to extend Stormlord's wish: It would be nice to run the rendering process in a separate process (program?) (independent from Terragen). Just like Stormlord, I wanted to make another change to a setting during a final render (High CPU load), with the result that Terragen and the render running with it crashed. With the render in its own process, it probably would not have crashed, or only Terragen would have crashed without affecting the render itself.
In a sense, export the render job from Terragen to the "separate" renderer.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: Dune on June 22, 2021, 11:33:42 AM
Then you'd better open another session of TG and render the file there, whilst working in the first session. But it's prone to mistakes when saving and so on. I always stick to testrendering, stop, work/adjust, testrender, stop, etc.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 22, 2021, 12:11:21 PM
I do that most of the time, of course, but...shit happens!
What do you mean by "open another session"?
As far as I know, you can't open multiple instances of Terragen (on Mac) to work in parallel. I open Terragen and that's it.... Or am I not understanding something correctly?
Title: Re: REQUEST - Stay Open button in Render Window
Post by: Dune on June 23, 2021, 02:42:45 AM
I sometimes open another blank session to check out an object before importing it in a big scene, or to grab some nodes (copy/paste) from one file into another. Just hit the shortcut to TGD.exe again, but that's PC. Don't know about Mac.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 23, 2021, 04:08:06 AM
When I try to open a second, empty session here (Terragen for Mac) during an open session, I only get the "Close" dialog for the open session. Apparently it is not possible to open parallel sessions under macOS. You can switch back and forth between two sessions, but you have to save, close and reopen them again and again, which is very inconvenient. I guess I have to live with the risk of an unintentional crash when Terragen is almost at full capacity due to rendering and/or editing.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: KlausK on June 23, 2021, 04:44:26 AM
I don`t know if that still works but back in the days you would have to use the terminal to run another instance of a program.

"Trying to use the Finder to open multiple instances of an application on Mac OS X will simply cause the first instance to come to the foreground.
To get around this, use the open command from the command line with the -n option.
The -n option opens a new instance of the application even if one is already running."

Or this:

"First, open the application you want to run in multiple instances.
Then, hold down the Shift key on your keyboard and click with your cursor - or tap with your finger - on its taskbar icon.
One click or tap opens a new instance, two clicks or taps open two, and so on."

CHeers, Klaus

ps: a search for "two instances of program mac os" or similar got a lot of results. If the two above do not work there is more ;)
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 23, 2021, 06:07:50 AM
Thanks @KlausK, I will try the terminal trick when I get a chance.
Most of the tips for this problem are already a few years old and no longer work with macOS Big Sur. Apple (unfortunately) has a habit of changing also terminal commands from update to update without officially informing the user.
In summary: Apple (macOS) does not support multiple opening of programs, unless the program inherently supports multi-window mode. Anything else is trial and error at your own risk.

https://www.quora.com/Can-I-open-two-instances-of-the-same-app-on-a-Mac-not-referring-to-two-windows-for-multi-window-apps (https://www.quora.com/Can-I-open-two-instances-of-the-same-app-on-a-Mac-not-referring-to-two-windows-for-multi-window-apps)
Title: Re: REQUEST - Stay Open button in Render Window
Post by: KlausK on June 23, 2021, 07:52:52 AM
I see. I am not familiar with new Mac OSes anymore...the last one I used must have been Leopard or something, I think.
Gonna have to start my old Macbook with FinalCut7 again some time and take a look...;)

CHeers, Klaus
Title: Re: REQUEST - Stay Open button in Render Window
Post by: WAS on June 26, 2021, 07:42:45 PM
I think I see the actual issue...

When a render completes, it goes behind the Terragen GUI, but if you click the Render Window below TG, it doesn't respond! Weird. I have to either Alt + Tab, or hover over the program (Windows 7+) and select the Render Window.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: Dune on June 27, 2021, 02:34:54 AM
That's why I mentioned F3 (though perhaps a bit unobtrusive); if you click that, the render window will pop up, whether it's been used or not, finished or not. In Windows. Only time it doesn't respond is in the internal postwork (GISD and such).
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 27, 2021, 02:49:07 AM
Here on a Mac I can't reproduce this behavior: After rendering, the "Render View" window remains as it is: In the foreground or background, depending on how you left it after the "Render" command. Nothing changes by itself, "freezes" or has to be corrected manually. The foreground/background behavior is as it should be. When you click on the main window or the Render View window, it moves to the foreground or background until you change it again, without any issues.
In this context, I don't need a "Stay open" button.
Your observed behavior could be a bug of certain Windows configurations.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: WAS on June 28, 2021, 02:13:00 PM
Quote from: Dune on June 27, 2021, 02:34:54 AMThat's why I mentioned F3 (though perhaps a bit unobtrusive); if you click that, the render window will pop up, whether it's been used or not, finished or not. In Windows. Only time it doesn't respond is in the internal postwork (GISD and such).

I suggest following the steps to reproduce before saying "only". F3 does return the window to the foreground, but if you're an average windows user, you're likely going to be clicking things. Put TG into windowed mode, start a render in foreground and let it finish. When it finishes it will become the background window as the 3D preview becomes active and now the GUI is priority. But when you click on the clearly visible render window under Terragen, it doesn't respond strangely.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 29, 2021, 01:03:02 AM
Quote from: WAS on June 28, 2021, 02:13:00 PMPut TG into windowed mode, start a render in foreground and let it finish. When it finishes it will become the background window as the 3D preview becomes active and now the GUI is priority. But when you click on the clearly visible render window under Terragen, it doesn't respond strangely
I repeat myself, although unfortunately it can not help clarify the problem:
@WAS:
Your description now shows me that it is obviously "only" a Windows problem. With macOS the "Render View" window of a finished render stays in the foreground for me (as it should?), while in the background main window the "3D Render Preview" starts working again unnecessarily. All the time Terragen is responsive and operable ("clickable") for me.
With macOS I also have the possibility to operate Terragen in "Tab-Mode". The main window and the render view window are simply two open tabs of a single window. Also in this mode I have no problems (switching by clicking).
Title: Re: REQUEST - Stay Open button in Render Window
Post by: Dune on June 29, 2021, 02:33:32 AM
This is different from my experience. If I let a render render and finish, it won't switch to the main TG, but stays on top. But I never have RTP on when doing a render and often my preview window is ready, or empty of objects/pops, box mode, or even closed, to save resources for the render, especially when doing a final render.
But perhaps when the machine is busy doing RTP stuff, render window won't respond, I can imagine that, priority and such. Probably also depends on the kind of CPU/GPU?
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 29, 2021, 04:57:37 AM
As said elsewhere: It may well be an RTP/render preview problem.
Since it seems to be impossible to disable the render preview permanently, you always have to do this manually. If the render preview is still active during the rendering process (you forgot to stop it), the render preview will be stopped at the beginning of the rendering process, but will be continued after the rendering process is finished and will most likely bring the corresponding window to the foreground again...
If the render preview is stopped manually before rendering, the actual render window remains in the foreground.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: KlausK on June 29, 2021, 08:38:43 AM
What WAS is describing is not normal TG behaviour on Windows.


Quote from: raymoh on June 29, 2021, 04:57:37 AMSince it seems to be impossible to disable the render preview permanently, you always have to do this manually.
You can - sort of - "disable the Preview Render" as follows:
go to every tab in the TG interface (Object, Terrain, Shaders...etc) and close the 3D Preview.
Once you do that, it does not come back (open up) on its own. If you need it, use F4 (Windows) on any tab or use the button at the top.
Of course, you have to close it manually again in this tab. F4 is not a on/off switch  for the preview window.
Neither is F3 for the Render View. Anyways, I always use Ctrl+R to get the the render started.

It was nice (I know I repeat myself) when you could open the 3D Preview as a floating window.
But as Matt said way back this is not possible anymore (or so) because of how the RTP works now.

On Windows any program window that has the focus comes to the foreground of the desktop.
You can program a "Always on top" behaviour into the the program (like the Task Manager has),
but that has to be implemented by the developer.
On Windows the "Render Window" cannot be docked into the TG Gui - sadly.

Windows has the "Taskbar" where you have a button for each open program window.
You simply need to click there and choose which window should come to the foreground.
Use the "Windows" key on your keyboard to see the Taskbar. Because TG hides the Taskbar when in Full Screen Mode. (Win 7 here).
That is also something the developer could prevent.

Quote from: raymoh on June 29, 2021, 04:57:37 AMIf the render preview is still active during the rendering process (you forgot to stop it), the render preview will be stopped at the beginning of the rendering process, but will be continued after the rendering process is finished and will most likely bring the corresponding window to the foreground again...
No. That is not standard Windows behaviour. After a render finishes without user intervention
there is no change of focus on the open program windows.
The 3D Preview does not start where it was interrupted by starting the "Render Window".
It refreshes the scene from scratch - which really is even more grrrrr&*$%^....

Changing settings while a image is rendered in the "Render View" is prone to lead to crashes. We all know this, I think.

On the other hand: why does not everybody use at least 2 monitors...."problem"  solved ;)

CHeers, Klaus
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on June 29, 2021, 09:30:57 AM
@KlausK:
With my votes I only tried to explain the "weird" behavior of Terragen by @Stormlord and @WAS... Since I myself, as I said, am on the road with macOS, my conclusions are probably rather guesses.

Quote from: KlausK on June 29, 2021, 08:38:43 AMOn Windows any program window that has the focus comes to the foreground of the desktop.

It is the same under macOS.

Quote from: KlausK on June 29, 2021, 08:38:43 AMWindows has the "Taskbar" where you have a button for each open program window.

You can also set the menubar under macOS to show every open program window.

Quote from: KlausK on June 29, 2021, 08:38:43 AMThe 3D Preview does not start where it was interrupted by starting the "Render Window".
It refreshes the scene from scratch - which really is even more grrrrr&*$%^....

That's exactly what I wanted to say... ;)

Quote from: KlausK on June 29, 2021, 08:38:43 AMChanging settings while a image is rendered in the "Render View" is prone to lead to crashes. We all know this, I think.

"Sigh!" Therefore: Two separate processes and this problem would be solved. Do a final render at the same time and continue working somewhere else in Terragen.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: WAS on June 29, 2021, 02:02:13 PM
Quote from: raymoh on June 29, 2021, 01:03:02 AMYour description now shows me that it is obviously "only" a Windows problem.

Yeah, that is what I am on and talking about. I never said it was a mac problem.

I think the call made to WDM is locking the window on screen or something requiring it to be called back (alt tab, f3, clicking task bar)
Title: Re: REQUEST - Stay Open button in Render Window
Post by: KlausK on June 29, 2021, 05:04:09 PM
@raymoh 


Quote from: raymoh on June 29, 2021, 09:30:57 AMWith my votes I only tried to explain the "weird" behavior of Terragen by @Stormlord and @WAS... Since I myself, as I said, am on the road with macOS, my conclusions are probably rather guesses.
I understood that and I don`t think I was questioning that. Just talking about that it is not a strange overall windows behaviour.



Quote from: raymoh on June 29, 2021, 09:30:57 AM"Sigh!" Therefore: Two separate processes and this problem would be solved. Do a final render at the same time and continue working somewhere else in Terragen.

Sure, that would be nice for MacOS. I did not question that, did I?
As Dune said, on Win you are able to start as many instances as your machine can bear.
But a separate process like you describe would also be good for TG on Win, of course.

CHeers, Klaus
Title: Re: REQUEST - Stay Open button in Render Window
Post by: WAS on June 29, 2021, 05:17:58 PM
Quote from: KlausK on June 29, 2021, 05:04:09 PMBut a separate process like you describe would also be good for TG on Win, of course.
Yeah, it would really be cool if the TG renderer was just a render node sort of deal. So when you click render, it sends a snapshot of the projects current state, and renders that [in a separate process/program]. Any changes won't affect the render, and 3D preview can continue to operate. I think systems (Workstations at least) can scale their cores to do example rendering while continuing to use TG, and it's previewer.

PS this sort of snapshot functionality, and going to a new process, I think would be easier to open up avenues of improvements. Like a built-in network render manager, to communicate with other render nodes. More abilities like history of renders it's completed as part of the GUI, etc.
Title: Re: REQUEST - Stay Open button in Render Window
Post by: KlausK on June 30, 2021, 03:23:38 AM
@raymoh Going back to  opening to instances on Mac here? Did you try anything already? Any success? What might work is to open a render via command line with the tgdcli. At least that is a way to separate the render process from the open session under TG Windows.
There are some threads about that in the forum to find.
And the wiki documentation: https://planetside.co.uk/wiki/index.php?title=Command_Line_Reference

CHeers, Klaus
Title: Re: REQUEST - Stay Open button in Render Window
Post by: raymoh on July 05, 2021, 05:10:41 AM
@KlausK: Working with the command line is not at the top of my list. I am more of a "click-man". I have gotten used to working with Terragen. If it takes longer, I take a break, drink coffee or go for a walk... I rarely have crashes anymore. It has become a habit to stop the preview before rendering
Otherwise, I can only agree with the post #22 of @WAS.