Another newbie

If you have a design you're proud of, share the cfdg file here. It's also a good place to ask for feedback and collaborate.

Moderators: MtnViewJohn, chris, mtnviewmark

Post Reply
lkmitch
Posts: 3
Joined: Tue Sep 27, 2005 9:46 pm
Contact:

Another newbie

Post by lkmitch »

Hi all,

I just discovered CFDG yesterday, and this is my first (presentable) image.

Kerry Mitchell

Code: Select all

startshape SS1

rule SS1 {
	BASE{s 1.3}
	BARNEY {}
	FRED {}
}

rule BASE {
	SQUARE {b 0}
	SQUARE {s 0.9925 b 1}
}

rule FRED {
	SQUARE {b 0}
	SQUARE {s 0.9925 b 1}
	FRED {r -3 s 0.98}
}

rule BARNEY {
	SQUARE {b 0}
	SQUARE {s 0.9925 b 1}
	BARNEY {r 1 s 0.98}
}
Image

dzeni
Posts: 18
Joined: Wed Sep 28, 2005 2:18 pm
Location: Auckland, New Zealand
Contact:

Amazing!

Post by dzeni »

I love your work.

Hope you don't mind but I took some liberties with it and gave it a hint of colour.

Below is the changed script.

---
startshape SS1

rule SS1 {
BASE{s 1.3}
BARNEY {}
FRED {}
}

rule BASE {
SQUARE {b 0 hue 1 sat .9}
SQUARE {s 0.9925 b 1 hue 200 sat 1}
}

rule FRED {
SQUARE {b 0}
SQUARE {s 0.9925 b 1 hue 50 sat .7}
FRED {r -3 s 0.98}
}

rule BARNEY {
SQUARE {b 0}
SQUARE {s 0.9925 b 1 hue 0 sat .9}
BARNEY {r 1 s 0.98}
}
---

Needless to say, I appreciate you posting your stuff and think you are wonderful.

Dzeni
http://www.dzeni.blogspot.com

lkmitch
Posts: 3
Joined: Tue Sep 27, 2005 9:46 pm
Contact:

Post by lkmitch »

Hi Dzeni,

Nice job with the coloring. I haven't quite figured that out yet. :D

Kerry

User avatar
UglyPuppy
Posts: 12
Joined: Thu Jul 07, 2005 2:33 pm
Location: here
Contact:

Post by UglyPuppy »

Holy crap that's cool. Not newbish at all...
Great Job!

dzeni
Posts: 18
Joined: Wed Sep 28, 2005 2:18 pm
Location: Auckland, New Zealand
Contact:

Colouring

Post by dzeni »

Thanks :)

It took a bit of playing but basically you can add colour to your stuff by specifiying values for hue, saturation and brightness. The thing is, if you don't specify the saturation and brightness as well as the hue, it won't work.

To get a red circle the rule would be:

rule redcircle
{
CIRCLE{hue 0 sat 1 b 1}
}

Not very interesting (I know). To get a blue circle, simply change the hue value to around 200.

G-d Bless

Dzeni :)

User avatar
MtnViewJohn
Site Admin
Posts: 882
Joined: Fri May 06, 2005 2:26 pm
Location: Mountain View, California
Contact:

Post by MtnViewJohn »

Color is a recent addition to Context Free. We had to set the default saturation and brightness to 0% to avoid breaking all of the pre-color CFDG files.

Post Reply