Page 1 of 2

Autofill using jpegs and the CTG layer - is it possible?

Posted: 16 Mar 2016, 22:50
by rowlification
Hello there, I am very new to this software.

I have been using the CTG layers to auto fill colour and it's really fantastic. I have done it this way -

1. Duplicate layer structure
2. Convert to CTG layer
3. Fill area I want on first frame
4. Undo
5. Select all frames
6. Press 'Enter'

Was that the best way to do it? Anyway it works and that's great. But what I really want to know is - how can I do this same thing but instead of filling an area with a solid colour I can fill it with a bitmap such as a jpeg. I have found out from these forums that you can import an image to use as fill by importing it as a custom brush. Then using the Fill tool you can fill an area with this pattern. You can then press undo and select all frames and press enter and it will kind of try to auto fill all the frames. But pretty badly and there seems no way to do this via the CTG layer function. Is it possible to fill with a pattern made from an imported image via the CTG layer?

Perhaps if I tell you what I want to do it will help.

I have as my background a simple creme paper texture. The characters I want to animate are line drawings sitting above this. They do not have any fill for they only feature very small amounts of colour - say a bowtie or a hat, everything else - their heads and bodies - have no fill. But sometimes I need them to have fill so they can pass in front of each other. But I don't want them to appear to have fill, i just want there to be the paper texture that is the background, the only reason I want fill at all is so that you cannot see through them to anything that they pass infront of.

Does this make sense? Can you help?

Thanks for reading

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 17 Mar 2016, 06:01
by Elodie
1. Duplicate layer structure
2. Convert to CTG layer
3. Fill area I want on first frame
4. Undo
5. Select all frames
6. Press 'Enter'
You should better use the layer preset "colo & texture layer", that can be found in the "new" button, at the top-left side of the timeline.
Is it possible to fill with a pattern made from an imported image via the CTG layer?
Not immediately. CTG layers are not a simple "paint bucket" layer. They are using a complex algorithm that calculates the area to fill, following the thickness of the different squiggles and the the original lines from the source.
That's why it only generates solid and aliased colours.

However, once your sequence is coloured, you have different posibilities :
1) using the Texturizer withing CTG layer, with an image from the library
2) duplicate the structure and combine different Fx, such as Image Source + Inlay texture

Both features a re explained in tutorials and manual.

But, if I understant you well :
But I don't want them to appear to have fill, i just want there to be the paper texture that is the background, the only reason I want fill at all is so that you cannot see through them to anything that they pass infront of.

Does this make sense? Can you help?
... you simply have to use "multiply" mode in your CTG layer to display to paper of the background.

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 12:24
by rowlification
Thank you for replying to my post Elodie, very kind of you. Apologies for the delay in my reply but when I tried to check if anyone had replied the forum was down, then I got busy with something else and forgot about it. Rest assured I do appreciate the time it took you to reply to me. I have replied to your reply by annotating it - please see below.
Elodie wrote:
1. Duplicate layer structure
2. Convert to CTG layer
3. Fill area I want on first frame
4. Undo
5. Select all frames
6. Press 'Enter'
You should better use the layer preset "colo & texture layer", that can be found in the "new" button, at the top-left side of the timeline.

---> How is that better? Does that also duplicate the structure of the currently selected layer?
Is it possible to fill with a pattern made from an imported image via the CTG layer?
Not immediately. CTG layers are not a simple "paint bucket" layer. They are using a complex algorithm that calculates the area to fill, following the thickness of the different squiggles and the the original lines from the source.
That's why it only generates solid and aliased colours.

---> Yes, I realise that's how the CTG works but why would that algorhythm not be able to use a jpg as the fill? it just has to decide how big an area to fill and then fill it with a portion of whatever jpg you specify. The hard work of the algorhythm doesn't need to change from when it is filling with a solid colour does it?

However, once your sequence is coloured, you have different posibilities :
1) using the Texturizer withing CTG layer, with an image from the library
2) duplicate the structure and combine different Fx, such as Image Source + Inlay texture

Both features a re explained in tutorials and manual.

---> I do not want to apply a texture, I want to apply the specific colour and texture of a jpg in the same way that i apply a solid fill using the CTG layer - in the same way that filling with a pattern can be done in photoshop

But, if I understant you well :
But I don't want them to appear to have fill, i just want there to be the paper texture that is the background, the only reason I want fill at all is so that you cannot see through them to anything that they pass infront of.

Does this make sense? Can you help?


... you simply have to use "multiply" mode in your CTG layer to display to paper of the background.
---> No sorry, you do not understand me well, I need some fill so that they do not appear transparent when passing in front of other characters. Therefore I need them filled with my jpg's colour and texture NOT simply allowing the background to show through.

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 12:50
by Fabrice
please post some images, so we could help.

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 13:21
by slowtiger
My understanding is that he wants the look of black outlines on paper without any fill, but have the paper structure shine through everything. I think one way to achieve this would be like this:

1. Fill characters with a solid colour (white), via CTG or traditional.
2. Duplicate that background layer with the texture.
3. Extend that duplicated layer to the length of animation.
4. Activate the stencil of the animation layer, reverse it (so the transparent parts get editable).
5. Erase in the duplicated layer.
6. Put this layer on top of that CTG layer, but under the line art.

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 17:00
by rowlification
Hello Slowtiger and Fabrice,

Thank you for taking the time to try to help me.

Here is a little screen cap that might help -

Image

Each of these characters are on a separate layer. See the chap with the small hat and the chicken? I have filled them using an imported image via custom brush and the fill tool. It works well - he can move around in front of the girl on the left as if all the characters were all one drawing on one layer. If a CTG layer could achieve this then it would save me a lot of clicking to manually fill each frame.

I read your post slowtiger and tried to make sense of it. I am very new to TVpaint and am struggling.

