MCPcopy Create free account
hub / github.com/creatale/node-dv / icvGetColorModel

Function icvGetColorModel

deps/opencv/modules/core/src/array.cpp:2838–2857  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2836}
2837
2838static void
2839icvGetColorModel( int nchannels, const char** colorModel, const char** channelSeq )
2840{
2841 static const char* tab[][2] =
2842 {
2843 {"GRAY", "GRAY"},
2844 {"",""},
2845 {"RGB","BGR"},
2846 {"RGB","BGRA"}
2847 };
2848
2849 nchannels--;
2850 *colorModel = *channelSeq = "";
2851
2852 if( (unsigned)nchannels <= 3 )
2853 {
2854 *colorModel = tab[nchannels][0];
2855 *channelSeq = tab[nchannels][1];
2856 }
2857}
2858
2859
2860// create IplImage header

Callers 2

cvCreateImageHeaderFunction · 0.85
cvInitImageHeaderFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected