Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display correct credit information #575

Closed
SangeethaS94 opened this issue Mar 26, 2018 · 4 comments
Closed

Display correct credit information #575

SangeethaS94 opened this issue Mar 26, 2018 · 4 comments

Comments

@SangeethaS94
Copy link

In the latest version of ol-cesium, the credit information for the layers are not displayed correctly. The text, imageUrl and link parameters have been removed from Cesium.Credit in Cesium version 1.41 onwards. In the latest version of ol-cesium, three arguments are being passed when Credit object is created in function olcs.core.OLImageryProvider.createCreditForSource. In order to display the correct credit information, it must instead be one object that contains these three parameters.

@gberaudo
Copy link
Member

Hi @SangeethaS94, I fixed the parameter passed to Cesium and opened #576 with the change. However there looks to still be some issues.

I will not have time in the next 3 weeks to look at this. If you investigate this, you are welcome to provide a pull request.

@gberaudo
Copy link
Member

See also CesiumGS/cesium#6331.

@SangeethaS94
Copy link
Author

Hi @gberaudo!
Thanks for looking into it.

In my case, I changed

return (imageUrl || text.length > 0) ? new Cesium.Credit(text, imageUrl, link) : null;

to

var options = new Object();
options.text = text;
options.imageUrl = imageUrl;
options.link = link;
return (imageUrl || text.length > 0) ? new Cesium.Credit(options) : null;

And everything seems to work well for me. I am not getting the issues you have mentioned in #576

@gberaudo
Copy link
Member

gberaudo commented May 3, 2018

The issue I mentioned actually appears when the 3D globe is loaded first (not OpenLayers). This issue is unrelated to the OL and Cesium changes.

@gberaudo gberaudo closed this as completed May 3, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants