LUX

From Valve Developer Community
< Zh
Revision as of 04:02, 20 February 2023 by Yakumo koishi (talk | contribs)
Jump to navigation Jump to search
English (en)中文 (zh)Translate (Translate)
Zh/LUX
Development.pngAlpha 开发阶段中
Wiki
类型模组
开发商ShiroDkxtro2
引擎起源 起源
平台(存在于 PC 之中)
基于起源2013 起源2013
 
GitHub
Join Discord server

LUX LUX是一个专门为起源2013 单人分支 起源2013 单人分支起源2013 多人分支 起源2013 多人分支制作和开发的模组,其目的皆在为完全重写所有原版和Mapbase Mapbase的着色器

目标

  • 大修\清理materialsystem\stdshaders\目录
Template:Warning:zh-cn
告示: 实现LUX LUX的着色器需要将stdshaders/替换为LUX LUX自己的,这“有效”的扬了所有原版着色器的修改版,LUX应该能够实现所有起源2013Mapbase着色器原有的功能
Template:Note:zh-cn
  • 大幅减少所有着色器的编译时间
Template:Why:zh-cn
告示: 即便使用高端CPU也至少需要半天或更久的时间进行编译。以LUX LUX为例,在4核@4.1Hz环境下编译整个LUX_Lightmappedgeneric仅需要大约30秒
  • 着色器仅使用SM 3.0
Template:Why:zh-cn
Template:Note:zh-cn
Template:Note:zh-cn
告示: Linux和MacOS暂无官方支持。以上系统用户需要使用togl进行补丁才能使用SM3.0,或使用DXVK
  • 完全重写.h, .cpp, .fxc文件
  • 更多有关着色器、自身参数、如何工作以及任何可能的注意事项的文档
告示: 你可能已经注意到了如$lightwarptexture$detailUnlitTwoTexture$envmapmask得到了由ShiroDkxtro2贡献的重大更新
他为军团要塞2异形丛生起源2013反恐精英:全球攻势添加了新的注意事项和bug记录。这些文档是LUX LUX开发的直接结果,尽管开发的重点集中在起源2013异形丛生上,因为他们是开源项目
Template:Note:zh-cn
  • 实现起源2013没有的内容
Template:Seealso:zh-cn
  • 修复大多数参数的Bug和警告
Template:Seealso:zh-cn
  • 禁用特定功能的简单方法
Template:Note:zh-cn
  • 对Mapbase的兼容性
告示: 要替换其他mod(如Source 2013社区版,以Mapbase为本体的mod)修改的原版着色器,应该和直接替换stdshaders\目录一样简单
Template:Note:zh-cn

计划实现的功能

这是正在实施的新功能列表,或者将从较新的引擎分支移植/复刻的功能,例如异形丛生求生之路2反恐精英:全球攻势 Template:Note:zh-cn

File:Important template.gif 重要: LUX LUX不使用任何的泄露代码。像$phongalbedoboost(存在于 csgo 之中)这样的功能不是什么难以实现的东西,它们可以在不使用泄露代码的情况下安全的复现
Template:Warning:zh-cn

出于Mapbase Mapbase而需实现的功能

Template:Note:zh-cn
File:Important template.gif 重要: LUXMapbase参数是一样的,所以Mapbase的地图编译器也可以使用
待完善: 这真的是移植自异形丛生Mapbase功能吗

New Features

  • In 起源2013 多人分支 Models utilizing Model Lightmapping can use $bumpmap. Additionally all Model shaders will be able to utilize this feature. Except they have $phong.
File:Important template.gif 重要: The Lightmap does not do bumped-lighting using the bumpmap. Only named-lights/projected textures will be able to do so.
Template:Note:zh-cn
  • In 起源2013 多人分支 Models can utilize Lightmap UV's.
Template:Warning:zh-cn
待完善: Investigate 起源2007 code, supposedly the Studiomdl code is there. Maybe it can be packed via Blendweights or alternatively the precision loss might be decreased.

Features ported/recreated/revived

Template:Note:zh-cn
Template:Note:zh-cn
Template:Seealso:zh-cn
[File:Important template.gif 重要]
* On brushes this will use the Lightmap
* On models with $bumpmap, this will use bumped lighting.
* On models without $bumpmap, this will use Vertex Lighting.
* In 起源2013 多人分支 Models utilizing Model Lightmapping, will use the Lightmap. Regardless of whether or not $bumpmap is used.

Features that are being discarded

  • $envmapsphere and related - These features have been removed since 异形丛生 and are obsolete.
Template:Note:zh-cn

Features that won't be ported/recreated/revived

  • $basealphaenvmapmaskminmaxexp from 异形丛生 - This parameter is not yet documented on the VDC, it is also unclear what exactly it does...
  • $EnvMapLightScaleMinMax from 反恐精英:全球攻势

Not functional - FOR NOW



Stock Shaders VS LUX

待完善: Move This to their own pages or something like that.

LightMappedGeneric

Stock Shader's

