ndee85 / coa_tools

COA Tools is a 2D Animation Suite for blender. It offers a 2D cutout animation workflow similar to programs like spine or spriter.
GNU General Public License v3.0
908 stars 139 forks source link

Select different animation = camera broken on render #18

Closed IBwWG closed 8 years ago

IBwWG commented 8 years ago

If I have an animation selected, then create an ortho camera, then render the animation, it looks great.

If I then select a different animation from the Cutout Animation Collections, select the same camera, and render the animation, only one or two sprites show up in the output. Also, just after selecting the different animation, the view only shows one or two sprites, and I have to click on 2D view again, even though it's already selected. This fixes the view, but rendering afterwards still only shows the same one or two sprites.

Resetting the camera size doesn't help. Only deleting and making a new camera and putting it in the exact same location seems to make rendering work again.

ndee85 commented 8 years ago

The Animation Collection Frame Settings will also be used for rendering. Make sure they are set right. They overwrite the global settings. I have worked lately alot on the animation collections to improve them. Will push changes soon which makes it hopefully easier to work with. Especially if you want to use NLA Strips.

IBwWG commented 8 years ago

Where do I find those settings?

I haven't delved into NLA Strips (yet?) but I look forward to your changes :) Thanks!

ndee85 commented 8 years ago

Should work now everything I think.

IBwWG commented 8 years ago

I'm still having this issue with the latest update. Do you mean the ACF settings, as in, whether the "eye" icon is clicked in coatools or not? I.e. if it's visible in preview, it should render? If so, they are already set to visible, yet only one or two sprites render after I change the camera. So I'm not sure which settings you mean, I don't see any related to rendering in the coatools AC panel...

IBwWG commented 8 years ago

Also, now it seems that instead of rendering most of the animation (I usually hit ESC after a few frames, when seeing this...), the first frame shows 1 or 2 sprites, then later frames gradually show more, but by the end, still not all are visible. This is on an anim without z-order changes. And just to confirm, the behaviour of most sprites disappearing in the preview when you select the different animation, and only reappearing when you click 2D view (even if already clicked) is still there too.

IBwWG commented 8 years ago

It looks as though it is a z-order issue, though. Maybe I have some sprites at the same z-order and it's deciding randomly at render time which ones go on top of each other, but anyway, if I set the camera's Y value to, say, 1, everything disappears on render, and if I set it to -1, it's all there. So that's an easy workaround.

I suppose that when the camera is created, its Y value gets set based on the current animation's sprites' lowest Y value, although it's strange that I seemed to have this behaviour in both directions (i.e. going from anim A to anim B or vice-versa, both seem broken), so maybe this hypothesis is incorrect.

IBwWG commented 8 years ago

Interestingly, I noticed that when I select an animation in coattools, the Y value of the camera changes. That must be what causes it, I'm not sure why it does that. Anyway just modifying the Y value is a lot easier than copying in X and Z and width and height and scale and creating a new camera. :)

ndee85 commented 8 years ago

@GimmickyApps camera resetting is fixed with the latest commit.