along with VOMP. If not, see <https://www.gnu.org/licenses/>.
*/
+// FIXME It doesn't seem like the LoadingIndex entries in loadindex_ref ever get deleted
+
#include "log.h"
#include "surfacevector.h"
#include "vdr.h"
if ( itty != tvmedias_loaded.end())
{
- // removeImageRef((*itty).second); // remove lock
+ removeImageRef((*itty).second); // remove lock
+
+ /* Update - not this? Re-enabled. */
+
/*
* I'm not sure exactly how all this works but removing this line of code prevents
* reference counts in vhi_refcounts from going negative. Therefore I suspect the above
}
}
+void OsdVector::dumpImages()
+{
+ // surfaces_mutex.lock();
+
+ printf("tvmedias.size = %i\n", tvmedias.size());
+
+ printf("vhi_refcounts\n");
+ // std::map<ImageIndex, int> vhi_refcounts;
+ // ImageIndex is a VectorHandle. VectorHandle is an unsigned int
+ for(auto& a : vhi_refcounts)
+ {
+ printf("ImageIndex: %u int: %i\n", a.first, a.second);
+ }
+
+ printf("loadingindex_ref\n");
+ // std::map<LoadingIndex, int> loadindex_ref;
+ // LoadingIndex is a unsigned long long
+ for(auto& a : loadindex_ref)
+ {
+ printf("LoadingIndex: %llu (%llu) int: %i\n", a.first, a.first >> 32, a.second);
+ }
+
+ // surfaces_mutex.unlock();
+}
+
void OsdVector::cleanupOrphanedRefs()
{
// Do some garbage collection
itty++;
}
- LogNT::getInstance()->debug(TAG, "removeDecoder");
+ LogNT::getInstance()->debug("PictureReader", "removeDecoder");
decoder->shutdown();
delete decoder;
decoders_lock.unlock();
return true;
}
- // LogNT::getInstance()->debug(TAG, "TVMedia Pictures arrived VDR {:#x} {} {}",
+ // LogNT::getInstance()->debug("PictureReader", "TVMedia Pictures arrived VDR {:#x} {} {}",
// vresp->getStreamID(),vresp->getUserDataLength(),vresp->getFlag());
bool decode = false;
bool freed = false;