Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removes unnecessary GetComponent #38

Merged
merged 3 commits into from
Oct 11, 2019

Conversation

hobnob
Copy link
Contributor

@hobnob hobnob commented Jun 7, 2018

There are a few areas in the OutlineEffect where GetComponent is used on PreRender, but doesn't need to be (which may affect performance)

This will remove all but 1 call (made at the Start of the scene) in favour of caching the information required on the Outline object

hobnob added 3 commits June 7, 2018 13:20
Reduces the need for GetComponent later
Makes use of the new Outline properties to reduce the number of GetComponent calls to 1 (in the Start method)
@ghost
Copy link

ghost commented Jun 7, 2018

DeepCode found the following issues:

Critical: 0
Warning: 0
Info: 0

Priority breakdown:

Security Defect API Anomaly Rename Lint Info
Critical 0 0 0 0 0 0 0
Warning 0 0 0 0 0 0 0
Info 0 0 0 0 0 0 0

Most affected files:

File Critical Warning Info

See detailed analysis.

@f0ff886f
Copy link

f0ff886f commented Feb 3, 2019

It should be outline.MeshFilter, as well on L238 it shouldn't be outline.GetComponent<Renderer>() but outline.SkinnedMeshRenderer.

@JimmyCushnie JimmyCushnie mentioned this pull request Oct 10, 2019
@cakeslice cakeslice merged commit 55024e4 into cakeslice:master Oct 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants