MCPcopy Create free account
hub / github.com/davisking/dlib / set_size

Method set_size

dlib/image_processing/generic_image.h:322–340  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

320#endif
321
322 void set_size(long rows, long cols)
323 /*!
324 requires
325 - rows >= 0 && cols >= 0
326 ensures
327 - Tells the underlying image to resize itself to have the given number of
328 rows and columns.
329 - #nr() == rows
330 - #nc() == cols
331 !*/
332 {
333 DLIB_ASSERT((cols >= 0 && rows >= 0),
334 "\t image_view::set_size(long rows, long cols)"
335 << "\n\t The images can't have negative rows or columns."
336 << "\n\t cols: " << cols
337 << "\n\t rows: " << rows
338 );
339 set_image_size(*_img, rows, cols); *this = *_img;
340 }
341
342 void clear() { set_size(0,0); }
343 /*!

Callers 15

get_imageMethod · 0.45
get_imageMethod · 0.45
load_bmpFunction · 0.45
load_dngFunction · 0.45
get_imageMethod · 0.45
get_imageMethod · 0.45
load_imageFunction · 0.45
init_hogFunction · 0.45
init_hog_zero_everythingFunction · 0.45
extract_fhog_featuresFunction · 0.45
draw_fhogFunction · 0.45
label_connected_blobsFunction · 0.45

Calls 1

set_image_sizeFunction · 0.70

Tested by

no test coverage detected