افکت گذاری و افکت برای تصویر – گرافیک کامپیوتری

  – گرافیک کامپیوتری

قیمت :   ۱۰۵۰۰ تومان ( ده هزار و پانصد تومان)

رشته :

کامپیوتر

نوع فایل:

ویژوال استدیو

توضیحات:


توضیحات :

در این که به زبان سی شارپ در محیط ویژوال استدیو  و با استفاده از توابع کتابخانه ای  گرافیکی طراحی شده است ، شما می توانید توسط کلیدهای تعریف شده در این برنامه افکت های مختلفی را اعمال و مشاهده نمایید .          

   

==========

رایگان فایل اجرایی این پروژه : 


==========

بخشهایی از سورس کد این پروژه : 

using System;
using System.ComponentModel;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Text;
using System.Windows.Forms;
using DemoFX.FastBMP;
using System.Reflection;
using System.Drawing.Imaging;
using System.Runtime.InteropServices;

namespace DemoFX
{

public partial class FormDemo : Form
{
// General declares

private const double rad = 3.14159 / 180;

private Bitmap bmp;
private Graphics gForm;
private Graphics gBmp;
private int fHeight, fWidth;
private Random RandomClass;
private FastBitmap fb;
private bool DoFire, DoPlasma, DoStars, DoWave, DoRain, Do3D;

// Starfield-related variables

private const int MAX_STARS = 50;

private double StarSpeed1 = .1;
private double StarSpeed2 = .3;
private double StarSpeed3 = .5;

struct star
{
public int y, layer;
public double x;
public Color color;
}

star[] myStars;

// Plasma-related variables

private const double Whorls = 16.0;
private int speed1 = 1;
private int speed2 = 2;
private int speed3 = 3;
private int X, Y;
private int counter1, counter2, counter3;
private int[,] plasma;

// Water-related variables

private const int WAVEWIDTH = 80;
private const int WAVEHEIGHT = 10;
private const int WATERDEPTH = 40;
private const int WAVE_UBOUND = 200;
private const int WAVE_LBOUND = 75;
private const double REFRACTION = 1.333;
private int WaveBack = 1;
private int WaveSpeed = 1;
private double[] shift;
private Color[,] newtemp;

// Raindrop-related variables

private short[, ,] RaindropRipples;
private int RaindropWidth;
private int RaindropHeight;
private int RaindropCount = 0;
private bool RipplesPresent;

private byte[] BitmapBytes;
private BitmapData BitmapData;
//private int ScaleFactor = 0;
private int RaindropRadius = 20;
private int RippleDampener = 6;
private short RaindropCounter = 0;

// ۳D Rotation variables

private const int Distance = -500;
private const int CameraPosition = 300;
private const double Pi_Squared = 9.86958;
private const int PixelSpacing = 7;

public FormDemo()
{
InitializeComponent();

// InitializePicturebox();

timer1.Enabled = false;

// variables that tell us what to do
DoFire = false;
DoPlasma = false;
DoStars = false;
DoWave = false;
DoRain = false;
Do3D = false;

}

private void InitializePicturebox()
{

// Set up the picturebox for drawing graphics
bmp = new Bitmap(pBox1.Width, pBox1.Height);
gForm = pBox1.CreateGraphics();

gBmp = Graphics.FromImage(bmp);

//We’ll need to know height and width of the picturebox later
fHeight = bmp.Height;
fWidth = bmp.Width;

// and we’ll need some random numbers
RandomClass = new Random();

}

// Get and set each pixel on the screen.
for (int y = fHeight – 5; y > 1; y–)
{
Application.DoEvents();

for (int x = 1; x < fWidth – 1; x++)
{
// Get the color of the pixels. We’ll grab
// four at a time and average them. Our fire
// will look different depending on how many
// we’re averaging at a time.
Color c = fb.GetPixel(x, y);
Color d = fb.GetPixel(x, y – 1);
Color e = fb.GetPixel(x – 1, y);
Color r = fb.GetPixel(x + 1, y – 1);

// Add ’em and divide by four. Our RGB is
// a set of integer values we’ll use in the
// FromArgb call below.
int rR = ((c.R + d.R + e.R + r.R) / 4);
int rG = ((c.G + d.G + e.G + r.G) / 4);
int rB = ((c.B + d.B + e.B + r.B) / 4);

// Now put them back one row up from where we
// got them!
fb.SetPixel(x, y – 1, Color.FromArgb(rR, rG, rB));
}
}

// Unlock the FastBitmap since we’re done with our pixel work
fb.Release();

// GDI blits the whole thing back to the screen
gForm.DrawImage(bmp, 0, 0, fWidth, fHeight);

}

private void buttonFire_Click(object sender, EventArgs e)
{
// Button events to turn and off the fire. Pretty kludgey
// and this stuff shouldn’t be in the click event but oh well!
DoPlasma = false;
DoStars = false;
DoFire = !DoFire;

if (DoFire)
{
InitializeFire();
}

Application.DoEvents();

switch (DoFire)
{
case true:
buttonFire.Text = “Stop Fire”;
break;
case false:
buttonFire.Text = “Start Fire”;
break;
default:
buttonFire.Text = “Start Fire”;
break;
}

while (DoFire)
{
DoFlames();
}

}

private void DrawPlasma()
{
// Initialize the FastBitmap class
fb = new FastBitmap(bmp);

// vary the speeds that each color will cycle. Remember
// that the FromArgb function requires each color value of
// RGB to be 256 or less.
if (counter1 > 255 || counter1 <= 1) speed1 = -speed1;
if (counter2 > 255 || counter2 <= 2) speed2 = -speed2;
if (counter3 > 255 || counter3 <= 3) speed3 = -speed3;

// increment the speed counters
counter1 += speed1;
counter2 -= speed2;
counter3 += speed3;

Application.DoEvents();

// Once again we’ll need to set the pixels on the
// whole screen
for (X = 1; X < fWidth – 1; X++)
{
for (Y = 1; Y < fHeight – 1; Y++)
{
// take our RGB values in the plasma array
// and increment them to produce a shifting
// color effect. Mod the result by 256 to make
// sure the value is within the range of 8 bits.
int r = (plasma[X, Y] + counter3) % 256;
int g = (plasma[X, Y] + counter1) % 256;
int b = (plasma[X, Y] + counter2) % 256;

// and set the pixel
fb.SetPixel(X, Y, Color.FromArgb(r, g, b));
}
}

// Unlock the FastBitmap
fb.Release();

// and blit it to the screen
gForm.DrawImage(bmp, 0, 0, fWidth, fHeight);
}

private void buttonPlasma_Click(object sender, EventArgs e)
{
DoPlasma = !DoPlasma;

if (DoPlasma)
{
InitializePlasma();
}

Application.DoEvents();

switch (DoPlasma)
{
case true:
buttonPlasma.Text = “Stop Plasma”;
break;
case false:
buttonPlasma.Text = “Start Plasma”;
break;
default:
buttonPlasma.Text = “Start Plasma”;
break;
}

while (DoPlasma)
{
DrawPlasma();
}
}

 ==========

 دانلود کامل پروژه همراه با فایل سورس کد برنامه و فایل اجرایی آن
در تمامی ساعات شبانه روز >> پرداخت آنلاین و دانلود آنلاین پروژه

پذیرش و انجام سفارشات پروژه های شما
شماره تماس پشتیبانی سایت : ۰۹۳۹۲۷۶۱۶۳۰



توجه مهم :

*دوست عزیز در صورت نداشتن رمز پویا یا قطع بودن درگاه بانکی ، لطفا نام پروژه درخواستی خود را جهت هماهنگی برای دریافت شماره کارت واریزی و دریافت لینک دانلود، به واتساپ پشتیبانی سایت  ۰۹۳۹۲۷۶۱۶۳۰  ارسال کنید *(از ساعت ۸ الی ۲۳)

Related posts

دیدگاهتان را بنویسید

نشانی ایمیل شما منتشر نخواهد شد. بخش‌های موردنیاز علامت‌گذاری شده‌اند *