given Image resize and save the resize image - c#

I want to re-size an user input picture and want to save the resize image in a folder. Please help me to do this task

http://www.switchonthecode.com/tutorials/csharp-tutorial-image-editing-saving-cropping-and-resizing this is good article for you

Related

Drawing shapes on an image control and save the new image

This is a wpf project in which i have a window that views some images in image controls - each image is viewed alone in the window - and i want to add the ability to draw some shapes or write a text on the image and then save the edited image.
I tried putting the image control inside an inkcanvas but that didn't really gave me what i want.
so how can i achieve that ?

How to erase part of Image by finger on WinPhone?

I have heavy task for me.
I have simple WinPhone silverlight page, on page I have Canvas.
On Canvas I have Image control with photo.
I want that user can erase part of picture on Image control by finger (similary on erase in MS Paint).
And after change photo user can save new image.
I don't fins solution for this task.
Could you please help me?
Put another Canvas into the Canvas, overlaying the Image. Let the user draw on this new Canvas (Drawing things on a Canvas). Save the result by calling WritableBitmap.Render(parentCanvas) and SaveJpeg (Saving a WriteableBitmap).
You might need to add some Transformations to handle different Image sizes.
You could put your image inside a Grid and put an InkPresenter on top and to erase just use white ink. Here is a getStarted to use the inkpresenter : link. Finally when you want to save the result, just saved the grid using WriteableBitmap.Render and MediaLibrary.SaveJpeg to save it to the user Library.

Create an effect of magnifying glass for a picturebox

I would like to know how to create an effect of a magnifying glass for a picturebox.
Not zooming the picturebox but magnifying a part of the the image in the PictureBox control (circle or rectangle) and setting the size of the glass and the magnification factor.
It may only work within the picturebox control.
Language: C#
Thanks in advance !
Basically, you'd need two pictureboxes. One for the whole image and another for the magnified section. Also, you have to place the magnified picturebox according to user's mouse position.
You'll find a good article about it at http://www.codeproject.com/Articles/21097/PictureBox-Zoom. Just change the source to show the second picturebox in appropriate place (under user's cursor position).
You need 2 picturebox objects, one for picture itself and second for magnified area.
Next load picture into memory, you haven't specified source of the picture but in any case I recommend using streams.
Then create bitmap image in memory.
Using Image method set property of a picturebox.
To create source image for magnifying picturebox you need to clone selected part (calculating dimensions of a new picture area). Whole thing is not as trivial as you may expect as clone method accepts Rectangle objects as an area selector and generally works on rectangles rather than circles to copy selection. I also recommend to Dispose() unused bitmap objects as soon as possible.
Hope this helps.

Paint in A Grid And Export Image? (Windows or Mac)

I want the user to be able to paint in a grid in my Windows application 16x16 pixels large. Of course these are visiably bigger when editing but then can be output as a png file at its actual 16x16 size.
Im not asking for a full solution of course but if you could point me in the right direction for what to use to build up the grid which will allow me paint colours into it and then output it.
Any help much appreciated, thanks.
here is a somewhat general idea:
depending on the application, i'd use a simple picturebox, load a bitmap (from file, db, create empty, ...) and handle mouse clicks on that ...
translate the screen coordinates to your 16x16 matrix, and use some "needle-scheme" to interact with that image (means you have some sort of colorpicker that selects the color to use, and a click on a pixel sets it to that color)
since your image is only 16x16 you will probably want to set the picturebox to stretch or zoom mode
output of an image object is rather simple if you make use of the System.Drawing.Image class
if you need further details/help, let me know...

manage image with Pop up

I had image for Products and i want user when click on image appear image as popup with big size and save it
as
http://www.istockphoto.com/file_browse.php?exu=1&action=abstracttype&value=15&page=4
Is this what you need? (very hard to guess from your question)
ASP.NET JavaScript Image Popup Done Right

Categories

Resources