Page 1 of 1

Noesis stats in Unity

Posted: 04 Jul 2014, 02:27
by wckdspn
Was looking for a way to gain some introspection into the Noesis runtime from within Unity. Things such as memory usage (bonus points for a breakdown based on object types), loaded resources, etc. Exposed function calls are fine, I can work out how to surface the info. Right now I'm diagnosing an out-of-memory issue when moving scenes a lot, and I want to see what Noesis's contribution towards that might be.

Re: Noesis stats in Unity

Posted: 04 Jul 2014, 13:45
by jsantos
We have profiling information regarding memory usage that is not available in c# right now. Also we have the following information for each frame:
struct RendererStats
{
    /// Information extracted from VGLSurface
    //@{
    NsSize triangles;
    NsSize maskTriangles;
    NsSize solidTriangles;
    NsSize linearGradientTriangles;
    NsSize radialGradientTriangles;
    NsSize texturedTriangles;
    NsSize batches;
    NsSize masks;
    NsSize fills;
    NsSize strokes;
    NsSize images;
    NsSize glyphs;
    //@}

    /// Render tree information
    //@{
    NsSize nodesWithClip, totalNodesWithClip;
    NsSize nodesWithOpacity, totalNodesWithOpacity;
    NsSize renderTargetSwitches;
    //@}
};
We should expose all this properties in the future. Also we have in mind developing an external tool that connect to your game and profile noesisGUI in realtime.

What exposed function calls do you mean?

Re: Noesis stats in Unity

Posted: 05 Jul 2014, 01:19
by wckdspn
I just mean something like a GetAllocatedMemory that returns a byte count exposed to C# API surface. An external profiler would be great, but just having the means to access this data from C# is very important in the short term.

Re: Noesis stats in Unity

Posted: 08 Jul 2014, 19:18
by jsantos
Yes, we could expose it. Could you please file a bug and describe the kind of API you need?

Thanks!

Re: Noesis stats in Unity

Posted: 08 Jul 2014, 20:09
by wckdspn
Bug filed.