Setting EarthOrientationParameters

Hello,

I am attempting to do some Reference Frame transforms. Thus, trying to load EOP data do I can invoke preloadIcrfFixed() with an interval so I can invoke computeFixedToIcrfMatrix() with a time so I can start exploring those transformations. At this time the computeFixedToIcrfMatrix() return undefined as I suspect preloadIcrfFixed() isn’t loading any data as not EOP data is formally loaded. I am obviously missing something OR my environment is not correct.

Project is a React application w/ Resium and Cesium. I’ve been doing circles with ChatGPT on how to set the EOP data. It seems the EarthOrientationParameters are NOT supposed to be publicly exposed. Trying to set Transforms.earthOrientationParameters results in a compute() call not valid for object. Examples seem to indicate that setting Transforms.earthOrientationParameters = response (where response is result from Resource.fetchJson()). I am getting errors/warnings that ‘earthOrientationParameters’ is not a member OR when it does execute the compute call is invalid. Which makes sense as it’s a JSON response. Other examples are to make a new EarthOrientationParameters({ data: response }); but that object seems to not exist. ChatGPT seems to Ping-Pong between the two options.

So…I am missing something. Anyone have any ideas how to load EOP data?

I found this post which talks about where to get EOP data. Is there any way to modify the default transformation “TEME <-> ECF” of the Cesium - #4 by Scott_Hunter Unfortunately I cannot wire this up ibn Sandcastle as there is a CORS error trying to get the EOP.json file.

cesium/packages/engine/Source/Core/Resource.js at 1.117 · CesiumGS/cesium · GitHub

cesium/packages/engine/Source/Core/EarthOrientationParameters.js at 1.117 · CesiumGS/cesium · GitHub

cesium/packages/engine/Source/Core/Transforms.js at 1.117 · CesiumGS/cesium · GitHub

Sandcastle example…

This is on me BUT I did notice that in my React/Resium/Cesium project the EOP must be loading from somewhere as the calls to computeFixedToIcrfMatrix() and others are working. They are NOT working in Sandcastle where I have been prototyping. Maybe Sandcastle is NOT for this kind of work? Additionally, where is the EOP data my local project is somehow loading? Or is it a default somewhere? Lastly, can Sandcastle load the EOP data?

Hi @bmcclint,

The CORS error originates from the server-side configuration, in this case https://ftp.agi.com. It will require adjusting configurations on that server. See Cross-Origin Resource Sharing (CORS) - HTTP | MDN for more info.

By default, the CesiumJS loads EOP data which we ship along with CeisumJS. These are typically coming from the Assets directory.