About: TeX Live provides a comprehensive TeX system including all the major TeX-related programs, macro packages, and fonts that are free software. Windows sources.
  Fossies Dox: w32tex-src.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

pgmtexture.c File Reference
#include <math.h>
#include "pgm.h"
Include dependency graph for pgmtexture.c:

Go to the source code of this file.


#define RADIX   2.0
#define EPSILON   0.000000001
#define BL   "Angle "
#define F1   "Angular Second Moment "
#define F2   "Contrast "
#define F3   "Correlation "
#define F4   "Variance "
#define F5   "Inverse Diff Moment "
#define F6   "Sum Average "
#define F7   "Sum Variance "
#define F8   "Sum Entropy "
#define F9   "Entropy "
#define F10   "Difference Variance "
#define F11   "Difference Entropy "
#define F12   "Meas of Correlation-1 "
#define F13   "Meas of Correlation-2 "
#define F14   "Max Correlation Coeff "
#define SIGN(x, y)   ((y)<0 ? -fabs(x) : fabs(x))
#define DOT   fprintf(stderr,".")
#define SWAP(a, b)   {y=(a);(a)=(b);(b)=y;}


float f1_asm ()
float f2_contrast ()
float f3_corr ()
float f4_var ()
float f5_idm ()
float f6_savg ()
float f7_svar ()
float f8_sentropy ()
float f9_entropy ()
float f10_dvar ()
float f11_dentropy ()
float f12_icorr ()
float f13_icorr ()
float f14_maxcorr ()
float * vector ()
float ** matrix ()
void results ()
void simplesrt ()
void mkbalanced ()
void reduction ()
void hessenberg ()
int main (int argc, argv)
float f1_asm (float **P, int Ng)
float f2_contrast (float **P, int Ng)
float f3_corr (float **P, int Ng)
float f4_var (float **P, int Ng)
float f5_idm (float **P, int Ng)
float f6_savg (float **P, int Ng)
float f7_svar (float **P, int Ng, float S)
float f8_sentropy (float **P, int Ng)
float f9_entropy (float **P, int Ng)
float f10_dvar (float **P, int Ng)
float f11_dentropy (float **P, int Ng)
float f12_icorr (float **P, int Ng)
float f13_icorr (float **P, int Ng)
float f14_maxcorr (float **P, int Ng)
float * vector (int nl, int nh)
float ** matrix (int nrl, int nrh, int ncl, int nch)
void results (char *c, float *a)
void simplesrt (int n, arr)
void mkbalanced (float **a, int n)
void reduction (float **a, int n)
void hessenberg (float **a, int n, wr, wi)


float Pxpy [2 *255]

Macro Definition Documentation

◆ BL

#define BL   "Angle "

Definition at line 48 of file pgmtexture.c.


#define DOT   fprintf(stderr,".")

Definition at line 65 of file pgmtexture.c.


#define EPSILON   0.000000001

Definition at line 47 of file pgmtexture.c.

◆ F1

#define F1   "Angular Second Moment "

Definition at line 49 of file pgmtexture.c.

◆ F10

#define F10   "Difference Variance "

Definition at line 58 of file pgmtexture.c.

◆ F11

#define F11   "Difference Entropy "

Definition at line 59 of file pgmtexture.c.

◆ F12

#define F12   "Meas of Correlation-1 "

Definition at line 60 of file pgmtexture.c.

◆ F13

#define F13   "Meas of Correlation-2 "

Definition at line 61 of file pgmtexture.c.

◆ F14

#define F14   "Max Correlation Coeff "

Definition at line 62 of file pgmtexture.c.

◆ F2

#define F2   "Contrast "

Definition at line 50 of file pgmtexture.c.

◆ F3

#define F3   "Correlation "

Definition at line 51 of file pgmtexture.c.

◆ F4

#define F4   "Variance "

Definition at line 52 of file pgmtexture.c.

◆ F5

#define F5   "Inverse Diff Moment "

Definition at line 53 of file pgmtexture.c.

◆ F6

#define F6   "Sum Average "

Definition at line 54 of file pgmtexture.c.

◆ F7

#define F7   "Sum Variance "

Definition at line 55 of file pgmtexture.c.

◆ F8

