\8fÍ/3.3.1_\89æ\91\9c\83t\83@\83C\83\8b\82Ì\95Û\91¶2.cpp - RSS feed" href="/view?p=psychlops/cpp_document.git;a=rss;f=Psychlops.manual/sample_cpp_file/3%C2%8F%C3%8D/3.3.1_%C2%89%C3%A6%C2%91%C2%9C%C2%83t%C2%83@%C2%83C%C2%83%C2%8B%C2%82%C3%8C%C2%95%C3%9B%C2%91%C2%B62.cpp" type="application/rss+xml" /> \8fÍ/3.3.1_\89æ\91\9c\83t\83@\83C\83\8b\82Ì\95Û\91¶2.cpp - RSS feed (no merges)" href="/view?p=psychlops/cpp_document.git;a=rss;f=Psychlops.manual/sample_cpp_file/3%C2%8F%C3%8D/3.3.1_%C2%89%C3%A6%C2%91%C2%9C%C2%83t%C2%83@%C2%83C%C2%83%C2%8B%C2%82%C3%8C%C2%95%C3%9B%C2%91%C2%B62.cpp;opt=--no-merges" type="application/rss+xml" /> \8fÍ/3.3.1_\89æ\91\9c\83t\83@\83C\83\8b\82Ì\95Û\91¶2.cpp - Atom feed" href="/view?p=psychlops/cpp_document.git;a=atom;f=Psychlops.manual/sample_cpp_file/3%C2%8F%C3%8D/3.3.1_%C2%89%C3%A6%C2%91%C2%9C%C2%83t%C2%83@%C2%83C%C2%83%C2%8B%C2%82%C3%8C%C2%95%C3%9B%C2%91%C2%B62.cpp" type="application/atom+xml" /> \8fÍ/3.3.1_\89æ\91\9c\83t\83@\83C\83\8b\82Ì\95Û\91¶2.cpp - Atom feed (no merges)" href="/view?p=psychlops/cpp_document.git;a=atom;f=Psychlops.manual/sample_cpp_file/3%C2%8F%C3%8D/3.3.1_%C2%89%C3%A6%C2%91%C2%9C%C2%83t%C2%83@%C2%83C%C2%83%C2%8B%C2%82%C3%8C%C2%95%C3%9B%C2%91%C2%B62.cpp;opt=--no-merges" type="application/atom+xml" />

OSDN Git Service

hk
[psychlops/cpp_document.git] / Psychlops.manual / sample_cpp_file / 3\8fÍ / 3.3.1_\89æ\91\9c\83t\83@\83C\83\8b\82Ì\95Û\91¶2.cpp
1 #include <psychlops.h>\r
2 using namespace Psychlops;\r
3 \r
4 double width=100,height=100;\r
5 double temp1;\r
6 double centerX=700,centerY=500;\r
7 Psychlops::Rectangle rect1(width,height);\r
8 Psychlops::Color col;\r
9 Psychlops::Image Noise1;\r
10 \r
11 void psychlops_main() {\r
12 \r
13  Canvas sampleA(Canvas::fullscreen);\r
14  rect1.shift(centerX,centerY);\r
15  for(int x=0; x<width; x++){\r
16   for(int y=0; y<height; y++){\r
17    temp1=Psychlops::random();\r
18    col.set(temp1);\r
19    sampleA.pix(x+centerX,y+centerY,col);\r
20   }\r
21  }\r
22  sampleA.to(Noise1,rect1);\r
23  sampleA.flip();\r
24  while(!Input::get(Keyboard::spc));\r
25  Noise1.save("%APP%test.png");\r
26 }\r