[RELEASE] Image Cycle Tile, E.g. Weather Radar

Glad you mentioned iFrameAdvanced, had forgotten about this, but will be nice addition to using this, will be similar to the way the BOM app works with the radar sliding up and down, freeing up screen real estate.

Following conversation on the BOM weather driver thread, @rocketwiz requested and did the hard work of looking up options to scale an image to fit a dashboard tile:

I will look at including this as an option / feature in the image cycle driver.

Thanks Simon. The code works perfectly and the positioning of the final radar image can be fine tuned using standard CSS on the dashboard ("tile-primary"). I have not yet tried but I'm guessing that instead of scale() we could use scale X() and scaleY() to stretch/shrink the image a bit more in either axis for a better fit.

The only thing that can't probably be done unfortunately is the ability to get a full screen version of the radar on tapping the tile like we can with an image.

Hmmm... I'm torn between specific requests and something that works for all.... Must be what it feels like to develop the HE platform :slight_smile: I'm also wanting to work through what the best options are for scale given I have included a width and height settings already.... Trust me, a good problem to have.... Scale may be more useful....

The full screen option could be achieved with the advanced iframe setup you linked early on in this thread, allowing users to click on an image (iframe) and see a larger version if we want.

1 Like

No worries - I just put it out there.

Unfortunately the advanced iframe driver generates an additional button for the resizing (screen real estate is already precious when you're using a 7" Nest hub :slightly_smiling_face:). Anyway I'm just happy to have a proper weather radar instead of a static image!

1 Like

Does this mean I can quote "works with Google Nest" if I implement this feature? :grinning_face_with_smiling_eyes:

1 Like

Actually the width/height settings truncate the BOM URL "image" if set to smaller than the actual radar size rather than resize it. The actual BOM radar is 512x557 pixels so the default settings don't affect it as far as I can see.

That makes sense now that you mention it. There are probably uses for both options, allowing parts of an image to be cropped and then scaling the result... maybe...

Today I added the option to define static foreground images that appear on top of the images that cycle, primarily for the benefit of my Rain Radar image driver.

2 Likes

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.