Welcome Guest ( Log In | Register )


 
Reply to this topicStart new topic
> lightmaps
tschumann
post Aug 14 2009, 08:40 PM
Post #1


Advanced Member
***

Group: Moderator
Posts: 741
Joined: 20-March 09
From: Australia
Member No.: 283



How exactly do lightmaps work? Do you need to add a second UVW layer to the model, then specify the material used for the the second UVW layer in the prop_static's entity data?
Or can you specify a lightmap for a model without a second UVW layer?
Go to the top of the page
 
+Quote Post
Carlos Bordeu
post Aug 14 2009, 09:46 PM
Post #2


Super Member
****

Group: Developers
Posts: 2,178
Joined: 11-April 08
From: Santiago, Chile
Member No.: 4



QUOTE (tschumann @ Aug 14 2009, 08:40 PM) *
How exactly do lightmaps work? Do you need to add a second UVW layer to the model, then specify the material used for the the second UVW layer in the prop_static's entity data?


This... exactly. Details documented in the wiki.

QUOTE (tschumann @ Aug 14 2009, 08:40 PM) *
Or can you specify a lightmap for a model without a second UVW layer?


If you don't have a second UV layer I'm not sure if the lightmap will appear on as if it were on the first layer (or if it will just appear all messed up).

Anyways... a lightmap on the same UV layer as the diffuse makes no sense unless the prop uses a unique texture space for all its triangles. If it the regular diffuse (texture) layer has a tiling texture or mirror mapping, your lightmap would tile or mirror and completely look innapropriate.

Think of a large polygon with a tiling grass texture... For a lightmap for this 'prop' you would need a second UV layer where the polygon uses the texture area and does not tile.

Is this clear, or is my explanation too confusing?
Go to the top of the page
 
+Quote Post
tschumann
post Aug 14 2009, 10:21 PM
Post #3


Advanced Member
***

Group: Moderator
Posts: 741
Joined: 20-March 09
From: Australia
Member No.: 283



Okay, I understand.
Do all the lightmap textures have sh in their names?
Go to the top of the page
 
+Quote Post
Carlos Bordeu
post Aug 15 2009, 02:29 AM
Post #4


Super Member
****

Group: Developers
Posts: 2,178
Joined: 11-April 08
From: Santiago, Chile
Member No.: 4



QUOTE (tschumann @ Aug 14 2009, 10:21 PM) *
Okay, I understand.
Do all the lightmap textures have sh in their names?


We did that so we could organize them better, but it's not mandatory. You can use any name you want.
Go to the top of the page
 
+Quote Post

Fast ReplyReply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members: