question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ImageLayer+ImageStatic does not render on Chrome/Chromium

See original GitHub issue

Describe the bug Firefox displays ImageLayers ok, but Chrome/Chromium doesn’t display them at all.

To Reproduce Steps to reproduce the behavior:

  1. With firefox go to http://coe-maps-dev.s3-website-eu-west-1.amazonaws.com/
  2. With Chrome go to http://coe-maps-dev.s3-website-eu-west-1.amazonaws.com/
  3. See png background in firefox, but all-blue background in chrome.

Expected behavior ImageLayer to render in all browsers.

Source

Simplified excerpt from source that still fails:

import ImageLayer from 'ol/layer/Image'
import Map from 'ol/Map'
import ImageStatic from 'ol/source/ImageStatic'
import View from 'ol/View'

const layers = [
    new ImageLayer({
        source: new ImageStatic({
            imageExtent: [-740, -1360, 860, 1640],
            url: './Selene-4.png',
        }),
    }),
]

const map = new Map({
    layers,
    target: 'map',
    view: new View({
        center: [0, 0],
        extent: [ -2880, -2880, 2880, 2880 ],
        zoom: 0,
    }),
})

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
mike-000commented, Nov 5, 2019

The problem seems to be related to the size of the image you are using. If I reduce it from 6400 x 12000 to 4800 x 9000 px it works. There are also issues when using very large tiles (5000 x 5000) in OL6 with Chrome - about 20% of tiles fail to render but there is no error.

0reactions
stale[bot]commented, Jan 5, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Issue 246875: Chrome not rendering webpage CSS and ...
CSS images are not getting rendered. Web server log has a lot of 304 errors to assets. Only Chrome issue works fine on...
Read more >
68622 - Images randomly not displayed - chromium - Monorail
First, reloading (cmd + R) several times until the image stop rendering (tried scrolling while reloading, changing tabs, playing flash, etc.. until it...
Read more >
How Chromium Displays Web Pages
Chromium's render process embeds our WebKit port using the glue interface. It does not contain very much code: its job is primarily to...
Read more >
138876 - Pages Not Rendering Until Window Moves - chromium
1.Open Chrome on Linux. 2. Navigate to any page. It will not show the page. 3.Move the window and the page content will...
Read more >
134040 - image-rendering: - Monorail
Issue 134040: image-rendering: -webkit-optimize-contrast does not work ... I believe a CSS property is ideal, even if it ends up being Chrome/webkit ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found