MCPcopy Create free account
hub / github.com/SimVascular/SimVascular / Image_scale

Function Image_scale

Code/Source/PythonAPI/ImagingImage_PyClass.cxx:809–828  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

807");
808
809static PyObject *
810Image_scale(PyImage* self, PyObject* args, PyObject* kwargs)
811{
812 auto api = PyUtilApiFunction("d", PyRunTimeErr, __func__);
813 static char *keywords[] = {"scale_factor", NULL};
814 double scale;
815
816 if (!PyArg_ParseTupleAndKeywords(args, kwargs, api.format, keywords, &scale)) {
817 return api.argsError();
818 }
819
820 if (scale <= 0.0) {
821 api.error("The 'scale_factor' argument must be >= 0.0.");
822 return nullptr;
823 }
824
825 ScaleImage(self, scale);
826
827 Py_RETURN_NONE;
828}
829
830//--------------
831// Image_origin

Callers

nothing calls this directly

Calls 3

ScaleImageFunction · 0.85
argsErrorMethod · 0.80
errorMethod · 0.80

Tested by

no test coverage detected