Last Comment Bug 333613 - update canvas on branch
: update canvas on branch
Status: RESOLVED FIXED
: fixed1.8.1
Product: Core
Classification: Components
Component: Canvas: 2D (show other bugs)
: 1.8 Branch
: x86 All
: -- normal with 1 vote (vote)
: ---
Assigned To: Vladimir Vukicevic [:vlad] [:vladv]
:
Mentors:
: 337319 (view as bug list)
Depends on: 245684 291218 293244 333177 336331 338407
Blocks: 337214
  Show dependency treegraph
 
Reported: 2006-04-11 12:04 PDT by Vladimir Vukicevic [:vlad] [:vladv]
Modified: 2006-07-01 18:17 PDT (History)
12 users (show)
mtschrep: blocking1.8.1+
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
moz18-canvas-update.patch (104.64 KB, patch)
2006-04-28 13:36 PDT, Vladimir Vukicevic [:vlad] [:vladv]
no flags Details | Diff | Review
new patch, with updated todataURL stuff (109.23 KB, patch)
2006-05-03 15:12 PDT, Vladimir Vukicevic [:vlad] [:vladv]
roc: superreview+
shaver: approval‑branch‑1.8.1+
Details | Diff | Review

Description Vladimir Vukicevic [:vlad] [:vladv] 2006-04-11 12:04:52 PDT
Two bits of functionality that we should give to web developers on the branch:

1. toDataURL bits
   - bug 245684 (add image encoder support)
   - bug 291218 (toDataURL)
   - bug 293244 (security checks)
2. canvas speedup and API fixes
   - bug 333177
Comment 1 Vladimir Vukicevic [:vlad] [:vladv] 2006-04-28 13:36:33 PDT
Created attachment 220169 [details] [diff] [review]
moz18-canvas-update.patch

1.8 version of my patch from bug 333177; the only change outside of canvas bits is an API change in nsIRenderingContext.h -- we were returing "native graphic data" as a PRUint32, when in most cases the actual data was a pointer (this function was unused in most of the RC backends, but I needed to get at the underlying native thing for canvas).  This seems like a very bad thing to do on 64-bit platforms, so I changed this to return a |void *| instead.
Comment 2 Vladimir Vukicevic [:vlad] [:vladv] 2006-04-28 13:45:53 PDT
Oh, that patch does not have image encoders moved over, though the infrastructure is in the canvas code -- once they're moved over the bits can just be uncommented out.
Comment 3 Mike Shaver (:shaver -- probably not reading bugmail closely) 2006-04-29 09:29:46 PDT
1.8.1, boy howdy.
Comment 4 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2006-05-01 01:09:31 PDT
Do we really want all the MOZ_CAIRO_GFX code? Is it worth it to get more consistent diffs between branch and trunk?
Comment 5 Mike Shaver (:shaver -- probably not reading bugmail closely) 2006-05-01 07:53:08 PDT
I think branch/trunk sync is virtuous here, yeah.
Comment 6 Vladimir Vukicevic [:vlad] [:vladv] 2006-05-01 10:31:15 PDT
I'm writing the exact same code for trunk/branch right now; I don't see any value to pulling out one or the other.  Sometime after Fx2 ships, I'll pull out the MOZILLA_1_8_* stuff from the trunk, because at that point it will be much harder to get simultaneous changes in; but for now, it seems easier to do a patch if it can apply directly to branch and trunk.
Comment 7 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2006-05-02 14:46:43 PDT
Comment on attachment 220169 [details] [diff] [review]
moz18-canvas-update.patch

sr+ with toDataURLAs disabled on branch.
Comment 8 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2006-05-02 15:19:26 PDT
Comment on attachment 220169 [details] [diff] [review]
moz18-canvas-update.patch

resetting requests since it looks like we'll want to make it toDataURL(format) as per the WHATWG spec.
Comment 9 Vladimir Vukicevic [:vlad] [:vladv] 2006-05-03 15:12:35 PDT
Created attachment 220710 [details] [diff] [review]
new patch, with updated todataURL stuff

New patch, with updated toDataURL API.
Comment 10 Mike Shaver (:shaver -- probably not reading bugmail closely) 2006-05-05 09:14:34 PDT
Comment on attachment 220710 [details] [diff] [review]
new patch, with updated todataURL stuff

branch-approved, let's get this mother on.
Comment 11 Vladimir Vukicevic [:vlad] [:vladv] 2006-05-05 09:17:29 PDT
Checked in 
Comment 12 Roy Tam 2006-05-08 09:06:45 PDT
(In reply to comment #11)
> Checked in 
> 

It breaks the gdiplus SVG rendering.

mozilla\layout\svg\renderer\src\gdiplus\nsSVGGDIPlusCanvas.cpp(140) : error C2664: 'nsIRenderingContext::RetrieveCurrentNativeGraphicData' : cannot convert parameter 1 from 'PRUint32 *' to 'void ** '
Comment 13 Mike Shaver (:shaver -- probably not reading bugmail closely) 2006-05-08 09:17:23 PDT
Can you file a bug on that breakage, and mark it as blocking this one?  Thanks.  It looks like the obvious fix (following the new pattern in nsCanvasRenderingContext2D::Render) would work, but I don't have an environment to test that in.
Comment 14 Roy Tam 2006-05-08 17:15:45 PDT
(In reply to comment #13)
> Can you file a bug on that breakage, and mark it as blocking this one?  Thanks.
>  It looks like the obvious fix (following the new pattern in
> nsCanvasRenderingContext2D::Render) would work, but I don't have an environment
> to test that in.
> 

bug 337214 is filed.
Comment 15 Mike Shaver (:shaver -- probably not reading bugmail closely) 2006-05-08 18:40:30 PDT
Doesn't affect the 1.8.0.x branch, marking bug blocking appropriately.  (But do we use GDI SVG anywhere on the 1.8 branch?  I thought that was all cairo now.)
Comment 16 Roy Tam 2006-05-08 20:51:04 PDT
(In reply to comment #15)
> Doesn't affect the 1.8.0.x branch, marking bug blocking appropriately.  (But do
> we use GDI SVG anywhere on the 1.8 branch?  I thought that was all cairo now.)
> 

Sorry for mis-marking this. Originally I want to mark blocking Firefox 2.0a1 but there's no option for that.
Comment 17 tor 2006-05-09 05:47:56 PDT
(In reply to comment #15)
> Doesn't affect the 1.8.0.x branch, marking bug blocking appropriately.  (But do
> we use GDI SVG anywhere on the 1.8 branch?  I thought that was all cairo now.)

While we didn't end up shipping it, the GDI+ backend code is still in the 1.8 branches.
Comment 18 Mike Shaver (:shaver -- probably not reading bugmail closely) 2006-05-09 07:16:09 PDT
And we've already shipped alpha1 some weeks ago, so...

(More in the new bug.)
Comment 19 Adam Guthrie 2006-05-09 13:00:33 PDT
*** Bug 337319 has been marked as a duplicate of this bug. ***
Comment 20 Mike Beltzner [:beltzner, not reading bugmail] 2006-06-28 19:45:04 PDT
Er, wait - I just marked this [checkin needed] but vlad's comment 11 makes me think it might be checked in already. If it is, please mark fixed1.8.1 in the keywords.
Comment 21 Doug Shelton 2006-07-01 17:37:24 PDT
BeOS branch builds have same bustage as OS/2.  Bug 343365 created.

Note You need to log in before you can comment on or make changes to this bug.