Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Texture render target not updating when game paused?

I'm using a SceneCaptureComponent2D inside an actor blueprint to render a scene to a render target (a texture). But I am seeing that when the game is paused (GetWorld->IsPaused()==true), it doesn't update the render target.

How do I fix this, or work around it?

I've set the actor blueprint to update when paused (PrimaryActorTick.bTickEvenWhenPaused = true; in its constructor), and I've also set "AutoActivate" on the SceneCaptureComponent2D to true.

Product Version: Not Selected
more ▼

asked Jan 05 '15 at 10:16 PM in Rendering

avatar image

274 34 49 66

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Hey -

The SceneCapture Component 2D or Cube does not directly run on tick, but you can make it run on tick and have it maintain updating through a Pause with this setup:

The one think you will want to do in the Components is make sure that your camera is set to NOT update every frame which will force the camera to update only when moved.

alt text

Thank You

Eric Ketchum

camerabp.jpg (236.0 kB)
more ▼

answered Jan 06 '15 at 08:49 PM

avatar image

Lovecraft_K ♦♦ STAFF
36.7k 702 260 736

avatar image MSE_Taliesin Jan 06 '15 at 09:08 PM

Thanks, Eric -- that fixed it! :-)

A bit awkward having to put it into an infinite MoveComponentTo loop, but hey ... if it works, I'll take it!

avatar image Digital_Kitchen Jan 08 '16 at 02:07 AM

@EricKetchum, can you give some more details on how this blueprint is set up?

I tried to turn my camera that is looking at stuff to render, and isn't working when I tried to do your setup.

I feel like there is half the blueprint missing for what I need? My render target updates fine and looks good as long as the world is not paused, but stops updating once I do pause the game.

avatar image Lovecraft_K ♦♦ STAFF Jan 08 '16 at 03:09 PM

Hello -

So the Blueprint above is a Camera Actor itself. I made a BP Actor class and added a Scene Capture 2D as the sole component. Once that is done, the important part of this is to set the Scene Capture 2D to not update on Tick via the Component Details and instead you will be using the logic listed above in Event Tick to run the same update functionality and finally and most importantly you are setting the actor to calculate Tick even when the Game is Paused on Event Begin Play.

Hopefully that clarifies what you are asking about -

Eric Ketchum

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question