Age | Commit message (Collapse) | Author |
|
This makes it possible to paint pixel art using the workbench.
Cubic interpolation is not supported but could be added if needed.
|
|
|
|
We exploit the fact that we are using the metallic workflow for material
and pass the metallic parameter instead of the specular color.
Pack the front facing bit in the color buffer only for matcap display.
Change buffer formats to use less bytes as possible.
Also don't request buffers that we won't use.
Saved 40MB on 2K screen on StudioLight + Shadows + Specular Lighting.
Includes several cleanups.
|
|
This is in order to have more flexible ligthing presets in the future.
The diffuse lighting from hdris was nice but lacked the corresponding
specular information. This is an attempt to make it possible to customize
the lighting and have a cheap/easy/nice-looking pseudo-PBR workflow.
* Add cheap PBR to Workbench with fresnel and better roughness support.
This improves the look of the metallic surfaces and is easier to control.
* Add ambient light to studio lights settings: just a constant color added
to the shading.
* Add Smooth option to studio lights settings: This option fakes the
effect of making the light bigger making the lighting smoother for this
light. Smoother lights gets reflected like a background hdri.
* Change default light settings to include the smooth params.
* Remove specular highlights from flat shading. (could be added back but
how do we make it good looking?)
* If specular lighting is disabled, use base color without using metallic.
* Include a lot of code simplification/cleanup/confusion fix.
|
|
Usage of matcap image uniform had different ifdef than definition
of that uniform. Assuming the usage was correct, and the definition
needed an update.
Prevents shader from compilation failure and from aborts in debug
builds.
|
|
Worknemch now supports transparent textures.
As the main engine is a deferred shading only a cutoff is supported
(draw or don't draw this pixel)
|
|
Most of the times the materials differ due to the object_id. This was an
overhead and resulted in instabilities on Intel graphical cards. This
commit will revert the Material Data UBO and replace it with normal
uniform.
|
|
|
|
the use of the texture drawtype is limited. so who should we have it
this prominent on the screen. By adding it as a shading.color_type
option we should save some screenspace.
|
|
By using equation 7 from the paper, we make the surfaces nearest to the
viewpoint appear more "opaque". This gives better sense of ordering than
the previous weighting function that was really not doing anything.
|
|
There was a method explained in the Weighted Blended Order-Independent
Transparency paper to support hardware that does not support per render
target blending function.
So now only 2 geometry passes are required instead of 3 (one being the
outline/depth fill pass).
This also fix how the blending is done. There was some premult confusion
in the implementation.
|
|
|
|
|
|
|
|
This fixes the problem that matcaps have when using a very larg FOV in
perspective view.
This was because it was stupidly using the normal direction which can not
aligned with the view vector under perspective.
So to workaround this problem we don't use the normal as is, but compute
how much it's facing the camera.
This changes how matcaps looks in perspective because they now always use
the full range of the matcap (which is expected).
|
|
This fixes specular in perspective view.
|
|
- users can use their own matcaps
.config/blender/2.80/datafiles/studiolights/matcap/ folder
- upto 100 matcaps can be loaded
- color of the matcap is influenced by the color of the material/single
color etc. To show the plain matcap use single color at 1.0
- chosing a matcap is at lighting level (flat/studio/matcap)
- matcap only possible in solid mode
- also works for X-Ray mode
As the old matcaps are still in used by the clay engine I didn't remove
it yet.
|
|
Now hairs are shaded properly in workbench and support texturing.
I also added a 10% random normal direction per hair to have a bit more
variation in the shading. This is hardcoded for now.
|
|
- will not render when set to 0.0 for speed reasons. so when user sets
transparency to hide everything the bigger passes will be skipped.
|
|
- Uses the roughness setting of the basic eevee material
- renamed gloss_mir to roughness
- set default of roughness to 0.25
- renamed ray_mirror to metallic
- cleaned up material rna (BI mirror struct)
- use BLINN phong model
- normalize incoming/outgoing specular light
- when using camera oriented studiolight, the SolidLight will be used
for specular highlights
- EXPERIMENT: when in world oriented studiolight only the shadow direction will be used.
- change the settings of the internal light to make scenes more
readable
|
|
|
|
Added specular highlights for:
- Solid studio shading
- Texture studio shading
|
|
|
|
|
|
Unmultiplied the final color during compositing. Same as the revealage
buffer would do
Also use the DRW_STATE_ADDITION_FULL as it is aware of premultiplied
colors
|
|
added a fresnel effect
TODO: solve memory leak
|
|
Option to see through all meshes (transparency)
Works for OB_SOLID and OB_TEXTURED. Does not work for
V3D_SHADING_SHADOW.
TODO: Fresnel effect
|