xna wp7 how to let the user crop his photo
hi how can i let the user to crop his picture before choosing one in the photoChooserTask?
开发者_开发问答 ( in msdn it says that the pixelheight/width doesn't work yet) thanksYou would have to do the pixel operations yourself after the image has selected. You can render the image to the screen, and then look for two touch points to determine the x/y and height/width ... then create a new texture with those dimensions and render to it as a RenderTarget. You can then save this new texture, or do whatever you need to do with it
Not sure if Windows Phone 7 can handle RenderTargets but if it can. You can just have the user drag a rectangle, create a RenderTarget of that size, and then draw to the RenderTarget using the rectangle as the source rectangle of the image you want to crop.
精彩评论