Icon-Bug.png错误:$detailblendmode起源2013军团要塞2 2-9 Don't work.  [todo tested in ?]
Icon-Bug.png错误:$detailblendmode异形丛生 6 Doesn't work.  [todo tested in ?]
Icon-Bug.png错误:$detailblendmode反恐精英:全球攻势 1-6, 8 Don't work. 9 Does not work with $bumpmap, $envmap or $selfillum  [todo tested in ?]


Icon-Bug.png错误:$bumpmap + $envmapmask Doesn't work, except in 反恐精英:全球攻势 反恐精英:全球攻势  [todo tested in ?]
Icon-Bug.png错误:$lightwarptexture + $detail军团要塞2异形丛生 Doesn't work  [todo tested in ?]
Icon-Bug.png错误:$basealphaenvmapmask + bumpmap Doesn't work  [todo tested in ?]


Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn

告示: $basealphaenvmapmask requires inverted masks

LUX_LightMappedGeneric

告示: Caveat - Has higher priority than $selfillum/$selfillummask.
告示: Caveat - $selfillumtexture has higher priority than both.
File:Important template.gif 重要: $basealphaenvmapmask does no longer require a flipped mask.
PlacementTip.png解决方案:Materials that previously used have to be adjusted. Use $envmapmask or $normalmapalphaenvmapmask instead!

VertexLitGeneric

Stock Shader's

Always

$envmaplightscale(存在于 反恐精英:全球攻势 之中).

Without $Bumpmap

Icon-Bug.png错误:$detailblendmode起源2013军团要塞2异形丛生反恐精英:全球攻势 10-11 Don't work.  [todo tested in ?]
Icon-Bug.png错误:$selfillumfresnel missing.  [todo tested in ?]
Icon-Bug.png错误:$lightwarptexture missing.  [todo tested in ?]
Template:Note:zh-cn

With $Bumpmap

Icon-Bug.png错误:$detailblendmode起源2013军团要塞2异形丛生反恐精英:全球攻势 5-11 Don't work.  [todo tested in ?]
Icon-Bug.png错误:$detailblendmode反恐精英:全球攻势 5-6 & 8-11 Don't work.  [todo tested in ?]

Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn

Icon-Bug.png错误:$selfillumfresnel disables $normalmapalphaenvmapmask.
待完善: Also on other branches than 异形丛生?
  [todo tested in ?]

With $Phong

Icon-Bug.png错误:$detailblendmode起源2013军团要塞2异形丛生反恐精英:全球攻势 8-11 Don't work.  [todo tested in ?]
Icon-Bug.png错误:$invertphongmask异形丛生起源2013 In the shadercode, only flips the mask used for $envmap.
证实:Also on newer branches?
  [todo tested in ?]
Icon-Bug.png错误:$phongalbedotint cannot be used without $phongexponenttexture.  [todo tested in ?]
Icon-Bug.png错误:$phongwarptexture求生之路2 does not work.  [todo tested in ?]
Icon-Bug.png错误:$phongalbedoboost(存在于 反恐精英:全球攻势 之中) + $detail does not work.  [todo tested in ?]
Icon-Bug.png错误:$phongtint disables $phongalbedotint.  [todo tested in ?]
Icon-Bug.png错误:$envmap always masked by something.  [todo tested in ?]
Icon-Bug.png错误:Only in 求生之路+ $envmap masked by $basetexture luminance when $normalmapalphaenvmapmask and $basemapluminancephongmask is used.  [todo tested in ?]
Icon-Bug.png错误:$envmap masked by $basetexture alpha when $normalmapalphaenvmapmask and $basemapalphaphongmask is used.  [todo tested in ?]
Icon-Bug.png错误:$basemapalphaphongmask makes $phong ignore the $bumpmap.  [todo tested in ?]
Icon-Bug.png错误:$selfillumfresnel + $normalmapalphaenvmapmask will cause the $envmap to be multiplied by 0.0f regardless of whether $invertphongmask is used.  [todo tested in ?]
Icon-Bug.png错误:$selfillumfresnel will cause $envmap to be masked using the $basetexture alpha channel  [todo tested in ?]

Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn Template:Note:zh-cn

LUX_VertexLitGeneric

Without $Bumpmap

待完善: Make a parameter that allows its usage. Right now default behavior is replicated and a default bumpmap is bound.

With $Bumpmap

With $Phong

告示: Will use entirety of $basetexture, without being masked.
告示: When no $phongexponenttexture is specified, Mask will be 1.0f!
  • $envmap Can now be not-masked by using a new parameter ($phongenvmapnomask)
  • File:Important template.gif 重要: By default the original masking for the $envmap will be replicated as to not have disparity.

However it can now be overriden using two new parameters. $phongforcebasealphaenvmapmask and $phongforcenormalmapalphaenvmapmask

告示: This will make materials that previously used this intentionally, look different.





待完善: Add LUX_WorldVertexTransition and other LUX_ Shaders to this list of comparison and changes.
Template:Note:zh-cn