Skip to main content
sasikumars93559897
Participant
April 1, 2015
Question

How to create PathGradient in PDF?

  • April 1, 2015
  • 1 reply
  • 1245 views

I have only little knowledge about pdf language

Can anybody reply me please...

Thanks.

This topic has been closed for replies.

1 reply

Known Participant
April 1, 2015

Are you talking about using Acrobat or using a shading dictionry in a pdf job?

sasikumars93559897
Participant
April 7, 2015

Yes i need to implement PathGradient in pdf ,So tell me what type of shading i need to use  and how to implement

Known Participant
April 7, 2015

There are various ways of doing it. One example would be:

specify a shading resource, like

/Resources  <<
   /Shading <</Sh1 4 0 R>>
   >>

where object 4 is a shading dictionary, like

4 0 obj  <<

/ColorSpace /DeviceGray

/ShadingType 2

/Function <<

    /FunctionType 2

    /N 1

    /Range [0 1]

    /Domain [0 1]

    /C1 [0.0705882]

    /C0 [0.1]

>>

/Domain [0 1]

/Coords [15  15  45  30 ]

/Extend [true true]

>>

endobj

Then in your job stream, you can construct your path and gradient fill the path with

/Sh1 sh

Hope this helps.

-R