资源描述:
《papervision3d- understanding plane object – part 9》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、Papervision3D:understandingPlaneobject–part2 ThistimeIamgoingtoexplainthebasiccolormaterialandatricktomakeaplanehavetaterials,oneperside. Beforeyoucontinuereading,letmesayyoucanthaveaplaneaterials,oneperside.Soifyouareplanningtohaveadoublesidedplane,suchasagam
2、blingcard,youllhavetomakeatrick letmeshoport flash.display.Sprite; import flash.events.Event; import org.papervision3d.cameras.Camera3D; import org.papervision3d.render.BasicRenderEngine; import org.papervision3d.scenes.Scene3D; import org.papervision3d.vieport
3、 org.papervision3d.objects.primitives.Plane; import org.papervision3d.materials.aterial; import org.papervision3d.materials.ColorMaterial; public class papervision extends Sprite { public var vieera:Camera3D = neera3D(); public var renderer:BasicRenderEngine =
4、 nee:aterial = neeMaterial(); public var red_material:ColorMaterial=neaterial,500,750,4,5); public var backplane:Plane=nee,500,750,4,5); public function papervision() { addChild(vieera, vieportingtheColorMaterialclass,theclassusedtoassigncolorstoobjects Li
5、ne17:creatinganeaterial,representingasolidredmaterialasyoucanseefromthe0xff0000colorcode. ColorMaterialacceptsmoreparameterssuchasalphaandaflagtodetermineifitsinteractivebutatthemoment Lines18-19:Creatingtesize,oneaterialmaterialandoneematerial Lines22-25:Pla
6、cingbothplanesonthesameplace,andnoticethatinPapervision3D:understandingPlaneobjectIakingmaterialsasdoublesided,assinglesides.Thismeansplaneswilldisappearoncetheyflipstotheotherside. Line26:Rotatingthesecondplaneof180degreesalongYaxis. Lines32-33:Rotatingthepla
7、nesbyonedegreealongYaxisbutsincetheyhavea180degreesdifferencebetweentheirrotation,whentheredplaneisvis12下一页[感谢阅读这篇文章,..,]ible,theeoneisinvisible,andeplaneisvisible,theredoneisinvisible. Thisname="src"value="2009_10/136069.se,cameraadjustmentandarealakeacardgame
8、withPapervision3D编缉推荐阅读以下文章Papervision3D:understandingPlaneobject上一页12[感谢阅读这篇文章,..,]