DO NOT REPLY [Bug 46583] New: [PATCH] PS tiling patterns implementation

View: New views
13 Messages — Rating Filter:   Alert me  

DO NOT REPLY [Bug 46583] New: [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583

           Summary: [PATCH] PS tiling patterns implementation
           Product: XMLGraphicsCommons
           Version: Trunk
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: PostScript
        AssignedTo: general@...
        ReportedBy: kunhart@...


Created an attachment (id=23157)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=23157)
tiling patterns patch

This patch allows to make and use postscript tiling patterns. Tiling patterns
consist of a small graphical figure (called a pattern cell) that is replicated
at fixed horizontal and vertical intervals to fill the area to be painted.

Notice that a image (a texture) must not be a too large, otherwise the
postscript error 'limitcheck' will be generated (on ps printer or in ps
viewer).


--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583


Jeremias Maerki <jeremias@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO




--- Comment #1 from Jeremias Maerki <jeremias@...>  2009-02-07 03:31:24 PST ---
Sorry for not responding earlier. Thank you for your patch. This is a nice
addition. However, before I can process your patch, can I ask you to do the
following:

- Since your patch includes new files, please fill out and send an ICLA
(Individual Contributor License Agreement, see [1] for details). Depending on
your work contract you may also need to ask your employer to consider sending
in a CCLA.

[1] http://apache.org/licenses/#clas

- Please put the same license header you find in our other source files on top
of the new files you create to clearly indicate that you are donating this to
the ASF.

- And finally, please rework the patch to make it Java 1.4 compatible. (this
point I can handle for you if you want but it would be great if you could do it
while you add the license headers)

- One note on the code while taking a quick look: You used an ArrayList for the
bounding box. Please consider using a java.awt.Rectangle instead.

I hope you understand. Thank you very much!


--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #2 from Jiri Kunhart <kunhart@...>  2009-02-17 01:43:05 PST ---
Created an attachment (id=23267)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=23267)
java 1.4 compatible patch


--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583


Jiri Kunhart <kunhart@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |ASSIGNED




--- Comment #3 from Jiri Kunhart <kunhart@...>  2009-02-17 01:54:52 PST ---
Jeremias, it should be ok now.
I have sent ICLA and CCLA licenses, the patch is now java 1.4 compatible,
headers are included and Rectangle instead of Array is used.


--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #4 from Jeremias Maerki <jeremias@...>  2009-02-18 00:46:20 PST ---
Thank you, Jiri. I'll process your patch as soon as your ICLA is recorded. That
could take a few days, though.


--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #5 from Jeremias Maerki <jeremias@...>  2009-03-02 00:41:55 PST ---
Jiri, your CLA still hasn't shown up. :-( How did you submit it? In the
meantime, there have been a number of batches with CLAs but yours was not among
them.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #6 from Jiri Kunhart <kunhart@...>  2009-03-02 01:00:02 PST ---
Jeremias,

I sent it via email to secretary@..., 14 days ago (17.2.2009), the
subject was "FOP ICLA and CCLA". Should I send it again?

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #7 from Jeremias Maerki <jeremias@...>  2009-03-02 01:03:19 PST ---
If it's no trouble for you, yes, please do. I'll talk to the secretary directly
if it doesn't appear by next week. Thanks for your patience.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #8 from Jiri Kunhart <kunhart@...>  2009-03-02 01:10:20 PST ---
No problem Jeremias. I have sent it again.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #9 from Jeremias Maerki <jeremias@...>  2009-03-12 03:14:56 PST ---
Jiri, your ICLA (and the CCLA) has finally been recorded. I've also already
taken the time to process the patch and applied it with modifications:
http://svn.apache.org/viewvc?rev=752822&view=rev

As you can see in the commit message, I found a bug concerning the anchor
rectangle. I found that using the example I've just committed:
http://svn.apache.org/viewvc?rev=752824&view=rev

Another problem which I didn't realize earlier is that your changes violate the
DSC specification. Here's the scenario:
Create a PostScript document with two pages and use the same TexturePaint on
both pages. Then extract the second page according to DSC rules and you get an
invalid PostScript file (because it misses the pattern that is part of the
first page).
The example above demonstrates this. This is not catastrophic but it should be
fixed at some point. This is why I'll leave this issue open for the time being.

I think there are two approaches:
1. limit the reuse of tiling patterns to one page and ignore DSC for pattern
resources.
2. Tie pattern resources into resource tracking. This will require changes in
PSDocumentGraphics2D similar to what we do in Apache FOP: we create the
PostScript file as a temporary file and create common resources in the setup
part in a second pass. See:
http://svn.eu.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/render/ps/ResourceHandler.java?view=markup

Thanks for your patience, Jiri.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #10 from Jiri Kunhart <kunhart@...>  2009-05-26 06:05:08 PST ---
Hi Jeremias,

I checked your changes about anchor rectangle in the code and I think you did
it very well. But now I think, there is no reason to define the patterns in the
ResourceHandler, because now every pattern is unique - because of the line
"x y translate" in PaintProc - x and y will be always different (there is no
reason to draw the same pattern (if I say the same pattern I mean the same
binary data of pattern) on the same position (I mean the position which is
specified by "x y translate") several times). So I decided to delete class
PSPatternStorage, don't use the ResourceHandler and the pattern define directly
on a page where is used.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583





--- Comment #11 from Jiri Kunhart <kunhart@...>  2009-05-27 07:08:39 PST ---
Created an attachment (id=23720)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=23720)
Patterns will not violate DSC rules after using this patch

This patch remove the class PSPaternStorage and all references to it. Patterns
will not violate DSC rules, but now the same pattern can be defined more than
one time on the page (document) => the size of the output file can be a bigger
than it is necessary. The right solution would be to define pattern resources
in the begin of the ps document, similarly how it is done for fonts and images.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...


DO NOT REPLY [Bug 46583] [PATCH] PS tiling patterns implementation

by Bugzilla from bugzilla@apache.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

https://issues.apache.org/bugzilla/show_bug.cgi?id=46583


Jeremias Maerki <jeremias@...> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


--- Comment #12 from Jeremias Maerki <jeremias@...> 2009-08-15 02:15:05 PDT ---
Latest patch applied: http://svn.apache.org/viewvc?rev=804444&view=rev

Thanks a lot, Jiří and sorry for the slow reaction time! Pattern generation now
looks fine to me. I think that means we can close this issue here.

--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@...
For additional commands, e-mail: general-help@...