So I have just stumbled upon some augmented reality stuff done in Flash and it got me super excited. I am just looking for some pointers right now. What I would like to be able to do is overlay images on a webcam at specific GPS coordinates. The couple of libraries that I've seen (FLARManager and IN2AR) appear to be based on motion tracking which isn't exactly what I'm looking for. Are there any AS3 libraries that can help do this? Many Thanks.
I'm assuming the key to your project is to get the user's GPS coordinate, and based on this to 'do stuff'.
If you use the native geo-location classes, you can already approximate the users' GPS position: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/sensors/Geolocation.html
However, on a desktop it will not work.
For desktop, you can use a Javascript approach in the HTML to feed the data back into the Flash app: Geolocation in Flash
Then just do your image overlay code on your webcam image as required (though if you don't require motion tracking, I'd be interested to know what sort of 'augmented reality' your project is doing!)
Related
This is my first post, wooohooo! I've been using stack exchange when I needed information but usually someone had the same problem as me and I didn't need to make a post. Which means this website is really good.
Now turns out I have a pretty unique problem.
Please check out http://gaia.tru.ca/birdMOVES/
You will see a website with a google map. It is connected to a db which will be automatically updated.
The purpose of this website is to track how birds feed. There is going to be bird feeders equipped with NFC all over the world to track birds equipped with RFID when they feed.
I am taking care of the front-end, the web app for visualizing.
This is a work in progress so try not to care about the looks of it.
Apparently everything was written in RApache because the person who made everything this far is a Geography teacher(Not a lot of programming background, I had to refactor his code and learn R because it wasn't in my array of known languages.)
My client asked me to add time animation to his map. Feasible with the help of Google Earth.
I made the existing R code generate a tour. It works perfectly and even shows on my map.
Here is the address of my dev server: http://thelab.dyndns.org:1080/birdmoves/
You can see that there is an extra check box for time animation. If you check it, the tour will appear as an object on the map (no way to use it whatsoever right now).
So what I'd like to know is how do I make it work? How do I make it autoplay when the submit button is pressed? With standard google earth controls for rewind, pause and fast-forward. And independently from the google maps without tour?
This is intense. I have the feeling google earth isn't going to work because they deprecated all their gadgets.
I'm on the clock and I need help.
In case you were wandering what eventually happened:
We ended up making a hybrid website where the static visualization is within Google maps using kml and the time animation is within CesiumJs using CZML.
CZML is based off JSON and can be used very similarly to kml.
The api is also very nice, it only takes one line of javascript code to get a map running on an existing server.
To implement time visualization CZML supports putting multiple consecutive values for almost any property(like position, to animate movement, or even color to change colors) and takes account of time.
Also very nice, CesiumJs supports animated 3d models!
If you're interested http://cesiumjs.org/
It also has a lot of support, documentation and tutorials... etc..
It's being maintained by professionals. I really recommend it.
The Google Earth API got deprecated and will not function by December this year which is not a viable option for a long term service. So cesium was the only option for this specific project.
Cheers
I have for a really long time been searching for a tutorial for an augmented reality application where the users can rotate and\or move a rendered 3D object with hand movements. I have found a few example applications of this, but none with viewable sourcecode, or in any way allowing me to change the models loaded.
What I need is either a working application that I can tamper with in AS3, or a decent tutorial for creating this kind of motion tracking. (I have been able to create a motion tracking application in itself, but not as an AR application where the models loaded are the ones affected by my movement.)
I am rather new to augmented reality programming, and only have the basics of marker based AR down, but I really don't need anything fancy, nor do I particularly need to understand the cone 100% (though obviously it would be better if I did). I just need it to work.
What you need is FLAR toolkit.
http://www.libspark.org/wiki/saqoosha/FLARToolKit/en
Here's a tutorial: http://mlab.taik.fi/mediacode/archives/1939
Enjoy
I'm searching for Depth map algorithm for action scrip 3 (or some other language).
My goal is to generate depth map for static image on run time.
I have fount this example http://kode80.com/2009/06/29/papervision-zbuffer-and-dof/, i didn't have the time to investigate it's code but i have the filling its working only with 3d models.
Worst viable option is server side technology that does the work.
Extended description:
I have a task to develop flash application where 3d rotation of a head is simulated by a 2d image uploaded by the user.
There are some japan guys that have managed to do that (http://hairtry.jp/), but the technology that they are using is server side. It generates swf fail with precisely coped eyes and image for the depth map of the uploaded picture. I can't find out what is the sever side technology that they are using so I'm searching for any posible workarounds.
Thanks in advance.
Cheers,
Chavdar Slavov
your easiest solution would be to use a 3d engine, Paper vision seems to be getting out dated, theres a lot of documents on how to use, and tutorials but again not much has been happening with them lately. i suggest Away3d "www.away3d.com" they seem up to date.
for what your asking it is possible to do this 100% in flash but to create a 3d head at runtime and fill the face with hieght maps this is possible, you would need to look at bitmap manipulation.i dont think this is an easy task, what you should learn first is how to add an image to a spheric surface dynamically than look into height mapping by converting certain coulours from the image into different levels of depth i must say im sure this is advanced stuff, i manged to animate a globe that was this same method it looks dodgy but it gives you some source code in the FLA
http://www.ffiles.com/flash/animations/globe_animation_3496.html
The above link will allow you to download my source files, the animation it self is a scrolling image but i used Actionscript to give the globe depth and a sheric look
I was taking a look at this example, http://gardengnomesoftware.com/samples/pano2vr_3/mozart/ and I was really interested in how it was done.
Do you think it would be complicated to develop such a function using one of the webgl engines out there? Is the panorama image just a texture on a cylindrical model? How is the panorama "cut?"
Perhaps it is just a cube with the images as a texture? You can kind of see the faces when it is loading slowly.
Yes, in this case it is simply a cube that the "camera" is centered in. It's basically the same concept as a skybox in many video games.
How to create a cube-map from photos the way they've done isn't something I have experience with, but the wikipedia article links to some tools that may help, including Hugin
Is there a way to embed Sketchup models on a website? Preferably a free one, if it's a commercial solution I'd like a confirmation that it's actually worth the money... I know about the 3D warehouse thingy where you can rotate it (javascript and some images), but I can't upload anything to the 3D warehouse 'cause it always "resets the connection".
You can try the upcoming WebGL Functions in modern Browsers. There are some Javascript Libraries that can read model files and show them within your (HTML 5?) website. I have not used them yet, but try these links if this sounds interesting:
https://github.com/mrdoob/three.js/
https://github.com/timjb/sketchup-threejs/
I made a patch of an example game in three.js. Added ColladaLoader and Sketchup model + Third Person Shooter controls:
https://github.com/irony/Nemesis
Try it out (Works best in Chrome)
http://peaceful-woodland-4410.herokuapp.com/index.html
You can use http://sketchfab.com, they even have a SketchUp exporter.
Yes, you can do it without cost. See here: https://help.sketchup.com/en/article/3000258
EDIT:
There were some free rendering sites apart from Google, but they don't seem to be in operation anymore. Posting to the Google 3D warehouse is going to be your best bet. Regarding your problem posting there, try it with Chrome.
EDIT #2:
If you don't want to upload to Google 3D Warehouse, you can achieve a similar effect with a little work. 3D Warehouse doesn't actually give the visitor the power to manipulate something in 3D, but rather it lets them "rotate" the image horizontally by simply showing a series of preset images of the 3D from various angles. You can take shots of your 3D object, import to Photoshop and create your own gif of the spinning object. A little more work than relying on Google, so you'll have to decide if it's worth it.
EDIT #3: If all else fails you can simply post the 3D model on your site as a downloadable file and advise visitors to get Sketchup to view it.