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

We should replace GeometryPool entirely #497

Open
andybak opened this issue Aug 11, 2023 · 0 comments
Open

We should replace GeometryPool entirely #497

andybak opened this issue Aug 11, 2023 · 0 comments
Labels
feature request Request to alter functionality

Comments

@andybak
Copy link
Contributor

andybak commented Aug 11, 2023

From the comments in GeometryPool.cs :

/// GeometryPool stores mesh data in convenient and C#-accessible data structures.
///
/// Quite often, GeometryPool data is associated with a particular UnityEngine.Mesh to which
/// data changes are pushed with CopyToMesh(mesh). This trades off increased memory usage for
/// efficient updates, and is analagous to a CPU cache. 

Unity has a much more efficient mesh API now so we could get rid of all this baggage.

First step might be to delete these fields:

    public List<Vector3> m_Vertices;
    public List<int> m_Tris;
    public List<Vector3> m_Normals;
    public TexcoordData m_Texcoord0;
    public TexcoordData m_Texcoord1;
    public TexcoordData m_Texcoord2;

and then see what breaks...

@mikeskydev mikeskydev added the feature request Request to alter functionality label Oct 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Request to alter functionality
Projects
None yet
Development

No branches or pull requests

2 participants