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
3af0400a
Unverified
Commit
3af0400a
authored
Jan 16, 2020
by
Rémi Verschelde
Committed by
GitHub
Jan 16, 2020
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #35176 from clayjohn/csg-crash
Fix light related crashes
parents
bd1a8aac
f1d0c391
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
rasterizer_scene_gles2.cpp
drivers/gles2/rasterizer_scene_gles2.cpp
+1
-1
rasterizer_scene_gles3.cpp
drivers/gles3/rasterizer_scene_gles3.cpp
+2
-2
No files found.
drivers/gles2/rasterizer_scene_gles2.cpp
View file @
3af0400a
...
...
@@ -1169,7 +1169,7 @@ void RasterizerSceneGLES2::_add_geometry_with_material(RasterizerStorageGLES2::G
LightInstance
*
li
=
light_instance_owner
.
getornull
(
e
->
instance
->
light_instances
[
i
]);
if
(
li
->
light_index
>=
render_light_instance_count
||
render_light_instances
[
li
->
light_index
]
!=
li
)
{
if
(
!
li
||
li
->
light_index
>=
render_light_instance_count
||
render_light_instances
[
li
->
light_index
]
!=
li
)
{
continue
;
// too many or light_index did not correspond to the light instances to be rendered
}
...
...
drivers/gles3/rasterizer_scene_gles3.cpp
View file @
3af0400a
...
...
@@ -1887,8 +1887,8 @@ void RasterizerSceneGLES3::_setup_light(RenderList::Element *e, const Transform
const
RID
*
lights
=
e
->
instance
->
light_instances
.
ptr
();
for
(
int
i
=
0
;
i
<
lc
;
i
++
)
{
LightInstance
*
li
=
light_instance_owner
.
get
ptr
(
lights
[
i
]);
if
(
li
->
last_pass
!=
render_pass
)
//not visible
LightInstance
*
li
=
light_instance_owner
.
get
ornull
(
lights
[
i
]);
if
(
!
li
||
li
->
last_pass
!=
render_pass
)
//not visible
continue
;
if
(
li
&&
li
->
light_ptr
->
type
==
VS
::
LIGHT_OMNI
)
{
...
...
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