optimized createHanningWindow

**merge with Itseez/opencv_extra#126**
```
                       Name of Test                          plain     cool      cool   
                                                                                  vs    
                                                                                plain   
                                                                              (x-factor)
CreateHanningWindow::CreateHanningWindowFixture::640x480   30.205 ms 0.707 ms   42.73   
CreateHanningWindow::CreateHanningWindowFixture::1920x1080 95.448 ms 3.967 ms   24.06 
```