From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/32309 Path: news.gmane.org!not-for-mail From: Peter Rolf Newsgroups: gmane.comp.tex.context Subject: Re: shading with stitching functions Date: Wed, 27 Dec 2006 18:01:20 +0100 Message-ID: <4592A6E0.9010805@gmx.net> References: <6faad9f00612261448y18a9a2ceoe5b8293c4edc8153@mail.gmail.com> <45926EB1.2070903@gmx.net> <6faad9f00612270843n5a7ef120t10e7196654274bbd@mail.gmail.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: dough.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1167238906 20984 80.91.229.10 (27 Dec 2006 17:01:46 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 27 Dec 2006 17:01:46 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Wed Dec 27 18:01:44 2006 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by dough.gmane.org with esmtp (Exim 4.50) id 1Gzc9w-000319-Jc for gctc-ntg-context-518@m.gmane.org; Wed, 27 Dec 2006 18:01:44 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id EA22320045; Wed, 27 Dec 2006 17:59:51 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 09920-01-11; Wed, 27 Dec 2006 17:59:41 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 7FE5F1FFE8; Wed, 27 Dec 2006 17:59:41 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id D778B2000A for ; Wed, 27 Dec 2006 17:59:37 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 09920-01-10 for ; Wed, 27 Dec 2006 17:59:31 +0100 (CET) Original-Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by ronja.ntg.nl (Postfix) with SMTP id 463321FFCA for ; Wed, 27 Dec 2006 17:59:31 +0100 (CET) Original-Received: (qmail invoked by alias); 27 Dec 2006 17:01:23 -0000 Original-Received: from i577BBF4A.versanet.de (EHLO [192.168.1.3]) [87.123.191.74] by mail.gmx.net (mp042) with SMTP; 27 Dec 2006 18:01:23 +0100 X-Authenticated: #24293357 User-Agent: Thunderbird 1.5.0.9 (Windows/20061207) Original-To: mailing list for ConTeXt users In-Reply-To: <6faad9f00612270843n5a7ef120t10e7196654274bbd@mail.gmail.com> X-Enigmail-Version: 0.94.0.0 X-Y-GMX-Trusted: 0 X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:32309 Archived-At: Mojca Miklavec wrote: > On 12/27/06, Peter Rolf wrote: >> Hi Mojca, >> >> this is also on my wishlist (and christmas is over). Currently I use >> several color gradients in a row, to simulate the same effect. But sadly >> this way is too viewer dependent (rendering is a matter of luck with >> every new version), not to mention the big size. So if there would be a >> cleaner solution, I would be a happy man. >> >> I'm willing to help, but I haven't looked into specials yet. Give me >> some time for reading and some more time for understanding... ;) > > With Hans's hint I finally got some kind of result. However, the > numbers in the stream seem to influence the colors, but not in the way > I want them to. I have to do some further explorations. Does anyone > know how to convert PS to PDF without compression? > I used \pdfcompresslevel=0 with your example code. > Btw: TikZ supports such shadings, so if you don't necessary need a > metapost graphic, you can take a look at it as well. Here's an example >>from the manual: > I need them as mp graphic, but it shouldn't hurt to look into that. > \usemodule[tikz] > \starttext > \pgfdeclarehorizontalshading{myshadingA} > {1cm}{rgb(0cm)=(1,0,0); color(2cm)=(green); color(4cm)=(blue)} > \pgfuseshading{myshadingA} > \stoptext > > (I've just found out that it uses another aproach for "sampled > functions", perhaps I'll have more chances to figure out how to > implement it that way.) > > Mojca > _______________________________________________ > ntg-context mailing list > ntg-context@ntg.nl > http://www.ntg.nl/mailman/listinfo/ntg-context >