Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
godot
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
community
godot
Commits
a3450884
Commit
a3450884
authored
Jan 15, 2020
by
clayjohn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add background mode keep to GLES2
parent
40f0649e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
rasterizer_scene_gles2.cpp
drivers/gles2/rasterizer_scene_gles2.cpp
+2
-2
No files found.
drivers/gles2/rasterizer_scene_gles2.cpp
View file @
a3450884
...
...
@@ -3325,6 +3325,7 @@ void RasterizerSceneGLES2::render_scene(const Transform &p_cam_transform, const
glDepthMask
(
GL_TRUE
);
glClearDepth
(
1.0
f
);
glEnable
(
GL_DEPTH_TEST
);
glClear
(
GL_DEPTH_BUFFER_BIT
);
// clear color
...
...
@@ -3351,13 +3352,12 @@ void RasterizerSceneGLES2::render_scene(const Transform &p_cam_transform, const
if
(
!
env
||
env
->
bg_mode
!=
VS
::
ENV_BG_KEEP
)
{
glClearColor
(
clear_color
.
r
,
clear_color
.
g
,
clear_color
.
b
,
clear_color
.
a
);
glClear
(
GL_COLOR_BUFFER_BIT
);
}
state
.
default_ambient
=
Color
(
clear_color
.
r
,
clear_color
.
g
,
clear_color
.
b
,
1.0
);
state
.
default_bg
=
Color
(
clear_color
.
r
,
clear_color
.
g
,
clear_color
.
b
,
1.0
);
glClear
(
GL_COLOR_BUFFER_BIT
|
GL_DEPTH_BUFFER_BIT
);
if
(
storage
->
frame
.
current_rt
&&
storage
->
frame
.
current_rt
->
flags
[
RasterizerStorage
::
RENDER_TARGET_DIRECT_TO_SCREEN
])
{
glDisable
(
GL_SCISSOR_TEST
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment