#
4399ec51 |
|
10-Jun-2020 |
X512 <danger_mail@list.ru> |
BPicture: add fill rule support Change-Id: I068e1c2e8659f7b90c6d7c7331a8bb25ae343fe9 Reviewed-on: https://review.haiku-os.org/c/haiku/+/2922 Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
|
#
90ab1a44 |
|
27-May-2020 |
X512 <danger_mail@list.ru> |
BPicture: add gradient support Fixes #9680. Change-Id: I0013326559cc40ff26cf7b44794c0b32aea832ba Reviewed-on: https://review.haiku-os.org/c/haiku/+/2829 Reviewed-by: Stephan Aßmus <superstippi@gmx.de>
|
#
954a0a0c |
|
02-Jan-2019 |
Stephan Aßmus <superstippi@gmx.de> |
Fix some cases of updating draw state while recording a BPicture * Also implemented recording DrawString(string, length, BPoint[] locations), which was previously not recorded at all. * Also implemented playing back recently added drawing commands in PicturePlayer.cpp. I don't quite understand what this is actually used for, but it seemed it was forgotten. I just followed the pattern already established in the code. * The other important bit in this change is to update the pen location when it is needed while recording a BPicture. Often the BView will use PenLocation() in order to transmit drawing commands to the app_server which use absolute coordinates only. This isn't actually so nice, since it means the client has to wait for the server to transmit the current pen location. If there were dedicated link-commands for pen-relative drawing commands, the client could just keep sending without waiting for the server. In any case, the app_server needs to update the pen location in the current DrawState and even the DrawingEngine even while recording a picture, because some next command may need up-2-date state information, such as the font state and the pen location. * I have not yet tried to find /all/ instances where the DrawState needs to be updated while recording. This change should repair /all/ font state changes, all versions of drawing a string, and all versions of StrokeLine(). Change-Id: Ia0f23e7b1cd058f70f76a5849acb2d02e0f0da09 Reviewed-on: https://review.haiku-os.org/c/817 Reviewed-by: Stephan Aßmus <superstippi@gmx.de>
|
#
57067377 |
|
10-Sep-2018 |
JackBurton79 <stefano.ceccherini@gmail.com> |
PictureDataWriter: Fix invert rect. Resetting the drawing mode to B_OP_COPY was not right, since the previous mode could be anything. Use WritePush/PopState() instead. Change-Id: If9cba2c46bf372fd0164d951fcc49696cf72d576
|
#
25dbf74b |
|
10-Nov-2015 |
Julian Harnath <julian.harnath@rwth-aachen.de> |
BView: add methods for affine translation/scaling/rotation * BView::TranslateBy(), BView::ScaleBy() and BView::RotateBy() allow to conveniently modify the current affine transformation. This makes it unnecessary to first read the current transform, modify it, and then set it again. Uses the new Pre...() methods of BAffineTransform. * Also, remove setting the transform "through" to the BView even while recording a BPicture, as this now results in transforms being applied more than once.
|
#
4bd6f322 |
|
09-Nov-2015 |
Julian Harnath <julian.harnath@rwth-aachen.de> |
app_server/Interface Kit: add new clipping API * Add new clipping API for rectangles (ClipToRect, ClipToInverseRect) and shapes (ClipToShape, ClipToInverseShape) * Works with affine transforms and automatically switches from fast region-based clipping to alpha-mask based clipping as necessary. * Always self-intersecting, i.e. no state push required to further narrow down the clipping region. All of the 4 new methods can be mixed in any order.
|
#
551438b9 |
|
25-Jul-2015 |
Julian Harnath <julian.harnath@rwth-aachen.de> |
app_server: add new BView layers API * Add new methods BView::BeginLayer(uint8 opacity) BView::EndLayer() * All drawing between begin and end of a layer is redirected onto an intermediate bitmap. When ending the layer, this bitmap is composited onto the view with the opacity given when the layer was started. * Layers can be nested arbitrarily and will be blended onto each other in order. There can also be any arbitrary interleaving of layer begin/end and drawing operations. * Internally, drawing commands are redirected into a BPicture between BeginLayer and EndLayer (but client code need not know or care about this). Client code can also start/end other BPictures while inside a layer. * Uses the PictureBoundingBoxPlayer to determine the size of the layer bitmap before allocating and drawing into it, so it does not allocate more memory than necessary and -- more importantly -- it will not alpha-composite more pixels than necessary. * Drawing mode is always set to B_OP_ALPHA, blend mode to (B_PIXEL_ALPHA, B_ALPHA_COMPOSITE) while inside layers. This is necessary for (a) correct compositing output and (b) for redirection of drawing into the intermediate bitmap, which uses the renderer_region offset (in B_OP_COPY, the Painter does not use the AGG renderer methods, it directly accesses the pixel data. This would access out-of-bounds without the offset, so B_OP_COPY cannot be allowed.) To ensure these modes aren't changed, BView::SetDrawingMode() and BView::SetBlendingMode() are ignored while inside a layer. * The main motivation behind this new API is WebKit, which internally expects such a layers functionality to be present. A performant and reusable implementation of this functionality can only be done server-side in app_server.
|
#
ce27f961 |
|
05-Sep-2015 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implement ClipToPicture inside a BPicture. Not working yet. BView::ClipToPicture doesn't work anymore, when nested inside a BPicture, This happened when its implementation was moved server-side.
|
#
2c3505de |
|
16-Mar-2015 |
John Scipione <jscipione@gmail.com> |
PictureDataWriter: Style fixes only No functional change intended
|
#
a6db6bd4 |
|
04-Feb-2014 |
Stephan Aßmus <superstippi@gmx.de> |
Added WIP support for affine transformations to BViews. Everything untested, but compiles, so it must work. The idea is to introduce BAffineTransform additionally to the existing Origin and Scale properties of BViews. One may use it in parallel or as an alternative. Painter in app_server is not yet aware of the additional transformation. It is however already used to transform drawing coordinates. It probably needs to work differently, perhaps only in Painter and AGGTextRenderer.
|
#
efffcb29 |
|
11-Aug-2012 |
Alex Smith <alex@alex-smith.me.uk> |
Better fix for picture data type mismatch. Should use a fixed-size type (int32) rather than a platform-dependent one.
|
#
8752f52d |
|
28-Jul-2009 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added an (empty) destructor. Use a const BRegion (since we can now), honour the 80 column limit. Some comment clarification. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31853 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
18cd67c7 |
|
22-Jan-2009 |
Michael Lotz <mmlr@mlotz.ch> |
Add missing headers (malloc/free, string functions, memcpy, etc. undeclared). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28982 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
b1af0a7a |
|
10-Sep-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Setting the font shear in a BPicture didn't work, because the value was treated as uint32 in some places, when it's a float. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22214 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
46b4e489 |
|
16-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added some debug output to PicturePlayer. Since checking the table size for every op is very slow, now we do that only at the beginning, and use a custom op table if needed. The best case (which is the one used when drawing a picture with BView::DrawPicture()) is very fast since it only requires one check. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21972 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
253d42a6 |
|
14-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented SetClipping op, but it's not working yet (looks like it's never written into the data stream) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21947 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
796e4e45 |
|
13-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implement calling the exit_xxx hooks. Thanks to Marc Flerackers for the help. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21943 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
feb557a6 |
|
14-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented WriteSetFontFamily() and WriteSetFontStyle(). Only the server side functions are missing. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21941 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
37033892 |
|
14-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented SetPattern op. Reduced the buffer size to 4096 again. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21937 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
690c7474 |
|
13-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented BPicture's SetPenLocation() op, also nested AppendToPicture() (but still doesn't work :( ). Moved some functions around in PictureDataWriter.h. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21925 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ed5de868 |
|
13-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented the following BPicture ops: fill region, stroke/fill arc, stroke/fill polygon, stroke/fill bezier. some work towards drawing of nested pictures. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21918 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6f867cc1 |
|
22-Jul-2007 |
Stephan Aßmus <superstippi@gmx.de> |
* rearranged includes git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21683 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
84c2abee |
|
13-May-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Cast errors to status_t before throwing, otherwise the catch operator won't catch them (as ints). Thanks to Ingo and Marcus for pointing out the problem and suggesting a solution. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21133 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
140334f8 |
|
12-May-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added error checking using exceptions git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21112 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4bfa8f22 |
|
03-May-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
completes previous commit. Sorry for breaking the build git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20998 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
a3d758e3 |
|
13-Mar-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added support for font settings in PictureDataWriter. Not used yet git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20381 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0b0ecfab |
|
01-Mar-2007 |
Marcus Overhagen <marcusoverhagen@gmail.com> |
Added "const" to many parameters. Removed most data allocations/copying from PicturePlayer, ServerPicture now has to do this when converting coordinates. Added additional functions to ViewLayer to copy&convert multiple BPoint, BRect, BRegion to Screen coordinates, those should be further optimized. Removed some function call overhead. Note: some functions of PicturePlayer don't appear to be implented by PictureDataWriter, git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20292 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
252f4767 |
|
12-Dec-2006 |
Ryan Leavengood <leavengood@gmail.com> |
Added some needed stdio.h includes. I don't know what magic was used to compile these for other people, but they wouldn't compile for me when building the app_server test environment. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19479 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7022e790 |
|
13-Nov-2006 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
added license git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19269 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
420fe80e |
|
12-Nov-2006 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Moved picture data writing to its own class, thus simplifying code in various places. Implemented SetLineMode op for BPicture, fixed shape drawing (I accidentally broke it in the previous commit). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19264 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ce27f9612e78bbb58c62bdc54c02bfc0e5172681 |
|
05-Sep-2015 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implement ClipToPicture inside a BPicture. Not working yet. BView::ClipToPicture doesn't work anymore, when nested inside a BPicture, This happened when its implementation was moved server-side.
|
#
2c3505de79a59e03adcecef37b9a305d2f80ae49 |
|
16-Mar-2015 |
John Scipione <jscipione@gmail.com> |
PictureDataWriter: Style fixes only No functional change intended
|
#
a6db6bd40fe3492fd3104dba560f0e3ff61d388d |
|
04-Feb-2014 |
Stephan Aßmus <superstippi@gmx.de> |
Added WIP support for affine transformations to BViews. Everything untested, but compiles, so it must work. The idea is to introduce BAffineTransform additionally to the existing Origin and Scale properties of BViews. One may use it in parallel or as an alternative. Painter in app_server is not yet aware of the additional transformation. It is however already used to transform drawing coordinates. It probably needs to work differently, perhaps only in Painter and AGGTextRenderer.
|
#
efffcb292feee3c2db4814d7e414910fe91876d9 |
|
11-Aug-2012 |
Alex Smith <alex@alex-smith.me.uk> |
Better fix for picture data type mismatch. Should use a fixed-size type (int32) rather than a platform-dependent one.
|
#
8752f52d717fdfd88e6dbed22e76eeb2299418db |
|
28-Jul-2009 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added an (empty) destructor. Use a const BRegion (since we can now), honour the 80 column limit. Some comment clarification. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31853 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
18cd67c76072f825c4a7ba58414771d47fd1bfa2 |
|
22-Jan-2009 |
Michael Lotz <mmlr@mlotz.ch> |
Add missing headers (malloc/free, string functions, memcpy, etc. undeclared). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28982 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
b1af0a7a247358c80de46e5400f572d2f00fca3a |
|
10-Sep-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Setting the font shear in a BPicture didn't work, because the value was treated as uint32 in some places, when it's a float. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22214 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
46b4e489982de2e3ddfab11c68c714f6c1be4598 |
|
16-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added some debug output to PicturePlayer. Since checking the table size for every op is very slow, now we do that only at the beginning, and use a custom op table if needed. The best case (which is the one used when drawing a picture with BView::DrawPicture()) is very fast since it only requires one check. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21972 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
253d42a602bc2ed053cf9a5f400bb95070f91da5 |
|
14-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented SetClipping op, but it's not working yet (looks like it's never written into the data stream) git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21947 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
796e4e4552e247113ff540017eb41035f8c70d14 |
|
13-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implement calling the exit_xxx hooks. Thanks to Marc Flerackers for the help. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21943 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
feb557a6d116eef4567aa523d68fc1e7feef378c |
|
14-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented WriteSetFontFamily() and WriteSetFontStyle(). Only the server side functions are missing. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21941 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
37033892c523295d91f189d37ed65474dfac7046 |
|
14-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented SetPattern op. Reduced the buffer size to 4096 again. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21937 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
690c7474a4d9597b5deceeaa4b582f2b2a6baaaf |
|
13-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented BPicture's SetPenLocation() op, also nested AppendToPicture() (but still doesn't work :( ). Moved some functions around in PictureDataWriter.h. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21925 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
ed5de868df775fceddb5abedec7eab9bd5147d51 |
|
13-Aug-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Implemented the following BPicture ops: fill region, stroke/fill arc, stroke/fill polygon, stroke/fill bezier. some work towards drawing of nested pictures. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21918 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
6f867cc1de003a908172cffccb0caf6a4baee65d |
|
22-Jul-2007 |
Stephan Aßmus <superstippi@gmx.de> |
* rearranged includes git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21683 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
84c2abee9457d79d9db8abf4dfb0b5d541269c52 |
|
13-May-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Cast errors to status_t before throwing, otherwise the catch operator won't catch them (as ints). Thanks to Ingo and Marcus for pointing out the problem and suggesting a solution. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21133 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
140334f858c7c02f3187b668dd2b79dbc2580efa |
|
12-May-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added error checking using exceptions git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21112 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
4bfa8f22dfda8b6eeae58696cf5a1dfe779ff00c |
|
03-May-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
completes previous commit. Sorry for breaking the build git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20998 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
a3d758e3690cd335fb1afcd5b4d4c1c67def045a |
|
13-Mar-2007 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Added support for font settings in PictureDataWriter. Not used yet git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20381 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
0b0ecfab9004dab03fc2cdc6b0d1bc01fd4336af |
|
01-Mar-2007 |
Marcus Overhagen <marcusoverhagen@gmail.com> |
Added "const" to many parameters. Removed most data allocations/copying from PicturePlayer, ServerPicture now has to do this when converting coordinates. Added additional functions to ViewLayer to copy&convert multiple BPoint, BRect, BRegion to Screen coordinates, those should be further optimized. Removed some function call overhead. Note: some functions of PicturePlayer don't appear to be implented by PictureDataWriter, git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20292 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
252f4767828ef4564f9fcedca981234e26e7bd32 |
|
12-Dec-2006 |
Ryan Leavengood <leavengood@gmail.com> |
Added some needed stdio.h includes. I don't know what magic was used to compile these for other people, but they wouldn't compile for me when building the app_server test environment. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19479 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
7022e7903acfbe57d3665c177f015a44afcdac76 |
|
13-Nov-2006 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
added license git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19269 a95241bf-73f2-0310-859d-f6bbb57e9c96
|
#
420fe80e5c3dc9765da5343c511071d63bcb81cb |
|
12-Nov-2006 |
Stefano Ceccherini <stefano.ceccherini@gmail.com> |
Moved picture data writing to its own class, thus simplifying code in various places. Implemented SetLineMode op for BPicture, fixed shape drawing (I accidentally broke it in the previous commit). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@19264 a95241bf-73f2-0310-859d-f6bbb57e9c96
|