CocoStudio Scale9 sprite support seems broken/non-functional

CocoStudio Scale9 sprite support seems broken/non-functional
0.0 0


So I’ve just started evaluating CocoStudio’s UI editor, and I’m really confused. Maybe I’m just missing something, but it seems like the authors have perhaps misunderstood how to use CCScale9Sprite (or “9-slice” as they call it).
First off, the ImageView widget. Enabling “9 Slice” there, it doesn’t seem to behave in any way like a CCScale9Sprite, at least in the editor. Looking at the runtime cocos2d-x code, it seems to be using CCScale9Sprite in the implementation, so perhaps the end result is correct (I haven’t tested that), but certainly none of the editor behaviour is anything like a 9 slice image. Changing the “origin” and “width and height” settings in the “Sudoku Size” settings seems to warp the image in interesting ways that are reminiscent of 9 slicing, but when I go to actually scale the image (using the mouse by dragging the edges around), it does nothing 9-slicey.

I looked to the examples for some idea of how to use it. Sure enough, in the “DemoMap” example, the “alert_Panel” has a “bg_ImageView” that has “Enable 9 slice” checked. Both origin and w/h under “Sudoku Size” were set to zero. I tried scaling it. Nope. It doesn’t scale as a 9 slice would I checked the actual source art. In the source art the image is 419x148 pixels! What!? This is the perfect example of where a scale 9 sprite should be used, but the artist has actually gone and scaled it in photoshop. This says to me that scale 9 support is most likely completely broken, at least in the editor.

Next I took a look at the Button widget. It supports text in a button image. But it doesn’t seem to scale to my text size in any way, and physically scaling it just uniformly scales it (no scale 9 support here). Checking the source art, once again it’s a hard-sized rectangular image. This is in no way a replacement for the CCControlButton that we were used to in CocosBuilder.

So it seems like the UI editor is still in its infancy, but according to a forum post 5 months ago, it had been in development for 1.5 years already. This is extremely worrying to me that it’s been worked on for nearly 2 years and scale 9 sprites, which are a crucial component of UI development, are still broken.

So, I totally understand that this is a free product, and I should be happy to get what I get, but given that it’s not open source, I can’t even help out to fix it where it’s broken. It just doesn’t feel ready for production use at all. I’ll keep on using Cocos Builder for now.

Does the development team have any comment?

TL;DR: What’s the deal with scale 9 sprites in Cocos Builder?



Does the development team have any comment?


I have the same question