You wrote -

1. Fill characters with a solid colour (white), via CTG or traditional.
2. Duplicate that background layer with the texture.
3. Extend that duplicated layer to the length of animation.
4. Activate the stencil of the animation layer, reverse it (so the transparent parts get editable).
5. Erase in the duplicated layer.
6. Put this layer on top of that CTG layer, but under the line art.

ok 1 is straightforward. 2 - duplicate which background layer? The paper texture background I am using? 3 - ok fine if I understand 2. 4. I don't know how this is achieved or what it really means. 5 - Likewise how is this achieved? I guess if I understood 4 I might be able to follow 5.

I am surprised that it isn't built in to fill using a defined pattern as you can do in photoshop, I'm thinking it might not be that hard to implement but perhaps the TVpaint coders know otherwise. I expected someone to come forward talking of how this is something they had to figure out. I mean think how useful - you could have a swatch of a plaid shirt pattern and fill a character's shirt with that, it'd be pretty cool.

Once again, thanks for taking time on this and apologies for my delay in responding - I hadn't realised this was such a good active forum

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 17:40
by rowlification
Oh let me add a bit more about how I am achieving filling with a jpg -

1. duplicate structure of layer i want to colour and place under the layer i duplicated the structure of
2. import an image as a custom brush.
3. choosing the paintbucket/fill tool i tick 'brush wrapping' in its options panel
4. bob's your uncle, fanny's your aunt : P

That's how I filled the fella and the chicken. You can even fill and undo and then select all frames and press enter and it will attempt to auto fill but it tends to go wrong pretty quick and of course because it isn't a ctg layer (and cannot be as you are not allowed to import a jpg to a ctg layer) you can't use exclusion to help the auto fill

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 17:56
by slowtiger
OK, more basics.

1. The fill of a character should be on a separate layer, which makes a lot of things much easier. So you'll have this structure:
- line layer on top
- fill/colour layer

2. You can use the fill tool on the fill layer using the line layer above as reference. There's a pulldown giving you options: layer, above, below, display. Use above.

3. Any layer can be used as a mask/stencil for any other layer. See the 4 dots right in the fill layer name's area? The right one is to toggle on/off the stencil of this layer. Click it active, now draw something in another layer: it will only show in areas where the fill layer has something drawn. Under the dot there's a switch to protect either the artwork or the transparent area.

What you do is:
- create a solid fill where needed
- make a copy of the background with its paper structure
- use the fill as a mask, but preserve the artwork
- erase in the copy what is transparent in the fill layer.

Why don't I use any brush with the paper texture? Because I don't want the paper texture to move.

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 20:41
by Fabrice
One can try the FX (Rendering / Inlay Texture) to make a paper moving with a character.

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 22 Mar 2016, 20:52
by rowlification
@slowtiger

1 & 2 - yep already understood this much, but thanks for checking.

3 & etc - this is really interesting. I am home now and cooking plus my TVPaint dongle is at work, but I will practice this tomorrow and see how I find it. Thank you. I particularly like as you say, the fact that the texture will remain consistent with the background.


@fabrice

Not sure what to make of this - I will see if I can find what you are talking about in the menus. Thanks.

@both, appreciate your time and advice on here, hope you have a good evening : )

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 23 Mar 2016, 08:13
by Fabrice
look here :

http://www.tvpaint.com/doc/tvp11/index. ... re&lang=en" onclick="window.open(this.href);return false;

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 24 Mar 2016, 11:46
by rowlification
@slowtiger - firstly I get stuck here -

- erase in the copy what is transparent in the fill layer.

You give no explanation as to how this will happen.

First I tried to create my fill layer by creating a ctg layer and filling the area i wanted for each frame. This didn't seem to work but I'm not sure.

So I then manually filled some areas on a regular anim layer.

I hit the dot on the right as you asked and it didn't seem to make any difference other than to tell me i could no longer draw on that layer. I don't understand how you tell this layer to use the layer beneath it (the paper texture layer) as it's source to mask. Your last instruction 'erase in the copy what is transparent in the fill layer.' leaves me like this :|

@fabrice. Having created a ctg layer that regularly filled the area i wanted to fill with a solid colour i figure i've got some shapes for your inlay texture fx to work with. So keeping that layer selected I then open the fx rendering/inlay texture dialogue box, load up my paper from the image library as the 'image' and hit 'Apply FX stack'. Nothing happens

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 24 Mar 2016, 12:04
by slowtiger
OK, you need to train working with masks, which are called stencil in TVP.

Let's have a new project. Import your background paper image, this will be layer A. Create a new layer, this will be layer B.

Paint some shape in layer B. Activate the stencil in layer B. Now you can only paint inside the shape, but not in the transparent area.

Under the stencil button, there's two little mask symbols (in v10, in v11 this looks different). Click the white one. Now your stencil should work in reverse: you can only paint in the transparent area, but not inside the shape.

Now select Layer A (your paper). Here you can only paint in the area which is transparent in Layer B. Aha! And when you hit Backspace now, exactly this area will be erased. What's left is a portion of your paper in the shape of Layer B - you will see it when you switch off visibility for Layer B or put it under Layer A.

Try to reproduce this until you feel confident. Then apply the same workflow to your animation. Layer A will be the duplicate of your background paper layer. Layer B will be the fill layer of your animation, no matter how you created that.


Hope this helps!

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 24 Mar 2016, 13:52
by rowlification
After turning layer B into a stencil layer and attempting to draw anywhere at all on this layer I get this message -

Image

Re: Autofill using jpegs and the CTG layer - is it possible?

Posted: 24 Mar 2016, 13:54
by slowtiger
Ouch. This works differently in v10!

Can some v11 user please confirm that you can't do anything on the layer with the active stencil?