Changeset View
Changeset View
Standalone View
Standalone View
source/blender/draw/intern/draw_manager.c
| Show First 20 Lines • Show All 369 Lines • ▼ Show 20 Lines | |||||
| /** \} */ | /** \} */ | ||||
| /* -------------------------------------------------------------------- */ | /* -------------------------------------------------------------------- */ | ||||
| /** \name Multisample Resolve | /** \name Multisample Resolve | ||||
| * \{ */ | * \{ */ | ||||
| /* Use manual multisample resolve pass. | /** | ||||
| * Use manual multisample resolve pass. | |||||
| * Much quicker than blitting back and forth. | * Much quicker than blitting back and forth. | ||||
| * Assume destination fb is bound*/ | * Assume destination fb is bound. | ||||
| */ | |||||
| void DRW_multisamples_resolve(GPUTexture *src_depth, GPUTexture *src_color, bool use_depth) | void DRW_multisamples_resolve(GPUTexture *src_depth, GPUTexture *src_color, bool use_depth) | ||||
| { | { | ||||
| DRWState state = DRW_STATE_WRITE_COLOR | DRW_STATE_BLEND_PREMUL; | DRWState state = DRW_STATE_WRITE_COLOR | DRW_STATE_BLEND_PREMUL; | ||||
| if (use_depth) { | if (use_depth) { | ||||
| state |= DRW_STATE_WRITE_DEPTH | DRW_STATE_DEPTH_LESS_EQUAL; | state |= DRW_STATE_WRITE_DEPTH | DRW_STATE_DEPTH_LESS_EQUAL; | ||||
| } | } | ||||
| drw_state_set(state); | drw_state_set(state); | ||||
| ▲ Show 20 Lines • Show All 2,497 Lines • Show Last 20 Lines | |||||