view

An example to demonstrate the ForgeJS ability to handle any kind of panoramic-image size through multiresolution image processing.

configuration.json

{
    "controllers":
    {
        "instances":
        [
            {
                "uid": "pointer",
                "type": "pointer",
                "options":
                {
                    "zoom": { "toPointer": true }
                }
            }
        ]
    },

    "story":
    {
        "uid": "multiresolution-story",
        "name": "Multiresolution Story",
        "slug": "multiresolution-story",
        "description": "This project display multiresolution panoramic images",
        "default": "scene-0",

        "scenes":
        [
            {
                "uid": "scene-0",
                "name": "Galoppaz",
                "slug": "galoppaz",
                "description": "Partial multiresolution panoramic image from summit of the Galoppaz",

                "camera":
                {
                    "fov":
                    {
                        "max": 39
                    },

                    "yaw":
                    {
                        "min": -126.5,
                        "max":  126.5
                    },

                    "pitch":
                    {
                        "min": -27.6,
                        "max": 11.6
                    }
                },

                "media":
                {
                    "uid": "media-0",
                    "type": "image",

                    "preview":
                    {
                        "url": "https://cdn.forgejs.org/samples/multiresolution/galoppaz/preview/{face}.jpg",
                        "tile": 1024
                    },

                    "source":
                    {
                        "format": "cube",

                        "faces":
                        {
                            "front": 0,
                            "right": 1,
                            "back": 2,
                            "left": 3,
                            "down": 4,
                            "up": 5
                        },

                        "pattern": "https://cdn.forgejs.org/samples/multiresolution/galoppaz/{face}/{level}/{y}/{x}.jpg",

                        "levels":
                         [
                            {
                                "name": "level 0",
                                "width": 6656,
                                "height": 6656,
                                "tile": 512,
                                "pattern": "https://cdn.forgejs.org/samples/multiresolution/galoppaz/{face}/{level}/{y}_{x}.jpg"
                            },

                            {
                                "name": "level 1",
                                "width": 12800,
                                "height": 12800,
                                "tile": 512
                            },

                            {
                                "name": "level 2",
                                "width": 25600,
                                "height": 25600,
                                "tile": 512
                            },

                            {
                               "name": "level 3",
                                "width": 51200,
                                "height": 51200,
                                "tile": 512
                            }
                        ]
                    }
                }
            },

            {
                "uid": "scene-1",
                "name": "House Interior",
                "slug": "house-interior",
                "description": "Saint Jorioz's house interior",

                "camera":
                {
                    "fov":
                    {
                        "default": 95,
                        "min": 30,
                        "max": 100
                    }
                },

                "media":
                {
                    "uid": "media-1",
                    "type": "image",

                    "preview":
                    {
                        "url": "https://cdn.forgejs.org/samples/multiresolution/house/preview/{face}.jpg",
                        "tile": 512
                    },

                    "source":
                    {
                        "format": "cube",

                        "faces":
                        {
                            "front": 0,
                            "right": 1,
                            "back": 2,
                            "left": 3,
                            "down": 5,
                            "up": 4
                        },

                        "pattern": "https://cdn.forgejs.org/samples/multiresolution/house/{face}/{level}/{y}_{x}.jpg",

                        "levels":
                        [
                            {
                                "name": "level 0",
                                "width": 1024,
                                "height": 1024,
                                "tile": 512
                            },

                            {
                                "name": "level 1",
                                "width": 2048,
                                "height": 2048,
                                "tile": 512
                            },

                            {
                                "name": "level 2",
                                "width": 3584,
                                "height": 3584,
                                "tile": 512
                            }
                        ]
                    }
                }
            }
        ]
    },

    "plugins":
    {
        "prefix": "../../plugins/",

        "engines":
        [
            {
                "uid": "org.forgejs.previousnextbuttons",
                "url": "PreviousNextButtons/"
            },

            {
                "uid": "org.forgejs.share",
                "url": "Share/"
            }
        ],

        "instances":
        [
            {
                "uid": "previousnextbuttons",
                "engine": "org.forgejs.previousnextbuttons"
            },

            {
                "uid": "share",
                "engine": "org.forgejs.share",
                "options":
                {
                    "format": "normal",
                    "precision": 3
                }
            }
        ]
    }
}

Back to samples

24th Oct 2017