I try to search it,but only found this in cocos2d-iphone about this, have the similar way to do in cocos2d-x?
`+(UIImage ) getSumImageWithImagesHorizontal:(NSArray) images {
CGFloat width = 0;
CGFloat height = 0;
for (int i = 0; i < [images count]; i++) {
CGSize size = [(UIImage*)[images objectAtIndex:i] size];
width += size.width;
height = size.height > height ? size.height : height;
}
UIGraphicsBeginImageContext(CGSizeMake(width, height));
CGPoint beginPoint = ccp(0, 0);
for (int i = 0; i < [images count]; i++) {
UIImage* image = (UIImage*)[images objectAtIndex:i];
[image drawInRect:CGRectMake(beginPoint.x, beginPoint.y, image.size.width, image.size.height)];
beginPoint.x = beginPoint.x + image.size.width;
}
UIImage *resultImg = UIGraphicsGetImageFromCurrentImageContext();
*UIGraphicsEndImageContext*();
return resultImg;
} `