Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / Cel - Shading style effect on non-symmetrical models?

Miscreant Software
Years of Service
User Offline
Joined: 5th Mar 2010
Location: Australia (where the kangaroos are)
Posted: 16th Sep 2011 05:53
Hi everyone,
I'm fairly new to DBpro, and as such probably don't know half the things i should. =)
After looking at the various art styles (for games) around, I really wanted to create a Cel-shaded cartoonish look for my project, to suit my stylised models. I tried DBpro's cartoon shader (set cartoon shading on) on my model, and it just wasn't quite... cartoony enough. The problem I had was with the outlines. I was really hoping that it would have a cel-shading-style thick black outline, but it didn't.
I tried the trick with the inverted duplicate model elsewhere on the forum, but when I tried it with my character model (a .x file), it appeared upside down when I inverted it.

Does anyone know how to make a cel-shaded effect in DBpro that works for non-symmetrical models?

Thankyou in advance,

GenericRandom1 (i set the profile name ages ago, and i can't change it)
Years of Service
User Offline
Joined: 10th Mar 2003
Location: Long Island, NY
Posted: 17th Sep 2011 02:00 Edited at: 17th Sep 2011 02:23
This probably should be in the DBpro board. Hoping this thread helps you.

Take a look at Neophyte's tutorial on page 2 of the
The Ultimate Shader Thread
He does some tweaks with the built-in cell shading

The Ultimate Shader Thread 2

Your signature has been erased by a mod please reduce it to 600 x 120.
Miscreant Software
Years of Service
User Offline
Joined: 5th Mar 2010
Location: Australia (where the kangaroos are)
Posted: 17th Sep 2011 09:10
Thankyou for such a prompt reply!

You're right, it should be in the DBpro board; I thought it was there, but evidently not. =)

I looked over the threads you sent me, and they appear to be exactly what I was after. I compiled the example program on the
thread, substituting in my character instead of the sphere, and it worked perfectly.
However, when I tried to incorporate this into my actual program, it stopped working. I copied and pasted lines 1-19 into my program when the character is loaded, substituting its ID number (25) where needed. However, when I executed the program, it stopped responding at the end of the loading process and quit, not specifying why. I have no idea how to rectify this problem.

Did I copy the correct lines?

btw, I pasted the shader code snippet into Notepad and saved it as cartoon.fx

Thankyou again for your help,


Login to post a reply

Server time is: 2020-08-15 11:27:48
Your offset time is: 2020-08-15 11:27:48