#define F8   "Sum Entropy "

Definition at line 56 of file pgmtexture.c.

◆ F9

#define F9   "Entropy "

Definition at line 57 of file pgmtexture.c.


#define RADIX   2.0

Definition at line 46 of file pgmtexture.c.


#define SIGN (   x,
)    ((y)<0 ? -fabs(x) : fabs(x))

Definition at line 64 of file pgmtexture.c.


#define SWAP (   a,
)    {y=(a);(a)=(b);(b)=y;}

Definition at line 66 of file pgmtexture.c.

Function Documentation

◆ f10_dvar() [1/2]

float f10_dvar ( )

Referenced by main().

◆ f10_dvar() [2/2]

float f10_dvar ( float **  P,
int  Ng 

Definition at line 557 of file pgmtexture.c.

References abs, i, j, P, PGM_MAXMAXVAL, and Pxpy.

◆ f11_dentropy() [1/2]

float f11_dentropy ( )

Referenced by main().

◆ f11_dentropy() [2/2]

float f11_dentropy ( float **  P,
int  Ng 

Definition at line 586 of file pgmtexture.c.

References abs, EPSILON, i, j, log10(), P, PGM_MAXMAXVAL, and Pxpy.

◆ f12_icorr() [1/2]

float f12_icorr ( )

Referenced by main().

◆ f12_icorr() [2/2]

float f12_icorr ( float **  P,
int  Ng 

Definition at line 609 of file pgmtexture.c.

References EPSILON, i, j, log10(), P, and vector().

◆ f13_icorr() [1/2]

float f13_icorr ( )

Referenced by main().

◆ f13_icorr() [2/2]

float f13_icorr ( float **  P,
int  Ng 

Definition at line 653 of file pgmtexture.c.

References abs, EPSILON, exp(), i, j, log10(), P, sqrt(), and vector().

◆ f14_maxcorr() [1/2]

float f14_maxcorr ( )

Referenced by main().

◆ f14_maxcorr() [2/2]

float f14_maxcorr ( float **  P,
int  Ng 

Definition at line 697 of file pgmtexture.c.

References hessenberg(), i, j, k, matrix(), mkbalanced(), P, reduction(), sqrt(), vector(), and cordic::x.

◆ f1_asm() [1/2]

float f1_asm ( )

Referenced by main().

◆ f1_asm() [2/2]

float f1_asm ( float **  P,
int  Ng 

Definition at line 329 of file pgmtexture.c.

References i, j, and P.

◆ f2_contrast() [1/2]

float f2_contrast ( )

Referenced by main().

◆ f2_contrast() [2/2]

float f2_contrast ( float **  P,
int  Ng 

Definition at line 353 of file pgmtexture.c.

References i, j, n, and P.

◆ f3_corr() [1/2]

float f3_corr ( )

Referenced by main().

◆ f3_corr() [2/2]

float f3_corr ( float **  P,
int  Ng 

Definition at line 381 of file pgmtexture.c.

References i, j, P, sqrt(), and vector().

◆ f4_var() [1/2]

float f4_var ( )

Referenced by main().

◆ f4_var() [2/2]

float f4_var ( float **  P,
int  Ng 

Definition at line 432 of file pgmtexture.c.

References i, j, and P.

◆ f5_idm() [1/2]

float f5_idm ( )

Referenced by main().

◆ f5_idm() [2/2]

float f5_idm ( float **  P,
int  Ng 

Definition at line 456 of file pgmtexture.c.

References i, j, and P.

◆ f6_savg() [1/2]

float f6_savg ( )

Referenced by main().

◆ f6_savg() [2/2]

float f6_savg ( float **  P,
int  Ng 

Definition at line 474 of file pgmtexture.c.

References i, j, P, PGM_MAXMAXVAL, and Pxpy.

◆ f7_svar() [1/2]

float f7_svar ( )

Referenced by main().

◆ f7_svar() [2/2]

float f7_svar ( float **  P,
int  Ng,
float  S 

Definition at line 497 of file pgmtexture.c.

References i, j, P, PGM_MAXMAXVAL, Pxpy, and S.

◆ f8_sentropy() [1/2]

float f8_sentropy ( )

Referenced by main().

◆ f8_sentropy() [2/2]

float f8_sentropy ( float **  P,
int  Ng 

Definition at line 516 of file pgmtexture.c.

References EPSILON, i, j, log10(), P, PGM_MAXMAXVAL, and Pxpy.

◆ f9_entropy() [1/2]

float f9_entropy ( )

Referenced by main().

◆ f9_entropy() [2/2]

float f9_entropy ( float **  P,
int  Ng 

Definition at line 540 of file pgmtexture.c.

References EPSILON, i, j, log10(), and P.

◆ hessenberg() [1/2]

void hessenberg ( )

Referenced by f14_maxcorr().

◆ hessenberg() [2/2]

void hessenberg ( float **  a,
int  n,
wr  ,

Definition at line 918 of file pgmtexture.c.

References a, exit(), F14, fabs, fprintf, i, j, k, cutout::l, m, mmin, n, nn, p, q, r, s, SIGN, sqrt(), t, u, v, w, cordic::x, y, and z.

◆ main()

◆ matrix() [1/2]

float** matrix ( )
/dev/shm/warix/file_cache/windows/misc/w32tex-src.tar.xz/ktx/libs/freetype/include/freetype/freetype.h, /dev/shm/warix/file_cache/windows/misc/w32tex-src.tar.xz/ktx/libs/freetype/include/freetype/ftoutln.h, /dev/shm/warix/file_cache/windows/misc/w32tex-src.tar.xz/ptx/libs/freetype/include/freetype/freetype.h, and /dev/shm/warix/file_cache/windows/misc/w32tex-src.tar.xz/ptx/libs/freetype/include/freetype/ftoutln.h.

Referenced by _cairo_cogl_context_set_matrix(), _cairo_cogl_context_transform(), _cairo_debug_print_matrix(), _cairo_default_context_get_font_matrix(), _cairo_default_context_get_matrix(), _cairo_default_context_set_font_matrix(), _cairo_default_context_set_matrix(), _cairo_default_context_set_source_surface(), _cairo_default_context_transform(), _cairo_gstate_get_font_matrix(), _cairo_gstate_get_matrix(), _cairo_gstate_set_font_matrix(), _cairo_gstate_set_matrix(), _cairo_gstate_transform(), _cairo_matrix_compute_adjoint(), _cairo_matrix_compute_basis_scale_factors(), _cairo_matrix_compute_determinant(), _cairo_matrix_get_affine(), _cairo_matrix_has_unity_scale(), _cairo_matrix_is_identity(), _cairo_matrix_is_integer_translation(), _cairo_matrix_is_invertible(), _cairo_matrix_is_pixel_exact(), _cairo_matrix_is_pixman_translation(), _cairo_matrix_is_scale(), _cairo_matrix_is_scale_0(), _cairo_matrix_is_translation(), _cairo_matrix_scalar_multiply(), _cairo_matrix_to_pixman_matrix(), _cairo_matrix_to_pixman_matrix_offset(), _cairo_matrix_transform_bounding_box(), _cairo_matrix_transform_bounding_box_fixed(), _cairo_matrix_transformed_circle_major_axis(), _cairo_output_stream_print_matrix(), _cairo_path_fixed_transform(), _cairo_path_fixed_transform_point(), _cairo_pdf_operators_set_text_matrix(), _cairo_pen_vertices_needed(), _cairo_quartz_cg_mask(), _cairo_script_surface_show_text_glyphs(), _cairo_surface_to_cgimage(), _cairo_svg_surface_emit_transform(), _cairo_win32_scaled_font_init_glyph_metrics(), _cairo_win32_scaled_font_init_glyph_path(), _cairo_win32_transform_FIXED_to_fixed(), _cairo_xcb_linear_picture(), _cairo_xcb_picture_set_matrix(), _cairo_xcb_radial_picture(), _cairo_xml_emit_matrix(), _emit_scaled_font(), _hash_matrix_fnv(), _is_scale(), _pixman_image_for_gradient(), _pixman_image_for_recording(), _render_type3_glyph(), SVGCharPathHandler::appendPathElement(), SVGCharPathHandler::appendUseElement(), CairoOutputDev::beginTransparencyGroup(), CairoOutputDev::beginType3Char(), cairo_get_font_matrix(), cairo_get_matrix(), cairo_mask_surface(), cairo_matrix_init(), cairo_matrix_init_identity(), cairo_matrix_init_rotate(), cairo_matrix_init_scale(), cairo_matrix_init_translate(), cairo_matrix_invert(), cairo_matrix_rotate(), cairo_matrix_scale(), cairo_matrix_transform_distance(), cairo_matrix_transform_point(), cairo_matrix_translate(), cairo_pattern_get_matrix(), cairo_pattern_set_matrix(), cairo_set_font_matrix(), cairo_set_matrix(), cairo_transform(), cff_face_init(), cff_parse_font_matrix(), cid_parse_font_matrix(), SplashClip::clipToPath(), DVIReader::cmdXPic(), composite_aligned_boxes(), composite_one_color_glyph(), compute_cluster_sizes(), ImageToSVG::convert(), create_matrix(), TransformSimplifier::decompose(), do_operator(), do_pdf(), Gfx::doFunctionShFill1(), AnnotMovie::draw(), draw_composite_glyf(), draw_simple_glyf(), Gfx::drawForm(), CairoOutputDev::drawImage(), CairoOutputDev::drawImageMask(), CairoOutputDev::drawImageMaskPrescaled(), CairoOutputDev::drawImageMaskRegular(), CairoOutputDev::drawMaskedImage(), CairoOutputDev::drawSoftMaskedImage(), DVIToSVGActions::endPage(), TransformSimplifier::execute(), f14_maxcorr(), FcExprCreateMatrix(), FcExprMatrixCopyShallow(), FcVStackPushMatrix(), Splash::flattenCurve(), Splash::flattenPath(), Efont::Cff::CIDFont::font_matrix(), Efont::Cff::Font::font_matrix(), Efont::CharstringProgram::font_matrix(), Efont::Type1Font::font_matrix(), Efont::TrueTypeBoundsCharstringProgram::font_matrix(), FT_Glyph_Transform(), FT_Matrix_Check(), FT_Matrix_Invert(), ft_outline_glyph_transform(), FT_Outline_Transform(), ft_raster1_transform(), FT_Set_Transform(), ft_smooth_transform(), FT_Vector_Transform(), FT_Vector_Transform_Scaled(), CairoOutputDev::functionShadedFill(), generate(), generate_dither_array(), generate_initial_binary_pattern(), get_singular_values(), OT::glyf::CompositeGlyphChain::get_transformation(), CairoImageOutputDev::getBBox(), CairoOutputDev::getFilterForSurface(), DVIToSVG::getPageTransformation(), CairoOutputDev::getScaledSize(), ImageToSVG::getUserMatrix(), glpath(), gradient_source(), PsSpecialHandler::image(), PsSpecialHandler::imgfile(), TransformSimplifier::incorporateTransform(), largest_cluster(), loadAATfont(), main(), PsSpecialHandler::makepattern(), matrix_destroy(), matrix_get(), matrix_init(), drvPPTX::parse_xform_matrix(), Matrix::parseSVGTransform(), pdf_doc_get_page(), pdf_doc_make_xform(), pdf_include_page(), picture_set_matrix(), picture_set_properties(), pixman_transform_bounds(), pixman_transform_init_identity(), pparray_to_matrix(), ppdict_get_matrix(), CairoOutputDev::radialShadedFill(), record_source(), record_to_picture(), set_transform_matrix(), Efont::CharstringBounds::set_xf(), CairoOutputDev::setDefaultCTM(), SVGCharHandler::setMatrix(), Splash::setMatrix(), CairoOutputDev::setSoftMaskFromImageMask(), drvplot::show_text(), SplashFunctionPattern::SplashFunctionPattern(), SplashXPath::SplashXPath(), swap_pixel(), t1_parse_font_matrix(), t42_parse_font_matrix(), TIFFXYZToRGB(), CairoOutputDev::tilingPatternFill(), trace_outline(), Point::transform(), OT::contour_point_vector_t::transform(), Bezier::transform(), EllipticalArc::transform(), GraphicsPath< T >::transform(), gp::Command< T, NUM_POINTS >::transform(), gp::ArcTo< T >::transform(), Splash::transform(), SplashXPath::transform(), transform_box_extents(), OT::glyf::CompositeGlyphChain::transform_points(), TT_Transform_Outline(), TT_Transform_Vector(), CairoOutputDev::updateCTM(), CairoOutputDev::updateFont(), and PSFrontEnd::yylex().

◆ matrix() [2/2]

float** matrix ( int  nrl,
int  nrh,
int  ncl,
int  nch 

Definition at line 762 of file pgmtexture.c.

References exit(), fprintf, i, m, malloc, and ncl.

◆ mkbalanced() [1/2]

void mkbalanced ( )

Referenced by f14_maxcorr().

◆ mkbalanced() [2/2]

void mkbalanced ( float **  a,
int  n 

Definition at line 821 of file pgmtexture.c.

References a, c, f, fabs, g, i, j, last, n, r, RADIX, and s.

◆ reduction() [1/2]

◆ reduction() [2/2]

void reduction ( float **  a,
int  n 

Definition at line 873 of file pgmtexture.c.

References a, fabs, i, j, m, n, SWAP, cordic::x, and y.

◆ results() [1/2]

void results ( )

Referenced by _EBCDICSwapLFNL(), cf2_interpT2CharString(), do_query_features(), do_query_scripts(), PDFCore::findAll(), ZxNode::findAllChildElements(), ZxNode::findAllElements(), TZGNCore::findLocal(), number::impl::NumberFormatterImpl::format(), number::impl::NumberFormatterImpl::formatStatic(), GNameSearchHandler::getMatches(), ZNameSearchHandler::getMatches(), TZDBNameSearchHandler::getMatches(), Efont::OpenType::FeatureList::lookups(), main(), CharsetRecog_8859_1::match(), CharsetRecog_8859_2::match(), CharsetRecog_8859_5_ru::match(), CharsetRecog_8859_6_ar::match(), CharsetRecog_8859_7_el::match(), CharsetRecog_8859_8_I_he::match(), CharsetRecog_8859_8_he::match(), CharsetRecog_8859_9_tr::match(), CharsetRecog_windows_1256::match(), CharsetRecog_windows_1251::match(), CharsetRecog_KOI8_R::match(), CharsetRecog_IBM424_he_rtl::match(), CharsetRecog_IBM424_he_ltr::match(), CharsetRecog_IBM420_ar_rtl::match(), CharsetRecog_IBM420_ar_ltr::match(), CharsetRecog_sjis::match(), CharsetRecog_euc_jp::match(), CharsetRecog_euc_kr::match(), CharsetRecog_big5::match(), CharsetRecog_gb_18030::match(), CharsetRecog_UTF8::match(), CharsetRecog_2022JP::match(), CharsetRecog_2022KR::match(), CharsetRecog_2022CN::match(), CharsetRecog_UTF_16_BE::match(), CharsetRecog_UTF_16_LE::match(), CharsetRecog_UTF_32::match(), otfcc_buildCmap_format14(), output_tfm(), ParsePSArray(), smoothjoints(), ttf_fftm_dump(), ucnv_DBCSFromUTF8(), ucnv_MBCSGetFilteredUnicodeSetForUnicode_68(), ucnv_MBCSSingleFromBMPWithOffsets(), ucnv_MBCSSingleFromUnicodeWithOffsets(), ucnv_SBCSFromUTF8(), and uspoof_areConfusableUTF8().

◆ results() [2/2]

void results ( char *  c,
float *  a 

Definition at line 788 of file pgmtexture.c.

References a, c, DOT, fprintf, i, and fc-lang::stdout.

◆ simplesrt() [1/2]

void simplesrt ( )

◆ simplesrt() [2/2]

void simplesrt ( int  n,

Definition at line 801 of file pgmtexture.c.

References a, gen-emoji-table::arr, i, j, and n.

◆ vector() [1/2]

◆ vector() [2/2]

float* vector ( int  nl,
int  nh 

Definition at line 750 of file pgmtexture.c.

References exit(), fprintf, malloc, nh, nl, and v.

Variable Documentation

◆ Pxpy

float Pxpy[2 * 255]

Definition at line 472 of file pgmtexture.c.

Referenced by f10_dvar(), f11_dentropy(), f6_savg(), f7_svar(), and f8_sentropy().