Napisano 5 Lipiec 200717 l Witam Nie wiem czy to dobry dział ale połączenie 3d i flasha chyba jednak mieści się we flashu gdyż to jest plik wyjściowy :) http://www.anens.pl/scorp/SCORP.swf Prosze o ocene :)
Napisano 5 Lipiec 200717 l Czy t jest algorytm renderujący we flashu, czy po prostu odpalenie renderków we flashu?? :>
Napisano 5 Lipiec 200717 l nieźle.. pokaż z fpsami i czasami ładowania :) :P Pokaż też na innych obiektach - boxy, kulki, itp :)
Napisano 5 Lipiec 200717 l Autor A to by wymagalo stworzenie takich rzeczy :) A potem umiejetne ich renderwoanie gdyz jest tam pewien mechanizm. Coś tam pewnie jeszcze zrobie ale to malo czasu na takie zabawy.
Napisano 6 Lipiec 200717 l Nie czaje jaki algorytm ? to przecież animka tylko :P mogę wam to zrobić w 5 min ... ;) z maxa do flasha :P algorytm to byś pisał 3 lata świetlne do takiej animacji ;) this.createEmptyMovieClip("theScene", 1); theScene._x = 150; theScene._y = 150; focalLength = 300; make3DPoint = function (x, y, z) { var point = new Object(); point.x = x; point.y = y; point.z = z; return(point); }; make2DPoint = function (x, y) { var point = new Object(); point.x = x; point.y = y; return(point); }; Transform3DPointsTo2DPoints = function (points, axisRotations) { var TransformedPointsArray = []; var sx = Math.sin(axisRotations.x); var cx = Math.cos(axisRotations.x); var sy = Math.sin(axisRotations.y); var cy = Math.cos(axisRotations.y); var sz = Math.sin(axisRotations.z); var cz = Math.cos(axisRotations.z); var x; var y; var z; var xy; var xz; var yx; var yz; var zx; var zy; var scaleRatio; var i = points.length; while (i--) { x = points[i].x; y = points[i].y; z = points[i].z; xy = cx * y - sx * z; xz = sx * y + cx * z; yz = cy * xz - sy * x; yx = sy * xz + cy * x; zx = cz * yx - sz * xy; zy = sz * yx + cz * xy; scaleRatio = focalLength / (focalLength + yz); x = zx * scaleRatio; y = zy * scaleRatio; TransformedPointsArray[i] = make2DPoint(x, y); } // end while return(TransformedPointsArray); }; pointsArray = [make3DPoint(-50, -50, -50), make3DPoint(50, -50, -50), make3DPoint(50, -50, 50), make3DPoint(-50, -50, 50), make3DPoint(-50, 50, -50), make3DPoint(50, 50, -50), make3DPoint(50, 50, 50), make3DPoint(-50, 50, 50)]; cubeAxisRotations = make3DPoint(0, 0, 0); rotateCube = function () { cubeAxisRotations.y = cubeAxisRotations.y - this._xmouse / 3000; cubeAxisRotations.x = cubeAxisRotations.x + this._ymouse / 3000; var screenPoints = Transform3DPointsTo2DPoints(pointsArray, cubeAxisRotations); this.clear(); this.lineStyle(2, 000000, 100); this.moveTo(screenPoints[0].x, screenPoints[0].y); this.lineTo(screenPoints[1].x, screenPoints[1].y); this.lineTo(screenPoints[2].x, screenPoints[2].y); this.lineTo(screenPoints[3].x, screenPoints[3].y); this.lineTo(screenPoints[0].x, screenPoints[0].y); this.moveTo(screenPoints[4].x, screenPoints[4].y); this.lineTo(screenPoints[5].x, screenPoints[5].y); this.lineTo(screenPoints[6].x, screenPoints[6].y); this.lineTo(screenPoints[7].x, screenPoints[7].y); this.lineTo(screenPoints[4].x, screenPoints[4].y); this.moveTo(screenPoints[0].x, screenPoints[0].y); this.lineTo(screenPoints[4].x, screenPoints[4].y); this.moveTo(screenPoints[1].x, screenPoints[1].y); this.lineTo(screenPoints[5].x, screenPoints[5].y); this.moveTo(screenPoints[2].x, screenPoints[2].y); this.lineTo(screenPoints[6].x, screenPoints[6].y); this.moveTo(screenPoints[3].x, screenPoints[3].y); this.lineTo(screenPoints[7].x, screenPoints[7].y); }; theScene.onEnterFrame = rotateCube; To jest algorytm ;) http://www.graphix-lab.pl/tutoriale/box.swf
Napisano 7 Lipiec 200717 l Nie czaje jaki algorytm ? to przecież animka tylko :P mogę wam to zrobić w 5 min ... ;) z maxa do flasha :P algorytm to byś pisał 3 lata świetlne do takiej animacji ;) True... Ale ogólnie spoko, choć fajniejszy efekt dla mnie to ten realistyczny.
Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto