Page 1 of 2

Degrees symbol encoding

Posted: Mon 01 Apr 2024 10:03 pm
by Mapantz
I think I've mentioned this before?

Anyway, I'm using CMX to process a small text file to overlay on an image. The degrees symbol is not being encoded properly and causes strange characters to appear.

However, if I open the processed text file and then manually save it as ANSI, the degrees symbol is encoded correctly on the image. However, as soon as CMX does it's processing, it changes the file back to UTF8 and the encoding fails on the degrees symbol again.

I don't have UTF8 set in the extra web files processing. Is there anything I can do top stop this?

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 11:02 am
by cliftonweather
What are you using? ansi code or literally a degree symbol as °, the latter works for me on UTF8 overlaid on a webcam image.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 11:09 am
by Mapantz
Using IPTimelapse to put an overlay on a webcam image.

I've tried all codes, both ANSI and UTF8, as well as the literal symbol.

It works when the text file is ANSI, but CMX changes the text file back to UTF8 when it processes it.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 11:16 am
by mcrossley
I've had a look at the code, and if an Extra Web File just created at the path location (rather than being uploaded), then the global UTF-8 encoding value is being used rather than the value set in the Extra Web Files screen.

(Internet Settings > Web/Upload Site > General Settings)

I'll fix that for the next release.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 11:21 am
by Mapantz
Great stuff!

Thanks Mark. :D

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 4:29 pm
by BeaumarisWX
Brilliant :clap:

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 6:07 pm
by ConligWX
Mapantz wrote: Tue 02 Apr 2024 11:09 am Using IPTimelapse to put an overlay on a webcam image.

I've tried all codes, both ANSI and UTF8, as well as the literal symbol.

It works when the text file is ANSI, but CMX changes the text file back to UTF8 when it processes it.
well looks like mark has identified some fix for you. I use UTF-8 on website and any text files and overlays to my camera images so I dont run into that issue much.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 6:34 pm
by 92merc
Mapantz, I noticed you're running into the same issue as I am. When your wind direction goes from SSW, to SW, the whole line moves around. It doesn't stay with the same spacing.

The reason that is an issue for me, is I create a nightly timelapse video I post to YouTube. When you speed up those shifts, it makes the whole text overlay look wonky.

I was really hoping there would be a way to format that TXT file out to stay with consistent spacing.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 6:57 pm
by Mapantz
Hi 92merc.

I hadn't given that any thought before, but it doesn't cause any issues for me.
How often is your text file being updated?

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 7:28 pm
by 92merc
I think it updates every 10 seconds or so.

Right now, the IPTL developer has his configuration for WD. But I don't care for the tenths of a MPH on Wind. And Baro pressure should be 2 points.

I was hoping to switch over to having Cumulus make the TXT file. And it did make it when I tested it on V3. But if you fast forward on this video to just past the 1 minute mark, you can see when I switched to Cumulus making data overlay vs WD.

https://www.youtube.com/watch?v=UoZstJf7jMg

If the spacing was such that wind direction was always 3 characters, it would work.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 7:50 pm
by Mapantz
10 seconds is fast when playing it back on a time-lapsed video.

I'm guessing in the extra web files, you have 'Realtime' checked?

I don't use it for the text, as it updates too fast and you can't read it well on the time-lapsed video. Instead, the text file is updated every 5 minutes.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 7:57 pm
by 92merc
I think when you setup the plain text overlay, it'll add the text at every picture taking. Which I have set to 3 seconds.

But when you use WD option on the Weather tab, it caches it. You can chose 0-60 seconds. I have mine set to 5 seconds.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 8:13 pm
by Mapantz
I meant in the Cumulus MX settings. The text file/webtags are being updated too frequently.

Re: Degrees symbol encoding

Posted: Tue 02 Apr 2024 8:36 pm
by 92merc
When I upgraded to V4, I totally removed my IPTL text file from being made. But I don't think I had it set to realtime.

Wouldn't have mattered as IPTL was looking at the file only every few seconds.

Issue was the spacing of the resulting text file made the timelapse video text look wonky as it was sliding back and forth. IPTL developer had the WD setup locked in as far as spacing goes.

The developer said he'd look at fixing my issues by altering the decimal places, when he had time. In the meantime, I was hoping there was a way to format the Cumulus file instead.

Re: Degrees symbol encoding

Posted: Thu 04 Apr 2024 12:02 am
by BeaumarisWX
Cheers Mark,
CU-MX (4.0.0-b4019) Fixed this Degrees Symbol issue.

https://beaumaris-weather.com/webcam/BWXLiveCam.jpg

If you click image link above, once it loads, click the image again to zoom into more detail.

View Desktop : https://beaumaris-weather.com/wxwebcamtimelapse.php

View Mobile : https://beaumaris-weather.com/BWX/webcam.php

Kindest Regards,