Announcement

Collapse
No announcement yet.

[Tutorial] Live 3D Content in your HUD or UI

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • replied
    Is there any way to capture image from a separate level instance?

    Leave a comment:


  • replied
    Originally posted by unit23 View Post
    I managed to set this up with a Scene Capture Component 2D, however it has no transparent background.
    You need to use a actor and spawn it out side of the sky done then OnRep your changes to the preview actor to update the mesh.

    Leave a comment:


  • replied
    Originally posted by Twelvecaliber View Post
    An example was suggested that the larger render of the character could be used in an inventory screen, i have a wish to do this, however my character equip different types of clothing by using skeletal meshes and the masterpose component. Could the proxy character be set up so that it also displays the additional skeletal meshes that are currently being posed on the main player character?
    I managed to set this up with a Scene Capture Component 2D, however it has no transparent background.

    Click image for larger version

Name:	Cap1.jpg
Views:	1
Size:	446.7 KB
ID:	1124415

    STEP 1
    Add a Scene Capture Component 2D to your player character blueprint, then rotate it by 180 degrees, and move it a little outwards.
    Then add a CanvasRenderTarget2D texture under the Scene Capture Component 2D settings
    Disable auto activate

    Click image for larger version

Name:	Cap3.jpg
Views:	1
Size:	220.0 KB
ID:	1124417

    STEP 2
    Navigate to the newly created CanvasRenderTarget2D texture > rightclick and create a material
    Inside the material i set it up as can be seen in the image below
    Click image for larger version

Name:	Cap5.jpg
Views:	1
Size:	231.5 KB
ID:	1124419

    STEP 3
    Add an Image to your UMG (ie. Inventory UI)
    Add your RenderTarget material to the Brush Image Slot, of the newly created Image

    Click image for larger version

Name:	Cap2.jpg
Views:	1
Size:	303.9 KB
ID:	1124416

    STEP 4
    Add the following activate node to your Inventory show button, or where you load the Inventory display, same for exit Inventory view
    Click image for larger version

Name:	Cap4.jpg
Views:	1
Size:	305.5 KB
ID:	1124418

    The CanvasRenderTarget2D texture resolution is similar to the one i use in my UI, can be tweaked, HDR option is disabled. Maybe this helps someone, i wasn't able to find a documentation for this, using 4.14

    Leave a comment:


  • replied
    First off thanks for taking the time and doing this, very much appreciated! Out of curiosity, would it be feasible to set up the whole RenderToTexture system in a sublevel.

    Leave a comment:


  • replied
    Outstanding. I am just getting into HUD work and I appreciate the time you put in making this video and carefully explaining the details.

    Leave a comment:


  • replied
    An example was suggested that the larger render of the character could be used in an inventory screen, i have a wish to do this, however my character equip different types of clothing by using skeletal meshes and the masterpose component. Could the proxy character be set up so that it also displays the additional skeletal meshes that are currently being posed on the main player character?

    Leave a comment:


  • replied
    This is nice and clean. I didn't know if Scene Capture 2D can generate alpha until now. My solution for 3d render inside UMG is using mesh surrounding with planes with color-fix material. When render target is ready, filter the color and changed it to alpha. I probably should change my technique using this one.

    For multiplayer setup, I think Scene Capture 2D only works with one render target. So, running 2 or more games inside one computer and one executable/project folder, will share same render target. It'll result render target only render texture from the last game that access it. Solution : Try to use 2 different computers for clients.

    Leave a comment:


  • replied
    this doesn't work in multiplayer setup. anyone know a solution?

    Leave a comment:


  • replied
    Thank you so much for this information! This helped me get an object to be interactively spinnable on my HUD.

    I am having a couple issues, though.

    1. Any part of the 3D object that is 100% white on the HUD shows up as transparent. I cannot seem to figure out why this is happening. I have tried 1-x on the opacity and I tried the "If statement Jeff provided, neither one worked perfectly. Any idea how to get the background to disappear, but have the object show up completely opaque?

    2. Whenever I have the object rotating the refresh updates appear very wobbly. It looks like the model distorts slightly as it spins around. It seems like it would have something to do with the refresh rate or possibly anti-aliasing. Does anyone know of a fix for this?

    If these are not possible right now, does anyone know of a good way to make a model viewer in Unreal? That is my ultimate goal here, to be able to click on an object, have it appear in the HUD widget if possible, and have it interactively rotatable. Unfortunately it also needs to look good. I'm not sure it can be done cleanly the way I have it setup right now. Any help is greatly appreciated. Thanks!

    Unreal Engine 4.7.6
    Last edited by musine; 05-11-2016, 12:47 PM.

    Leave a comment:


  • replied
    Seems that whole project doesn't work at least at 4.9.2. There no UI pictures or any animation, only "player 1". Is it real to repeat this giude, or now it's just waste of time?

    Upd: Got it. Then he removes background in the material with "1-x" node from alpha channel it works only in video. In fact we remove all picture. WHY?(
    Last edited by Two-faced; 02-05-2016, 08:02 AM.

    Leave a comment:


  • replied
    Do we have any news regarding the SceneCapture2D Transparency issue or any workaround?
    Last edited by Sutorcen; 01-08-2016, 05:38 AM.

    Leave a comment:


  • replied
    Really nice work mate! Good voice to listen to for tutorials as well. I'll be picking apart this project for an inventory item preview, thanks!

    Leave a comment:


  • replied
    This approach does not seem to work on UE 4.10.1. For some reason I get all white for the alpha channel of the render target. I also tried the project you've supplied and when I converted it to 4.10, it had the same problem. The current material returns opacity 1-x, and as x is always 1, the face/full body images are not visible at all. Tried removing the 1-x and feeding the x instead: the face with its background appears.

    Leave a comment:


  • replied
    Thanks so much for the tutorial, it's fantastic.
    I am having a problem though. When I go outside the sky sphere to drop the camera and the actor, they both appear black, like they are unlighted. Also, when I go into the Render Target, the actor does not have the transparency deal covering it. Thus, I am unable to get rid of the background when it shows up on the viewport. I'm using 4.8 if that makes a difference. I can't remember if when I started the project, which template I started in. I don't know if that matters

    Leave a comment:


  • replied
    Hey Jeff, I really like your solution to this problem. However I found a problem with it.. You're consistently running at around 40%-60% performance.
    You don't normally see this in PIE because it has it's own hard coded settings and FPS smoothing that stays relatively low, but if you unbound and unsmooth FPS you can easily see the issue.

    I modified your project to show the issue. I got rid of the face, and only kept the Body on tab press. I also have the FPS unbound in Standalone.


    Observe the following results
    Without Capture
    http://imgur.com/0A2VnhS

    With Capture
    http://imgur.com/JT2E48h

    Full download:
    https://www.dropbox.com/s/dl1j4pxzi7...Issue.zip?dl=0

    Leave a comment:

Working...
X