The artificial fish in this experiment is simplified to
rectangular slices in order to reduce the number of polygons
drawn with the system. So the texture fusion technique is used
to map the 2D texture picture of artificial fish onto the
rectangular slices by calling glTexCoord2f(x, y). This method
can take full advantage of OpenGL’s vertex array function. The
swimming forms of artificial fish are created by reading
pictures of different forms of artificial fish and by calling
function glTranslatef(x,y,z) and function glRotatef(angle, x, y,
z) in OpenGL. Since the highlight of this experiment is the
behavioral decision making of artificial fish, the researchers
avoided building a complicated construction for the setting of
the artificial fish. All the fish images used in the model are 24
units BMP pictures sized 32 x 32. The main codes used in the
texture images are as follows:
ปลาเทียมในการทดลองนี้จะง่าย
ชิ้นสี่เหลี่ยมเพื่อลดจำนวนของรูปหลายเหลี่ยม
วาดด้วยระบบ ดังนั้นเทคนิคพื้นผิวการใช้
แผนที่ 2D เนื้อรูปปลาเทียมบน
ชิ้นสี่เหลี่ยมโดยการเรียก gltexcoord2f ( x , y ) วิธีนี้
สามารถใช้ประโยชน์จากฟังก์ชัน VERTEX OpenGL ของเรย์
ว่ายแบบเทียม ปลาที่ถูกสร้างขึ้นโดยการอ่าน
ภาพในรูปแบบที่แตกต่างกันของปลาเทียมและโดยการเรียกฟังก์ชัน gltranslatef
( x , y , z ) และฟังก์ชัน glrotatef ( มุม , X , Y ,
) Z ใน OpenGL เนื่องจากจุดเด่นของการทดลองนี้คือ พฤติกรรมการตัดสินใจ ของปลา
ตั้งประดิษฐ์ นักวิจัยสร้างการก่อสร้างที่ซับซ้อนสำหรับการตั้งค่าของ
ปลาเทียมปลาทั้งหมดภาพที่ใช้ในรูปแบบ 24
หน่วย BMP ขนาด 32 x 32 รหัสหลักที่ใช้ใน
พื้นผิวภาพ ดังนี้
การแปล กรุณารอสักครู่..
