Display Browsable 3D models in Browser - browser

Statement: I have a 3D model ready in Google SketchUp Pro.
Problem Statement:
I need to display the model in a webpage.
I need the model to be browsable (The user can navigate his way through it like on Google Earth)
I need the model to be update-able (If I update something in SketchUp, I should be able to easily port changes till the webpage)
Question: How can this be done?
Note: I figured out VRML could be an option, but I was unable to get that idea up and running.

Have you investigated the Sketchup Web Exporter plugin (still in beta at time of writing)?
If that doesn't do exactly what you're after, you can write a plugin yourself using the Sketchup API, allowing you to write plugins in Ruby or C++.

You can now use SketchUp in the browser, and it should be able to read anything coming from SketchUp Pro. Check out https://my.sketchup.com

Related

Apps Script vs Chrome Extension: Writing an alternative spellchecker to Google Docs

Say, I want to develop an alternative spellcheck module to google docs.
This means that I have to get corrections from my backend, and color the misspelled text's background, and do a small popup bubble when user hovers over it, where I'd display the correction. (please mind that spellcheck is not the actual goal of my project, but it does address my problems in a more simplified way)
What are my options? Any ideas how to do this?
Few possible solutions I came up with:
Chrome extension vs Apps script
Chrome extension
pros: user has to grant permissions once, can freely traverse and append anything to dom via content script
cons: is a "hacky" way, if google changes classnames or js source, it would stop working, and also, reverse engineering google docs's editor engine is impossible
Apps script
pros: supported by google: if it works, I dont need to be afraid of docs updates
cons: it seems to me that I can't just fiddle with the dom (because of Caja compiler), has very limited support (if any) for custom highlighting or hover functionality.
As I see it, neither of these are perfect solutions for this project. What do you think? Any suggestions are very welcomed.
I know this is an old question, but I have recently gotten into the same problem, and believe I have a solution. So for future Googler's I will post my answer here.
My solution was to create a Chrome Extension and understand how the Google Docs DOM's are structures to interact with it.
You can find my code to work with the Google Doc DOM's here
In Apps Script you can't "fiddle" with the DOM and you won't be able to implement hover functionality. Also, a lame Highlighting would involve changing the current document itself (which would go to revision history, undo queue, etc)
Therefore, your only altertive is the Chrome Extension. But I agree with you on the cons. It is a super hard task that could break at any minute without notice.

How can I programmatically show the select device dialog?

I am using the Cast Companion Library and most of it is working well however I have not been able to figure out how to show the device chooser programmatically.
Basically when a user chooses a video on my app I would like to show the chooser if they haven't yet connected.
Thanks.
If you are using the MediaRouteButton and it's accessible:
mediaRouteButton.performClick();
you need to "Developing a custom UI with the MediaRouter API’s and MediaRouter.Callback" but I didn't find any example how to do it .
First, I suggest you do not do that. I don't know what you are planning to do in your app so I can't say much but don't do something custom in terms of user interaction/flow that is different from other apps and the apps offered by the framework; people will not expect that.
On the technical side, if you want to open the standard dialog, I am not aware of any trick but I haven't looked at the MediaRouter code in v7 support library for that; since that is open source, you are welcome to look in there and see if there is any simple way to do that. If you want to design your custom one, you should be able to do that; the CastCompanionLibrary provides a sample of the Callback dialog and the one for chooser follows a similar pattern.
As a side note, you mentioned you want to open the chooser when user selects a movie. So how can they select to play locally? Are you planning to add additional selection to that dialog for local playback?

How to record audio in a Chrome Extension?

What's the simplest way to setup a chrome extension to record audio from the microphone?
I see there is a working experimental speech input API but how come you don't have access to the recorded file? Seems like hooking up into that should be simple enough, as it's a step earlier in the process, no? Especially as there is also a text-to-speech API, so you could effectively record into text and then have the computer speak it back out, but unless you want a standard voice, how lame, redundant and prone to error is that?
Then there seem to be flash solutions like this but how can I use that in a chrome extension without having to setup anything server-side? (since I don't actually need to send anything to a server--it's all local and client-side)
Is NPAPI a possibility? Is there such a plugin ready-made?
Don't know of other possible alternatives (HTML5 isn't ready yet, it seems) but I welcome anything functional and simple to implement and hook into a chrome extension.
Finally a native solution appeared: Introducing getUserMedia
You cannot use the speech input API, since it will record only the microphone. Okay, you can grab the speakers like that, but it's clearly not the solution.
Using a NPAPI plugin is a solution. You'll can identify the sound made by a particular tab and after record that source, but it is no longer web dev.

Is it possible to modify code generated by PhoneGap and how would this effect apps market application process?

Is it possible to modify/supplement code generated by PhoneGap to modify/add functionality? And how does this effect the application's likelihood of being accepted into the apps market?
The reason I am asking is because there are certain components of the desired iPhone application that we would like to have that we can not achieve with our converted CakePHP web application. These desired items include QR code scanning and augmented reality.
Yes, you can do that.
https://github.com/phonegap/phonegap-plugins
You can look there for already written (and validated) plugins.
If I remember correctly, a qrscanner plugin already exists.
Augmented reality it not really possible with phonegap. (At least not as far as I know) As you can't manipulate the camera view with phonegap.
Maby if you would write a plugin for it. But that would mean writing almost the whole application in objective-C.

View models in a browser

Is there a way to view models in a browser via flash, Java or anything else?
The models would be stored on my server with the client viewing it along with textures and anything else the model would need.
I would like any browser app that works ideally with 3ds.
VRML is mostly dead, but you might still be able to find a browser plugin for it. This page leads to some newer 3D web technologies: http://en.wikipedia.org/wiki/Vrml
Check this out:
http://blog.promethe.net/2008/12/24/display-half-life-3d-models-with-flash-10/
It mentions something called DirectFlex as well, which I haven't used personally, but at any rate, either of these links might point you in the right direction with respect to using Flash 10 to display your models. Hope it helps!

Resources