If we have a non-exact ODE, then to convert it to an exact ODE we multiply the ODE with an integrating factor $\mu(x,y)$.
Lets us say we have the following ODE: $$M(x,y)dx+N(x,y)dy=0,$$ and let us denote $\frac{\partial M(x,y)}{\partial y}=M_y$ and $\frac{\partial N(x,y)}{\partial x}=N_x$.
Since the ODE is not exact, $M_y-M_x =f(x,y)\neq 0$.
We know that if $\frac{f(x,y)}{N(x,y)}$ depends only on $x$ then $e^{\int\frac{f(x,y)}{N(x,y)}dx}$ is the integrating factor of the ODE and if $\frac{f(x,y)}{M(x,y)}$ only depends on $y,$ then $e^{\int\frac{f(x,y)}{-M(x,y)}dy}$ is the integrating factor.
But what is the integrating factor of the ODE when both $\frac{f(x,y)}{M(x,y)}$ and $\frac{f(x,y)}{N(x,y)}$ are functions of $x$ and $y$ and neither of them are independent of any variable?
For example, in the following ODE: $$y(1+2x^2+2y^2)\; \mathrm dx + x(1-2x^2-2y^2)\; \mathrm dy=0,$$ $M_y-N_x=f(x,y)=8x^2+8y^2$ and neither of $\frac{f(x,y)}{M(x,y)}$ and $\frac{f(x,y)}{N(x,y)}$ are independent of any variable i.e both of them depend on $x$ and $y$ both.
So in such cases how do we determine the integrating factor?