Opened 15 years ago

Closed 15 years ago

#1498 closed enhancement (fixed)

two small fixes for the OSD cache

Reported by: visit0r Owned by: danielk
Priority: minor Milestone: unknown
Component: mythtv Version: head
Severity: medium Keywords: OSD cache
Cc: Ticket locked: no


Subtitles were not cleared in channel change. For some reason I got this problem only after the OSD cache was implemented. It might be somehow caused by it (I don't get why because subtitles are not cached), or just revealed by it due to more quicker channel change (just a wild guess). Anyways, I simply inserted

  if (osdHasSubtitles || nonDisplayedSubtitles.size() > 0)

in NuppelVideoPlayer::JumpProgram?() which seems to get called in each channel change, thus clearing the subtitles of the previous channel.

Another issue I noted from reviewing the final OSD cache patch DanielK created was that for images that are not cached (e.g., subtitles), the bitmaps are never freed. I changed the destructor of OSDTypeImage to the following, which should avoid the memory leak:

    if (!cache.InMemCache()) {
	if (m_yuv)
	    delete [] m_yuv;
	if (m_alpha)
	    delete [] m_alpha;    
    } else {

Change History (1)

comment:1 Changed 15 years ago by danielk

Resolution: fixed
Status: newclosed

(In [9345]) References #1488, Fixes #1498. Special handling for DVB/DVD subtitles.

Note: See TracTickets for help on using tickets.