I have a map view inside a cell and I want it to have corner radius and shadow. I either get only rounded corners OR only the shadow and no rounder corners when i set masks to bounds ON/OFF respectively. I looked up to this example: Can't add a corner radius and a shadow
but with no success. What am I missing? thank you in advance!
[[cell.map1 layer] setShadowColor:[UIColor blackColor].CGColor];
[[cell.map1 layer] setShadowOpacity:0.8f];
[[cell.map1 layer] setShadowRadius:20.0f];
[[cell.map1 layer] setShadowOffset:CGSizeMake(0, 3)];
// [[cell.map1 layer] setMasksToBounds:NO];
[[cell.map1 layer] setShouldRasterize:YES];
[[cell.map1 layer] setCornerRadius:20];