Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - gecko64

Pages: [1]
1
We've got four buttons anchored at the four corners of the screen, and they disappear when I rotate the device 180 degrees. We only support landscape, not portrait, so the aspect ratio/resolution is exactly the same. Non-anchored objects are fine. Here's one of the anchored objects. Any idea what we're doing wrong?

thanks!
(And thanks for keeping NGUI going -- extremely helpful for legacy projects)

Dave


2
I was still on 3.0.7. I just upgraded to the latest version and the problem is fixed!! Huzzah!

And obviously, I should have upgraded before complaining. Sorry about that. :/

3
We have one atlas per panel, yet lots of drawcalls per panel. We need to have one panel per astronomical object, for various reasons.

I understand that it's a lot of panels, but it still seems like something isn't working correctly -- we have 40 panels, we should have 40 drawcalls, but instead we have over 300 drawcalls. If in fact we *should* have 300 drawcalls, then NGUI may not be the right tool for the job...but so far nobody is saying that we should have 300 drawcalls with this setup.

4
We have that many panels because each panel represents a different astronomical object, which needs to be placed on a skydome (inside a sphere), so it can rotate with the starry night.

I don't mind 40 drawcalls for 40 panels, but it's far more than that. (When I disable the parent of all these panels, drawcalls drop by about 300.) Attached is the Draw Call tool for one of those panels, showing many drawcalls for the sprites inside that panel.

I tried disabling all but one of these panels. After doing that, and then toggling individual sprites on and off, some use just a single drawcall, but others still use 2-3. Any ideas?

5
NGUI 3 Support / Several draw calls per sprite (only sprites in the panel)
« on: December 16, 2014, 08:59:21 PM »
I've got a game with a lot of panels -- at runtime, between 15 and 40 UIPanels are distributed across a starry-night skydome, representing astronomical objects. They're on a GUI layer is not affected by any lights, and only one camera is set to render that layer. Yet each sprite in each panel uses 2-4 drawcalls. I've read the various threads about this type of issue, but I don't think any apply. These panels are very simple: each one has about ten sprites in it, all of which use the same atlas. There are no dynamic fonts or anything else but sprites in the panels.  The panels revolve around the camera with the skydome, but the contents in each panel are static, so I've checked the "Static" toggle on each panel, and also checked the "Static" box on each sprite object.

I don't think that it's caused by 3.x's depth function, since there's nothing but sprites in these panels, and they all use the same atlas. There are several other GUI panels onscreen at the same time.

Any solutions or suggestions? It's really dragging down the frame rate.

thanks
Dave

6
NGUI 3 Support / Re: How to set up reference font
« on: March 14, 2014, 12:31:29 PM »
I know. That was my question -- how to load the correct set of font prefabs, so they'll match the Font Atlas being loaded via the LoadAtlas script. I can't figure out how to use a Reference Font to do that. 

7
NGUI 3 Support / Re: How to set up reference font
« on: March 13, 2014, 10:09:08 AM »
Thanks for the reply. But that part I understand. My question is: how to use Reference Fonts (with UIFont) with a LoadAtlas (or similar) script -- so the correct font prefab is selected? (I have already set up LoadAtlas to choose the correct Font Atlas, but that doesn't seem to switch the individual font prefabs. I have created Reference Fonts but can't figure out how to use the Load Atlas script (or something comparable) with them.

thanks
Dave

8
NGUI 3 Support / Re: How to set up reference font
« on: March 12, 2014, 08:54:08 AM »
So as I said, I am not going to upgrade to NGUI 3 due to the work involved, and all I need to do with this project is up-rez the graphics. But that's just too bad for me, because I didn't happen to tackle it a year ago? Can you give me any hints?

9
NGUI 3 Support / How to set up reference font
« on: March 11, 2014, 09:42:25 PM »
I've set up Reference Atlases with the LoadAtlas script, but I don't understand how to set up Reference Fonts. I thought I'd create a reference font for each font prefab, and then put LoadAtlas script on the UIRoot just like I've done for the Reference Atlases. But when I do that, I can't assign the Reference Font to the Reference Atlas slot in the inspector -- it rejects it, being the wrong type of object. So...do I put the LoadAtlas script on each Reference Font, or what do I do?

Edit: Oh, and in case it matters: this project is still on NGUI 2. (It's an old project, I'm just doing a higher-rez version, and can't do all the mods necessary to upgrade it to NGUI 3.)

thanks
Dave

10
NGUI 3 Support / Re: ArgumentException error when opening Atlas Maker
« on: April 16, 2013, 09:34:32 AM »
Argh, darn it, that didn't do it. I'm still getting the error. Is there any way to locate the duplicate sprites? I sure can't find them....

11
NGUI 3 Support / Re: ArgumentException error when opening Atlas Maker
« on: April 16, 2013, 09:30:14 AM »
That was it! We used FastGUI to import from photoshop and it created several folders, with a few button images with the same name. Thanks! (And to anyone else who has this problem: I moved all sprite images into the same folder, renaming those that Unity wouldn't copy due to duplicate names, then had to relaunch Unity to get rid of the error.)

12
NGUI 3 Support / ArgumentException error when opening Atlas Maker
« on: April 15, 2013, 04:15:54 PM »
I've been getting this error when I open the Atlas Maker, with a nearly-blank window. No way to close it, relaunching Unity doesn't help. How can I fix it?

ArgumentException: An element with the same key already exists in the dictionary.
System.Collections.Generic.Dictionary`2[System.String,System.Int32].Add (System.String key, Int32 value) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Collections.Generic/Dictionary.cs:404)
UIAtlasMaker.GetSpriteList (System.Collections.Generic.List`1 textures) (at Assets/NGUI/Scripts/Editor/UIAtlasMaker.cs:230)
UIAtlasMaker.OnGUI () (at Assets/NGUI/Scripts/Editor/UIAtlasMaker.cs:846)
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/b59ae78cff80e584/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)

13
NGUI 3 Support / Re: Font Maker fails
« on: February 21, 2013, 11:20:41 AM »
Turns out it was a problem with GlyphDesigner -- quitting and relaunching that app solved it. Weird.

14
NGUI 3 Support / Font Maker fails
« on: February 20, 2013, 01:39:37 PM »
I've been making fonts and atlases for a project in the past few days without a problem, but today, every font I try to make fails in the same way -- after i make the font, the font prefab is missing a sprite, and the new font has not been added to the font atlas. Throws an error when I look at the font prefab, below. Any suggestions?


NullReferenceException: Object reference not set to an instance of an object
UIFontInspector.OnPreviewGUI (Rect rect, UnityEngine.GUIStyle background) (at Assets/NGUI/Scripts/Editor/UIFontInspector.cs:277)
UnityEditor.Editor.OnInteractivePreviewGUI (Rect r, UnityEngine.GUIStyle background)
UnityEditor.Editor.DrawPreview (Rect previewPosition)
UnityEditor.InspectorWindow.DrawPreviewAndLabels ()
UnityEditor.InspectorWindow.OnGUI ()
System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Applications/buildAgent/work/3df08680c6f85295/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)

15
NGUI 3 Support / Re: UIInput on Web Player
« on: January 24, 2013, 10:22:50 AM »
We're having the problem with backspace not working in webplayers. I just tried it in 4.1 b2, and it still does not work. This (combined with inability to place the cursor) is a huge problem for email input fields. Any suggestions?

Pages: [1]