||Re: Filling with TBitmapPolygonFiller
Lynn C. Ormond <firstname.lastname@example.org>
||Tue, 27 Apr 2010 13:33:17 -0700
P&G.jpg, P&G ThreeD.jpg
I've been looking at something similiar recently and can outline what is
needed, I think.
I haven't actually started coding, just getting the concept clear in my
1. You need one of two things with your fill image. Either it should be
visible line, or you need to treat it as if it is stretched for fill
the area of your cloth
when it is flat.
2. Determine Z order of your fill areas, back to front, skipping those
that are hidden by
nearer folds of the cloth, or just drawing them first.
3. Calculate the size of each rectangle (flattened) and the copy that
suitable transforms for fit the shape of your cloth, in is display
It's gonna be fun!, but once you get it, particularly if you add light and
shading, it should
I've recently added 3D effects to my Infinite Fascination project. Attached
without shading and with.
"Simon Beesley" <email@example.com> wrote in message
> I have got a cloth simulation that offers a number of different drawing
> modes. In one of them, it uses TBitMapPolygonFiller to fill the cloth with
> floral (clothlike) pattern from a JPG image. The attached pictures show
> the cloth with and without the pattern.
> Unfortunately this doesn't look as good as I hoped it would, since the
> pattern doesn't get rescaled to fit the cloth outline. I've seen cloth
> simulations in Flash with Actionscript that fit the image to the cloth
> some kind of triangulation technique, but so far I haven't been able to
> out how it's done.
> Is there any way to do this with GR32 (with or without