summaryrefslogtreecommitdiff
path: root/src/Fl_Tiled_Image.cxx
AgeCommit message (Collapse)Author
44 hourswipmaxim nikonov
2023-01-08 Fix "Xrender blurs adjacent images with bilinear scaling" (#633)ManoloFLTK
Many thanks to @wcout for providing this fix. Xrender now draws images in the same way when tiling images or not when FL_RGB_SCALING_BILINEAR is on. This allows to remove static bool Fl_Tiled_Image::drawing_tiled_image() which becomes unused.
2022-08-10Fix Fl_Xlib_Graphics_Driver for drawing tiled images.ManoloFLTK
Conflicting demands arise in the implementation of class Fl_Xlib_Graphics_Driver for drawing images with the XRender library : 1) Issue #163 leads to use a bilinear filter to draw-and-scale images. 2) This tends to blur the edges of drawn areas which is bad for tiled images (that is because the edges get alpha values, even for an opaque source image). This commit resolves the conflict adding a means to detect whether the library is busy drawing a tiled image. If so, the bilinear filter is not applied, drawn areas don't have blurred edges, resulting in a nice tiling. With this commit, these test apps perform correctly: - tiled_image is correct at all scaling factor values also when modified to use a depth-3 or a depth-4 Fl_RGB_Image as tile; - unittests - Drawing Images is correct at all scaling factor values; - pixmap_browser scales correctly up and down JPEG and PNG images.
2022-06-20Fix issue #427 - 2nd partManoloFLTK
Fix Fl_Tiled_Image made from scaled source image. Fix Fl_Shared_Image::update() to allow scaled source image. Correct handling of default value (-1) of 3rd argument of 3-argument Fl_BMP_Image constructor.
2022-04-13Make Fl_Image::copy() 'const', including all derived classesAlbrecht Schlosser
Copying an image does not (and must not) change the original object, hence copy() should always be 'const'. This is *necessary* if the given Fl_Image object is 'const'.
2022-03-20Fix Fl_Tiled_Image::copy(int W, int H)Albrecht Schlosser
Remove false "optimization" that would return the same pointer if the requested width and height are the same. Note: copy() must always return a new image (this is the expected behavior of copy). Otherwise deleting one of the objects (either the source or the copy) would delete the other one as well.
2020-09-01Fix issue with Fl_Tiled_Image: did not correctly drawfire-eggs
... to sub-region of widget. Original patch (PR #114) modified by Albrecht-S: - fixed whitespace - removed modifications of test/unittest_images.cxx
2020-07-06Remove $Id$ tags, update URL's, and moreAlbrecht Schlosser
- remove obsolete svn '$Id$' tags from all source files - update .fl files and generated files accordingly - replace 'http://www.fltk.org' URL's with 'https://...' - replace bug report URL 'str.php' with 'bugs.php' - remove trailing whitespace - fix other whitespace errors flagged by Git - add and/or fix missing or wrong standard headers - convert tabs to spaces in all source files The only relevant code changes are in the fluid/ folder where some .fl files and other source files were used to generate the '$Id' headers and footers.
2015-03-02Fix an error and improve documentation of Fl_Tiled_Image.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10602 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-03-01Improve Fl_Tiled_Image drawing, scheme background setup, and documentation.Albrecht Schlosser
Fl::scheme("plastic") now correctly sets the background image width and height to 0, which causes the background image to fill the whole window. Fl_Tiled_Image drawing was partly broken. Offsets (cx, cy) were not used correctly, and some other inconsistencies with arguments were possible. Drawing has been optimized to draw only those tiles that are not clipped. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10598 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2014-07-10Fix for STR #3106: a tiled image could fail if the size of the tiled surface ↵Manolo Gouy
exceeded the size of the main screen. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10218 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-07-19Modifications to all LGPL headers for STR #2685.Greg Ercolano
(to clarify static exception LGPL by changing license references) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8864 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2010-11-28Fixed Copyright to 2010.Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7903 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-01-01Changed Copyright in 'src' directoryMatthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6616 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-12-06Replaced all occurrences of the deprecated fl_clip() function byAlbrecht Schlosser
fl_push_clip(). git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6551 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-16Doxygen documentation : took the opportunity to update copyright info as we ↵Fabien Costantini
modified already in batch almost all sources, added also a fil doxygen command to class headers to harmonize with original matt Fl_Widget dox. format. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6265 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-15Doxygen documentation WP11 Done!Fabien Costantini
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6255 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-04-16Update source file headers with STR web page.Michael R Sweet
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4288 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2005-02-24Copyright updates.Michael R Sweet
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4052 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2004-04-11Copyright updates and prep for 1.1.5rc1.Michael R Sweet
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3391 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2003-01-30Copyright update for 1.1.3 release (not quite yet, but soon...)Michael R Sweet
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2936 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2002-01-01Copyright updates...Michael R Sweet
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1903 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-12-19Multiple bug fixes from Sebastien:Michael R Sweet
- Fl_GIF_Image and Fl_PNG_Image didn't close the file before calling Fl::error(). - Fl_Help_View didn't clear the line array in Fl_Help_Block, and Fl_Help_Block::font and ::size were not used. - Fl_Shared_Image::get() didn't return NULL if the image could not be loaded. - Switched to more efficient code for Fl_Tiled_Image::color_average() and ::desaturate(). - Don't delete children in Fl_Text_Display since the group will do it. - Fixes to filename_isdir(), filename_absolute(), and filename_relative(). - Was using numbers instead of define constants for some OpenGL stuff under WIN32. - Wasn't exporting threading functions under WIN32. - The Fl_Widget destructor now removes from the parent to avoid a Purify error since the old widget would be referenced by the parent when it was destroyed; this has no apparent performance impact since Fl_Group::clear() sets children_ to 0, making Fl_Group::remove() very fast... - WIN32 font enumeration datatype fixes... git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1878 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-12-11Multiple fixes from Sebastien.Michael R Sweet
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1833 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-12-06Use FL_NO_BOX for check button and round button.Michael R Sweet
Clip Fl_Tiled_Image to the bounding box. Draw Fl_Progress using the box. Draw plastic box types right for narrow (but horizontal buttons) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1814 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2001-11-24Added XBM, XPM, and PNM image file classes.Michael R Sweet
The pixmap_browser demo now supports all image formats via Fl_Shared_Image. Dropped image file stuff from image demo. Added Fl_Tiled_Image class, which tiles an Fl_Image, useful for tiling a background image in groups. Added tiled_image demo. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1725 ea41ed52-d2ee-0310-a9c1-e6b18d33e121