Grant Echols
be79249c9c
Added pre-draw event for tiles to allow applications to alter the image just prior to its rendering. This should enable invert, brightness, contrast, sharpen and other transformations to occur naturally through the 'tile-drawing' event listener.
...
The listener is given the 'rendered' object which is the pre-drawn image on a canvas context object. By altering the 'rendered' object the listener can alter the display results. Since this event gets fired multiple times for the tile, it is wise for the handler to track what their desired modifications are and to tag the 'tile' element to keep track of the modifications already applied.
2014-02-27 15:35:00 -07:00
Antoine Vandecreme
365dad9317
Move all overlay code from drawer to viewer
2014-01-30 15:38:37 -05:00
Sean Wilkinson
a5a72ee321
Set image.crossOrigin = 'Anonymous';
to avoid tainted canvas problem
2013-12-11 19:31:35 -06:00
Antoine Vandecreme
0c2af6550a
Add support to add/remove layers and change their levels.
2013-12-09 09:26:36 -05:00
Mark Salsbery
930e8c4dfd
Updated Doclets
2013-11-25 08:48:44 -08:00
Mark Salsbery
ece76925a6
Updated Doclets
...
Lots of changes, most notably event documentation (@event and @fires)
2013-11-21 12:19:07 -08:00
Mark Salsbery
54049927f0
Updated doclets
...
Changed event docs:
Changed userData properties from optional to nullable.
Removed optional type from preventDefaultAction properties.
2013-11-18 06:56:32 -08:00
Mark Salsbery
70b91d57ec
Updated doclets for jsdoc3
...
Updated so jsdoc3 parser picks everything up.
Added event docs.
Lots of documentation content needed...
2013-11-15 22:19:53 -08:00
Mark Salsbery
5c4131303a
Use canvas when available - Fixes
...
Removed redundant useCanvas property from drawer
2013-11-07 11:48:01 -08:00
Mark Salsbery
085c7f2ecb
Use canvas when available - Fixes
...
Updated documentation doclet.
Enclosed detection code in a function.
Eliminated the Drawer USE_CANVAS global and replaced it with a
Drawer.useCanvas instance variable.
2013-11-01 13:02:28 -07:00
Mark Salsbery
e209846ac1
Use canvas whenever possible ( #191 )
...
Drawer uses an HTML5 canvas element if it's available.
Viewer.useCanvas can be used to override (default is true).
2013-11-01 10:19:47 -07:00
Antoine Vandecreme
4cd98a5da9
Check hash in viewer constructor.
...
Fix #229
Fix #176
2013-10-12 18:30:05 -04:00
Mark Salsbery
d574700b3d
Event Handler Signatures Changed to 'fn(event)'
...
All event handler signatures changed to 'fn(event)'
eventSource property added to the event object passed
Redundant event source properties removed ('button' and 'viewer'
Documentation updated in MouseTracker
changelog.txt updated
2013-10-10 17:00:15 -07:00
iangilman
aefe7f3610
Merge pull request #185 from robhobbes/master
...
Adding partial support for rotation.
2013-08-20 11:08:58 -07:00
Robert Hickman
767c897e7f
Revisions to rotate after second code review.
2013-08-16 11:32:21 -06:00
Robert Hickman
54e8d8c43f
Fixes made after first code review of rotation.
2013-08-15 16:15:20 -06:00
Ian Gilman
6669589e5e
Drawer now works when the page is rtl
2013-08-15 12:54:32 -07:00
Robert Hickman
6c63710131
Rotating overlays.
2013-08-14 13:43:49 -06:00
Robert Hickman
b9583c43ac
Working on rotating images.
...
So far only 90 degree rotation is supported.
Only the image is currently being rotated.
Overlays, debugger, and the navigator still need to be updated to support rotation.
2013-08-13 16:32:04 -06:00
Luke Murray
2717398181
Use the correct onDraw in drawer.js. Remove imageFullSize and fix up the comment for onDraw
2013-08-01 13:36:00 +10:00
Luke Murray
4239bb7adc
fix: remove the useTransform/SVG stuff and move back to a simple onDraw callback only so people can handle their own custom drawing and sizing
2013-07-31 17:01:48 +10:00
Luke Murray
df877493a9
Rename drawHandler to onDraw. Also make it a notification style callback
...
(does not override the draw functionality).
Add an overlay option 'useTransform' that will transform the overlay
element instead of moving it's postion - useful for SVG elements
2013-07-16 12:04:37 +10:00
Luke Murray
233c3a357a
Add the option for a zoom handler callback
2013-07-12 16:51:56 +10:00
iangilman
8fe0ce26b8
Merge pull request #136 from acdha/jshint-cleanup
...
JSHint tidying
2013-06-26 09:37:08 -07:00
Ian Gilman
3f1072b321
Fixed typos in comments
2013-06-26 09:15:37 -07:00
Chris Adams
c648c1df8a
drawer: don't leak drawLevel into global namespace
...
This code is still under-tested and documented but no longer relies on
`drawLevel` being leaked into the global namespace where `updateLevel`
to find it.
See #145
2013-06-25 14:26:09 -04:00
Kevin Ewing
248852c15f
Implementing OpenSeadragon.now()
...
Replacing both `+new Date()` and `new Date().getTime()` with `$.now()`
2013-06-20 13:15:04 -07:00
Chris Adams
e2bea810e3
Replace gnarly ternary expression with if statement
2013-06-20 15:12:53 -04:00
Chris Adams
643ee211ca
Remove unused variables
...
Mostly unused function arguments but there were also a fair number
of legacy names which are now no longer used.
One question which comes up – mostly in tilesource.js – is whether
there is any value in leaving unused variables for functions which
are intended to be overridden anyway. I'm inclined to say that the
docs + tests need to be sufficient as there's no enforcement that
whatever is in the base implementation will actually be followed by
any of the real functions.
2013-06-20 15:12:53 -04:00
Chris Adams
9f6f164d9f
Remove all whitespace
...
The results of running this command::
find . -name \*.js -print0 | xargs -0 perl -p -i -e "s|[ \t]+$||"
(Split from #136 )
2013-06-19 13:33:27 -04:00
Ian Gilman
1d51b72785
Fixed blendTile()-related blurriness issue
...
We were setting drawer.updateAgain to the result of each blendTile(),
which meant it was keeping only the last result. Instead we should have
been only setting it to true if blendTile returned true, but never
setting it to false. Fixed.
2013-05-29 11:18:25 -07:00
Benjamin Gilbert
fa1a8b2dde
Fix Drawer event emission
...
Drawer tries to emit events on the parent Viewer object but doesn't have
a reference to it. Add a reference when constructing the Drawer.
2013-05-16 02:49:29 -04:00
iangilman
0b366d7b42
Merge pull request #89 from bgilbert/license
...
Revert to original New BSD license; clean up license declarations
2013-05-14 09:15:00 -07:00
Benjamin Gilbert
fcc119bb84
Add file-specific descriptions to file headers
2013-05-14 00:00:24 -04:00
Benjamin Gilbert
17a6ee15b1
Include 2010 in "OpenSeadragon contributors" copyright dates
...
This Git repository starts in 2011, but the CodePlex Mercurial repository
has commits from 2010.
2013-05-13 23:32:09 -04:00
Benjamin Gilbert
522bcbf058
Add addClass()/removeClass() utility functions
2013-05-12 22:53:41 -04:00
Benjamin Gilbert
2f2eba8df2
Add "OpenSeadragon contributors" copyright statement
...
The license text will be provided on the website, etc., and it seems
strange to list no copyright date newer than the original CodePlex
copyright from the AJAX Control Toolkit. Add a blanket copyright
statement for contributions to the OpenSeadragon project, stating that
copyright is held by the authors of each contribution. This blanket
statement is not intended to preclude individual contributors from
attaching their own copyright statements to their modifications.
2013-05-12 17:12:26 -04:00
Ian Gilman
c6f8b5e192
Fixed broken viewer.raiseEvent calls in drawer.js
2013-05-10 11:32:22 -07:00
Benjamin Gilbert
be20645876
Add BSD license block and CodePlex copyright to each source file
...
See discussion in #10 .
2013-05-10 00:16:55 -04:00
thatcher
f0c7870f4e
cleaning up new setting as applied to collections
2013-03-14 07:22:26 -04:00
thatcher
b9741daaaf
removing debug console log statement per ventero's review notes
2013-03-14 07:22:26 -04:00
thatcher
86e27c18f7
what was initally a feature branch to work on just canvas prerender, evolved into a feature branch focused on broader ideas discussed in issue #4 - I've basically been able to reduce time spent in drawTile by half. good stuff, thanks to dustmoo for getting us looking into this
2013-03-14 07:22:26 -04:00
thatcher
2be165fa70
niave implementation of prerender for canvas, the first optimization discussed here: http://www.html5rocks.com/en/tutorials/canvas/performance/
2013-03-14 07:22:25 -04:00
thatcher
5b6a2f5873
basic implementation of issue #2
2013-02-28 15:55:24 -05:00
Ian Gilman
9569ff1215
Removed JS Hint globals comment, since it's now in grunt
2013-02-14 12:04:47 -08:00
thatcher
fda24f343a
added dozens of event hooks based on input from macreery's branch
2013-02-13 19:44:23 -05:00
thatcher
d8a3ccf5e8
dont compute NaN for opacity because FF doesnt like that, per macreery's branch, thanks
2013-02-13 17:20:05 -05:00
thatcher
0540e834b4
refactoring after lint left an error related to drawer and overlays
2013-02-13 09:05:35 -05:00
thatcher
a0fd2b3324
added inital support for moving to a nodejs build with grunt. build only includes concant and lint. fixed all lint warning where appropriate and added lint inline ignores where appropriate. when build script is complete we will start transition to new repo. also currently researching how to prune unfriendly portion of history that make repo large due to large binary files in web app. I like git well enough but using branches for web apps unrelated to code base has made me weary once again of social web fads that force convention without long term consideration of cost.
2013-02-12 22:40:08 -05:00
thatcher
855e753225
some overlays work that had be be completed before finishing tile layers. added brief example of how to how host tiles of zoom.it
2013-02-10 22:53:51 -05:00
thatcher
3f20018c75
correction for recent change which computed a highestLevel for drawer with max instead of min operation
2013-02-09 12:21:51 -05:00
thatcher
576c00b37d
adding support for several new tile sources including iiif, osm and tms (osm and tms are thanks to seajax-utils project)
2013-02-08 09:21:28 -05:00
thatcher
b1cdaaa845
found an IE specific error in some styles set for collections visualizations
2013-02-01 15:35:46 -05:00
thatcher
f863f5fcae
changing drawHTML routine to avoid ie rendering issue
2013-02-01 15:18:53 -05:00
thatcher
bd135904b6
Merge branch 'master' of github.com:thatcher/openseadragon
2013-01-31 12:30:36 -05:00
thatcher
6efc348b8a
finished collection support for html drawers
2013-01-31 12:30:13 -05:00
Ian Gilman
527682d5a6
Merge branch 'master' into lint
...
Fixed Conflicts:
openseadragon.js
src/drawer.js
2013-01-31 09:26:55 -08:00
thatcher
063bce8171
fixing some work in progress for collections visualizations
2013-01-30 20:23:45 -05:00
thatcher
9fc4388ac9
Merge branch 'master' of github.com:thatcher/openseadragon
2013-01-30 16:51:46 -05:00
thatcher
f6ee93b70c
improving custom tile source examples are work for layers begins being supported
2013-01-30 16:51:37 -05:00
Ian Gilman
7a55b6cf77
JS Hint work (mostly semicolons at this point)
2013-01-29 09:32:58 -08:00
Ian Gilman
624fbd97b9
Comment typo
2013-01-28 10:24:13 -08:00
iangilman
d23851d5e5
Merge pull request #15 from Ventero/imageload
...
Pass the correct object to image load callbacks.
2013-01-28 10:21:36 -08:00
Ventero
8f085c83ca
Update documentation for Drawer#loadImage.
...
Additionally, improve name of the parameter passed to the complete
listener.
2013-01-25 20:36:41 +01:00
thatcher
15c35c93fd
0.9.90 adds support for a debug mode and real heterogeneous collection visualizations. straight html div/image support for both features is in process but incomplete
2013-01-23 23:00:11 -05:00
Ventero
bb0ac1f9d1
Pass the correct object to image load callbacks.
...
Previously, the image object was passed on to onTileLoad regardless
if it loaded successfully or not. In case an image failed to load,
this would result in trying to draw a non-existing image onto the
canvas, which (at least in Firefox) throws a DOM exception and results
in the drawer being stuck mid-update.
2012-09-29 12:31:51 +02:00
Ventero
5c74c7b415
Always clear the image load timeout job.
2012-09-29 12:31:46 +02:00
thatcher
e7785fe636
found error related to minPixelWidth being set incorrectly for navigator and image reference strip so it loaded too many level which hurt performance
2012-09-07 08:55:19 -04:00
thatcher
c41f6a464e
Substantial rework of TileSource and Viewer.openTileSource to allow simpler introspect of the intended TileSource implementation based on the configuration object details. Also major www updates to simplify and unify the informational site by building it via simple templates. Improved examples and documentation. Added support for xml, json, jsonp, and inline configuration of supported tile sources.
2012-06-05 07:52:00 -04:00
thatcher
e595ad2381
Adding ability to bind to buttons to custom interface elements, also use screen size detection to avoid using canvas on small devices since is more cpu intensive. Added version check for IE specific implementations to avoid using them for IE 9 and made most IE implementation differences a one-time process instead of an if/else which is evaulated on every call to the function.
2012-04-10 17:02:24 -04:00
thatcher
05f3c1d811
several bug fixes and enhancements. legacy tile source issue discovered and corrected for images with width greater than height. adding basic support for sequenced tile sources including previous and next buttons. added mouse drag and scroll interactions for viewport navigator.
2012-04-03 03:08:27 -04:00
thatcher
2e821a7dc6
IE specific patches
2012-03-20 15:00:25 -04:00
thatcher
10a0db14f7
thanks to josh1093 for finally translating the typo I couldn't make sense of when refactoring. 1 less TODO in the code base, thanks josh.
2012-03-20 03:38:27 -04:00
thatcher
6443d57e09
corrected major performance issue discovered in navigator becuase minPixelRatio was set to Zero. This caused images to be loaded ad infinitum in the navigator, oops.
2012-03-19 19:03:58 -04:00
thatcher
ddaddb7f42
keyboard accessibile buttons finally
2012-03-16 11:36:28 -04:00
thatcher
3f6e8abbfc
Significant improvments to API documentation. Allow what was an object literal OpenSeadragon to be used a function which provides a simplified interface for constructing a Viewer and TileSource by simple, documented configuration settings. Major performance improvements for touch on iPhone, hopefully all mobile devices.
2012-03-01 08:38:15 -05:00
thatcher
1a7c96732f
Fixed issued that caused flicker when using the new LegacyTileSource! Also improves performance for dzi's and other tiled images since the issue was actually in the Drawer and a result of a mistake during the refactor. This is awesome imho! Please check out the new example page to see it in action.
2012-02-23 07:18:28 -05:00
thatcher
ec77bb2a78
finally managed to clean up MouseTracker, actually uses the prototype pattern. probably too many public methods but that can be cleaned up later.
2012-02-01 16:56:04 -05:00
thatcher
5cba11c91c
replaced all references of elmt with element ( or Elmt with Element )
2012-01-31 21:01:37 -05:00
thatcher
2410b01943
finsihed removing psuedo private methods from Drawer and added many jsdoc strings, labeled 0.8.26
2012-01-31 15:59:09 -05:00
thatcher
012255d622
added jsdoc some files to project, added 'doc' task to build, started to annotate code with docs
2012-01-25 14:14:02 -05:00
thatcher
0b09cc8859
found some variables leaked globally in viewer.js - continued very minor formatting clean up in preperation of adding docs
2012-01-24 08:03:50 -05:00
thatcher
a8730a9f00
mostly superficial formating. removing $.Strings and putting it directly in $. more clean up of the Drawer update related functions
2012-01-23 22:48:45 -05:00
thatcher
bc50a7df04
finally managed to untie the knot that was Drawer _updateActual. incremented build to 0.8.20
2012-01-18 21:52:22 -05:00
thatcher
f325804ff6
work-in-progress refactor of Drawer.prototype._updateActual
2012-01-18 20:15:54 -05:00
thatcher
d38bc75180
moved all functions in OpenSeadragon.Utils to OpenSeadragon object literal to remove 'utility' anti-pattern. removed src/utils.js from build and deleted physical file. added important TODO notes to avoid overhead from browser vendor/version checks in functions, defining them once instead. incremented build id to 0.8.18
2012-01-17 18:30:41 -05:00
thatcher
8424c78c4b
renamed psuedo-private accessor _getNumTiles to actual private numberOfTiles
2012-01-11 18:32:17 -05:00
thatcher
c8b4197f79
removed duplicate definition of Drawer.prototype._compareTiles
2012-01-11 18:25:35 -05:00
thatcher
0041e32cbb
removed all psuedo-private properties from Drawer instance in favor of direct access.
2012-01-11 18:22:13 -05:00
thatcher
dc841a6294
commented out unreported profiling code. removed psuedo private properties and accessors of Profiler preferring direct property access. will eventuall reconnect profiler via AOP and include 'profile' option in Viewer which is false by default
2011-12-29 17:14:42 -05:00
thatcher
d145c129a0
removed null method Drawer.prototype.idle
2011-12-27 18:20:45 -05:00
thatcher
8ba072a1a9
removed ImageLoader abstraction (loadImage is noe method of Drawer) since its constructor was only called once and the resulting object was kept psuedo-private.
2011-12-27 18:17:24 -05:00
thatcher
9b5cf799bf
removed _init anti-pattern from drawer constructor
2011-12-13 18:01:43 -05:00
thatcher
916ada5f02
Added simple ant build. Broke main file into composite parts in src directory. Concatenated release is still included in the project as a release artifact.
2011-12-05 22:50:25 -05:00