So I have a working media player that I built in C# with MSVS 2008. I have a feature that loads pics into a pictureBox. How can I possibly manipulate the bounds of the box to make it a circle, or an abstract object? I am aware of how to change x,y values.

Thanks for any help,
this is just a side project of mine NOT a hw assignment. If you know how to solve my issue please do so...
-jamesonh20

Recommended Answers

All 2 Replies

Correct me if I'm wrong. I think you want to change the region of picture box.

System.Drawing.Drawing2D.GraphicsPath gp = new System.Drawing.Drawing2D.GraphicsPath();
gp.AddEllipse(1,1,pictureBox1.Width, pictureBox1.Height );
Region rg = new Region(gp);
pictureBox1.Region = rg;
commented: Exactly what I was looking for, thank you! +1
commented: Great! +8

Thanks! Please mark this thread as solved if you have found an answer to your question and good luck!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.