MythTV  master
Public Member Functions | Private Attributes | List of all members
Histogram Class Reference

#include <Histogram.h>

Collaboration diagram for Histogram:
Collaboration graph

Public Member Functions

 Histogram ()=default
 ~Histogram ()=default
void generateFromImage (MythVideoFrame *frame, unsigned int frameWidth, unsigned int frameHeight, unsigned int minScanX, unsigned int maxScanX, unsigned int minScanY, unsigned int maxScanY, unsigned int XSpacing, unsigned int YSpacing)
float calculateSimilarityWith (const Histogram &other) const
unsigned int getAverageIntensity () const
unsigned int getThresholdForPercentageOfPixels (float percentage) const

Private Attributes

std::array< int, 256 > m_data {0}
unsigned int m_numberOfSamples {1}

Detailed Description

Definition at line 6 of file Histogram.h.

Constructor & Destructor Documentation

◆ Histogram()

Histogram::Histogram ( )

◆ ~Histogram()

Histogram::~Histogram ( )

Member Function Documentation

◆ generateFromImage()

void Histogram::generateFromImage ( MythVideoFrame frame,
unsigned int  frameWidth,
unsigned int  frameHeight,
unsigned int  minScanX,
unsigned int  maxScanX,
unsigned int  minScanY,
unsigned int  maxScanY,
unsigned int  XSpacing,
unsigned int  YSpacing 

Definition at line 8 of file Histogram.cpp.

Referenced by ClassicSceneChangeDetector::processFrame().

◆ calculateSimilarityWith()

float Histogram::calculateSimilarityWith ( const Histogram other) const

Definition at line 65 of file Histogram.cpp.

Referenced by ClassicSceneChangeDetector::processFrame().

◆ getAverageIntensity()

unsigned int Histogram::getAverageIntensity ( ) const

Definition at line 34 of file Histogram.cpp.

◆ getThresholdForPercentageOfPixels()

unsigned int Histogram::getThresholdForPercentageOfPixels ( float  percentage) const

Definition at line 49 of file Histogram.cpp.

Member Data Documentation

◆ m_data

std::array<int,256> Histogram::m_data {0}

◆ m_numberOfSamples

unsigned int Histogram::m_numberOfSamples {1}

The documentation for this class was generated from the following files: