ActionScript 3.0 :: 3D Rotating Sphere Texture?
Dec 29, 2010
i'm trying to achieve the effect of a rotating sphere given a regular 2D texture. the best thing i've seen is a tutorial on emanueleferonato.com which gives this result: emanueleferonato dot com /downloads/mapping09.swf as you can see, it works pretty well when you're moving left/right OR up/down. it fails to simulate realistic rolling when going in any diagonals (since it's a very simplistic illusion). how to render such a sphere given any point on a mercator projection and then have the sphere rotate in an arbitrary (but fixed) direction? this is a bit advanced math stuff.
btw, if anyone's interested, i figured a better displacement map than what is used in the link i showed
i started my search again and immediately bumped into this: [URL] it's library called BitmapSphere and it does exactly what i need it to! also, could admin edit this and put together the link or something? i find it highly annoying that i need 50 posts before being able to post a link
View 7 Replies
Similar Posts:
Apr 19, 2011
I have a flat circular texture in a bitmap for a project I am working on. Its a texture generated with the perlin noise functions. I wish to extrude the centre of the image using displacementmapfilter so the circle appears to be a 3d sphere. There will be no animation on the sphere. I'm not getting anywhere with it though, My code is below with my broken implementation of the displacement filter.
[Code]..
View 7 Replies
May 21, 2010
I want to attach spheres to rotating sphere but I've encountered some rotation problems:
In application u can rotate mainSphere in both x and y axiss'.
If I rotate main sphere in only x axiss or only y axiss, it works correctly. But if I rotate main sphere around both x and y axiss, sphere is attacing the wrong place.
Here is the code:
ActionScript Code:
// these are the spheres containers. Sphere container class extends form object3d
var mainSphere:SphereContainer3D;
var attachingSphere:SphereContainer3D;
[Code].....
View 1 Replies
Nov 1, 2005
I have a rotating menu that sets the selected button to the 3:00 position once clicked. I need the labels for the buttons to stay in the upright position as they rotate with the button. I have attached an image. Anyone know of an action script that would keep the labels upright?
View 8 Replies
Nov 22, 2009
Code:
package {
import flash.display.Sprite;
import org.papervision3d.cameras.Camera3D;
[Code].....
I've imported the correct folder in my Edit->Prefences->ActionScript 3.0 settings. I've instantiated an object and it compiles, and I'm not getting any errors but, nothing shows up on the screen.
View 1 Replies
Aug 27, 2010
I'm doing 3d gallery in AS3 and i have run in to huge problem. After ActionScript creates 3d sphere it doesnt go away no mater if i go forward or backwards in timeline.
View 0 Replies
Apr 9, 2010
I am making a splash screen for a program and I have a picture in my head of a spinning sphere with pictures on it.I've already made my sphere and mapped my design onto the sphere in illustrator, although it is not as clear as I wanted.How do i get the sphere into flash and animate it to spin continuously?
View 1 Replies
Jan 28, 2009
How would you do it? Or, else, how would you create a world? I.e. what I need is to place the sphere in the way the distance form the camera to it's center is less then the sphere's radius.
View 2 Replies
May 24, 2009
The basic concept: I want to at runtime overlay (or paste or whatever) one bitmap image asset onto another. The original image asset is a texture on a 3d sphere.Example:3D Sphere with earth texture applied to it. Put a cloud on the earth texture and have cloud move along the earth.
Caveats:Can't use any composite materials because I take a serious perf hit. Want to try working only with bitmaps to see if it is faster.I've gotten this far but don't know how to fill rectangle with jpeg file and certainly have no idea where to go from here..earthBitmap= new BitmapData( 256, 256, true); fillRect will only do a color ... I need what fills a rect with jpeg image and how to edit a bitmap on the fly.
View 2 Replies
Nov 6, 2009
I am trying to rotate a sphere with the mouse on the x and y axis but the sphere keeps 'roll'ing and flipping it all around.
package {
import flash.display.Sprite;
import flash.events.Event;
import flash.events.MouseEvent;
[code]....
View 1 Replies
Jul 25, 2011
if anyone has any info on animating a point around a "sphere" with actionscript. If anyone has an actionscript equation defining this motion
View 4 Replies
May 14, 2010
i am developing an application where client can add his photos to appear on a sphere or ball or coffee cup and able to save them and give it for printing using flex. like itasveer.com site. i tried to use away3D but if the image is small it is stretched and added to sphere. i dont want it to strech instead the original image shud appear on the sphere. if it is added to cup it shud cover only the circular part it shud not add this to top and bottom.
View 1 Replies
Dec 30, 2011
How position plane in sphere papervision3d as3 ?
I have a problem , how position a plane in surface of sphere.
View 1 Replies
Oct 21, 2009
The effect I would like to achieve is when the plane around the sphere is clicked, the sphere rotates so that the plane is in the middle of the stage. but there always some problems when i clicked the plane the sphere seems like never rotate to it's back.[code]
View 3 Replies
Jun 22, 2009
I am a newbie to Papervision. I want to design a sphere with 8 holes around one of its diameters. How do I do it? How do I draw anything on a sphere in Papervision?
View 1 Replies
Feb 9, 2010
I want to create an animating sphere representing the earth but here is the catch I want the users to be able to spin it round in real time, what tools will do the trick?
View 3 Replies
Apr 19, 2010
for the past two weeks I've been working on coming up with a collision detection system for my game in flash CS4. No matter what I try for some reason I just can't seem to do it, and I don't know how to fix it. This has never been an issue for me, I would even settle for basic rectangle to rectangle collision if I could, but no matter what I do I end up screwing it at all up. Somehow the collision detection either doesn't work at all, works for one side and jumps the guy through the wall on any other side or I think at one point it worked for two sides as long as I didn't hold down more than one movement key.
I've constantly scrapped what I've done over and over, right now I have no source code to present. I'm totally lost and confused, and my deadline for getting this done is today in a few hours. I really wanted to figure this out on my own but honestly I just don't see what I can do, I've got sphere to sphere collision detection working perfectly for my player and other spheres, but the walls are squares lined up to form long rectangles, and I just can't seem to get it to work. I'm dynamically loading the square-wall blocks as tiles to form a dynamically loaded map, and then I'm iterating through each individual block to determine if collision has occurred with the player. I think somehow I'm not managing the results right, or maybe I somehow need to be able to determine which direction the player hit the wall from, but I just don't know how to do it.
I've been staring at the screen for the past 3 hours trying to work something out but nothing is coming to me, example from a flash-type game or something similar I would be very grateful! (I've done this countless times in C++, C#, and java. I don't get what is going on in flash :-(((( )
View 2 Replies
Dec 6, 2010
I want to create a 3D cylinder, sphere, cone using Actionscript for Flash Player 10. Is there any available class? I also want to know how to paint gradient, wrap text and texture around them. It would be nice if these class have these functions. I can't use non DisplayObject in this project so PV3D is not an option
View 2 Replies
Mar 16, 2011
I am creating a 3D sphere gallery with ActionScript 3 and the Flash 10 3D (2.5D) APIs. I have found a method that works but is not ideal. I would like to see if there is a better method.
[Code]...
To see this in action, click here. alternate link. Notice that with the default settings, the number of items actually in the sphere are less by 13. I believe is the error introduced by my approximation in the first step.
I am not able to figure out a method for determining what the exact radius of such a sphere should be. I'm hoping to learn either a better method, the correct method, or that what I am trying to do is hard or very hard (in which case I will be happy with what I have).
View 2 Replies
Nov 6, 2009
I am currently building a sphere of images that I'm trying to load from a remote location using XML. I managed to find the source for the sphere and was able to figure out how load the XML into an array of image details.
My problem is that the sphere is made up of images that were loaded into the library and I'm trying to load them in dynamically, i got all the information from XML but i don't understand how to make these dynamic images the same as the ones in the library so i can instantiate the image object.
thumbsArray[0]=[new Bitmap(new Small1(thumbWidth,thumbHeight))];
Small1 = the name of one of the image in the library that makes up the sphere. if i go to the properties of this Small1 image i noticed that its class is called Small1 too. I don't understand this as iv never seen this in actionscript 2.0.
The code below is my attempt at making a image loader object to a bitmap object, that doesnt seem to work my bitmap object becomes null, and throws an error.
SYNTAX / CODE:
function getLoader(url) {
var loader:Loader = new Loader();
loader.contentLoaderInfo.addEventListener(Event.CO MPLETE, completeHandler);
[Code]......
View 0 Replies
Nov 11, 2009
I'm creating a ball bouncing in 3d. My problem is that I have a square boundaries. top,bottom, front, back. I tried get the the distance ( of the sphere/radius) but went I * vx , vy , vz by 1 or -1. One of the position is - while the other two might by positive. I need pool ball physics with the boundary be a 3d sphere.
View 9 Replies
Jul 7, 2010
I need to know what side of a rotated box my sphere/point is colliding with and at what angle.
I could perform the 4 lines check but I think it will be too cpu consuming. I need it for fast simple physics simulations(bounces)..
View 9 Replies
Feb 28, 2011
I have been programming flash for a while, but I suppose I never really learned flash "correctly", and I have my shortcuts and I cut corners sometimes. I'm now trying to render a sphere.
Code:
circleraduis = 500;
camerax = 275;
cameray = 200;
for (degrees = 0; degrees < 180; degrees += 30) {
xradius = Math.cos (degrees) * (Math.PI / 180) * circleraduis;
yvalue = Math.sin (degrees) * (Math.PI / 180) * circleraduis;
[Code] .....
View 6 Replies
Jun 8, 2010
I'm an animator and have always drawn with pen and paper (old schooool) and then coloured using photography in photoshop. I'm just starting a new project where I'll be using flash for the animation.
Question: If I am illustrating using the pen tool (black stroke), how can I easily colour each object with photography? As I am such a beginner the only way I know is to animate my sequence(s) then export a pdf sequence, and subsequently colour each frame individually in Photoshop.
View 1 Replies
Mar 31, 2010
I am becoming crazy because I really don't find a way to preload the texture image which is automatically loaded by the DAE class.
All that I want is to display the progression of the image loading, before displaying the DAE.
View 5 Replies
Jul 6, 2009
how i could create a background like this site has [URL]
You see there is a little texture in it, and the texture matches every screen size. The gradient effect is no problem but how can i make the texture also match every screensize?
View 1 Replies
Dec 15, 2011
Now I'm trying to use molehill to accelerate my collision detection effeciency, and I found out there is a function called setRenderToTexture that I can use. However, when I get a texture from that function, I cannot access pixel data in it. Does anyone knows how to deal with that, or is there another way to use molehill to do such general-purpose computation?
View 1 Replies
Jan 31, 2010
I am new to working with papervision and just want to add a simple spinning sphere inside a movieclip and have it positioned on the stage where I want it. For some reason when it creates the sphere, it doesn't place it on the registration points, but puts it in the bottom right corner of the stage and is cut off.
Here is ActionScript Code:
var viewport:Viewport3D=new Viewport3D(0,0,true,true);
addChild(viewport);
var renderer:BasicRenderEngine = new BasicRenderEngine();
var scene:Scene3D = new Scene3D();
var camera:Camera3D = new Camera3D();
[Code] .....
View 0 Replies
Oct 17, 2010
[code]...
That is changing colors (the ARRAY_COLOURS have [ 0xFF0000, 0x0000FF, 0xFFFF00 ])
I would like to have instead of that something like ARRAY_COLOURS[ IMAGE1, IMAGE2, IMAGE3 ]
View 1 Replies
Sep 3, 2011
Here i am looking to apply the texture to the Text and Movie Clip dynamically.
View 2 Replies