Get your own customer support community

Recent activity

Subscribe to this feed
  • question

    anthony.ali asked a question in Microsoft Live Labs on October 30, 2009 22:45:

    anthony.ali
    Does the Deep Zoom Composer retain ICC Color Profiles?
    Hi All,

    I was talking to a colleague today who happened to mention ICC color profiles - which you have been able to retain from saving for web from Photoshop since at least Photoshop 7.

    As I have been working with Sea Dragon and Deep Zoom recently, I was wondering if this information is retained when putting the images through the Deep Zoom Composer.

    Many Thanks

    Anthony
  • star

    Daniel Gasienica's reply to "Adding Panning Controls to Seadragon Ajax" was just promoted to the most useful! anthony.ali and 2 other people think it's one of the best replies.

    Daniel Gasienica
    Anthony,

    I'm not sure what's going wrong in your example but I quickly put together one that I actually tested and which seems to work. I posted the code to jsbin as it was all scrambled here:

    Example
    http://jsbin.com/akeni

    View Source
    http://jsbin.com/akeni/edit#html

    Feel free to ask me if you have any questions.

    Cheers,
    Daniel
  • question

    anthony.ali replied on October 30, 2009 13:20 to the question "Adding Panning Controls to Seadragon Ajax" in Microsoft Live Labs:

    anthony.ali
    Hi Daniel,

    Sorry it has taken me a couple of days to get back to you.

    I have managed to get this working as individual buttons.

    My code is as follows (might be handy for reference for anyone who stumbles upon this topic)


    var viewer = null;

    function init() {
    viewer = new Seadragon.Viewer("seadragon");
    viewer.openDzi("/radio4/anthony_ali/ahow/2500/GeneratedImages/dzc_output.xml");

    viewer.addControl(panRightButton(), Seadragon.ControlAnchor.NONE);
    viewer.addControl(panLeftButton(), Seadragon.ControlAnchor.NONE);
    viewer.addControl(panUpButton(), Seadragon.ControlAnchor.NONE);
    viewer.addControl(panDownButton(), Seadragon.ControlAnchor.NONE);
    }

    function panRightButton() {
    var control = document.createElement("a");
    var controlText = document.createTextNode("Right");

    control.href = "#"; // so browser shows it as link
    control.className = "buttonright";
    control.appendChild(controlText);

    Seadragon.Utils.addEvent(control, "click", onPanRight);
    return control;

    }
    function panLeftButton() {
    var control = document.createElement("a");
    var controlText = document.createTextNode("Left");

    control.href = "#"; // so browser shows it as link
    control.className = "buttonleft";
    control.appendChild(controlText);

    Seadragon.Utils.addEvent(control, "click", onPanLeft);
    return control;

    }
    function panUpButton() {
    var control = document.createElement("a");
    var controlText = document.createTextNode("Up");

    control.href = "#"; // so browser shows it as link
    control.className = "buttonup";
    control.appendChild(controlText);

    Seadragon.Utils.addEvent(control, "click", onPanUp);
    return control;

    }
    function panDownButton() {
    var control = document.createElement("a");
    var controlText = document.createTextNode("Down");

    control.href = "#"; // so browser shows it as link
    control.className = "buttondown";
    control.appendChild(controlText);

    Seadragon.Utils.addEvent(control, "click", onPanDown);
    return control;

    }

    var PAN_DISTANCE = 0.1;

    function onPanLeft(event) {
    viewer.viewport.panBy(new Seadragon.Point(-PAN_DISTANCE, 0));
    }

    function onPanRight(event) {
    viewer.viewport.panBy(new Seadragon.Point(PAN_DISTANCE, 0));
    }

    function onPanUp(event) {
    viewer.viewport.panBy(new Seadragon.Point(0, -PAN_DISTANCE));
    }
    function onPanDown(event) {
    viewer.viewport.panBy(new Seadragon.Point(0, PAN_DISTANCE));
    }
    Seadragon.Utils.addEvent(window, "load", init);


    The elements themselves are then styled and positioned using CSS, and have been position in alignment with the default navigation struture.

    Thanks again for your help.

    Anthony
  • question

    anthony.ali replied on October 28, 2009 16:38 to the question "Why zoom to more than 100%?" in Microsoft Live Labs:

    anthony.ali
    Hi Malcolm,

    I haven't found a way of limiting this inside of DZC itself - other than making the image invisible once you hit maximum - but that is a little cumbersome.

    However, if you are using Seadragon Ajax you can limit this inside of the seadragon library.

    On line 8 you will see find the following:


    maxZoomPixelRatio:4



    This sets the maximum zoom level to four times the actual size of the image, you can change this to 1 times simpyl with the following code



    maxZoomPixelRatio:1



    Thanks

    Anthony
  • question

    anthony.ali replied on October 28, 2009 16:32 to the question "Adding Panning Controls to Seadragon Ajax" in Microsoft Live Labs:

    anthony.ali
    Hi Daniel,

    Thanks for getting back to me.

    I have followed the information above, and have been able to do the following.

    Create a custom control - which appears and can be styled independently.

    The second part is what is getting me somewhat baffled.

    While I have followed your example i cannot get my new button to process my action as defined in the javascript see below:


    function Right() {
    var control = document.createElement("a");
    var controlText = document.createTextNode("Right");

    control.href = "#"; // so browser shows it as link
    control.className = "right";
    control.appendChild(controlText);

    Seadragon.Utils.addEvent(control, "click", onRight);
    return control;

    }
    function onRight(event) {
    viewer.viewport.panBy(new Seadragon.Point(0.1, 0));

    }


    I have checked (using an alert) that when my button is pressed that it actually makes a call to the onRight fuction.

    But it wont pan across to the right.

    Any ideas?

    Thanks

    Anthony
  • question

    anthony.ali asked a question in Microsoft Live Labs on October 26, 2009 14:43:

    anthony.ali
    Adding Panning Controls to Seadragon Ajax
    Hi,

    I'd like to be able to add panning controls for left, right, up and down to seadragon ajax.

    Any pointers are greatly appreciated.

    Anthony