x

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"

Spawn / Destroy actor with lighmaps and apply material from menu

Hello every one

I am currently working on a virtual Exhibition room that mainly focuses on washbasins

alt text

In this application I have created a menu were the user can change the material of a washbasin model, the problem is that I also want the user to be able to change model and preview them with different materials from the menu list.

alt text

The Ideal solution would be if I could build lightmap for each separate model and then simply destroy and spawn them but as far as I know this is option dose not exist. I tried creating different levels so I can toggle visibility but I cant find a way to apply materials to a model I just spawned from my menu. Hopefully all this makes sense.

Any help would be much appreciated.

Product Version: UE 4.11
Tags:
unrealq02.jpg (792.8 kB)
unrealq01.jpg (878.7 kB)
more ▼

asked May 10 '16 at 12:13 PM in Using UE4

avatar image

Kathorus
1 1 2

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

2 answers: sort voted first

Hi!

Lightmaps, Shadowmaps and Lightcaches not stored in objects.

UE4 merges all of lightmaps and creates atlases. These atlases are stored inside the file of level.

Probably you need to adjust lighting parameters and create Lighting Cache with properly density.

https://docs.unrealengine.com/latest/INT/Engine/Rendering/LightingAndShadows/IndirectLightingCache/

This is a simple example. We have two static meshes and one movable object. All objects have the same material. As you can see, they are very similar. Even if we rotate this movable object.

If you enable in viewport Show->Visualize->Volume Lighting Samples, then you will see samples of the light cache after build lighting.

alt text

alt text

If you need more detailed lighting for some objects, you can use Lightmass Character Indirect Detail Volume.

alt text

I mean, that there is no need to created the lightmap for each object. UE4 lighting system is very powerful and flexible.

lighting01.png (457.1 kB)
lighting02.png (461.4 kB)
lighting03.png (728.7 kB)
more ▼

answered May 10 '16 at 03:25 PM

avatar image

svv3dUDN
8.4k 254 42 399

avatar image Kathorus May 15 '16 at 08:04 PM

Thank you so much for your reply and I want to apologize for my delay.

I spend the couple of days trying everything you showed me and to be honest the results were quite good but still in my perspective I was not satisfied, I also use a couple of IES files and having them cast Dynamic shadows made the hole scene run slower.

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

Finally I did find a solution to my problem, I just created several levels each one containing a washbasin model and I also created a Static Mesh Actor Array, in each level blueprint I used an Insert array command and populate the array with the models. Finally in the UI I linked level visibility to the model buttons and it works just fine!! :D

It was a bit troublesome but at the end I managed to do it, if any one needs more details just let me know I am more than happy το post more info. :D

more ▼

answered May 15 '16 at 08:14 PM

avatar image

Kathorus
1 1 2

(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