EMAN2
Functions
tomoseg.cpp File Reference
#include "tomoseg.h"
#include <algorithm>
Include dependency graph for tomoseg.cpp:

Go to the source code of this file.

Functions

float DistToLine (int x0, int y0, int x1, int y1, int x2, int y2)
 

Function Documentation

◆ DistToLine()

float DistToLine ( int  x0,
int  y0,
int  x1,
int  y1,
int  x2,
int  y2 
)

Definition at line 32 of file tomoseg.cpp.

32 {
33 return abs((x2-x1)*(y1-y0)-(x1-x0)*(y2-y1))/sqrt((float)((x2-x1)*(x2-x1)+(y2-y1)*(y2-y1)));
34}
EMData * sqrt() const
return square root of current image

References sqrt().

Referenced by EMAN::TomoObject::bend().