Saturday, September 25, 2010

Bingoho Source code (Experimental)

Download  Bingoho source code from here

This application is just a experimental.. Coordinate system synchronization is not 100% accurate.

Usage of BingMaps in current application  is just a geoImaginary and geocoding services.. Didn't try with tile server implementation.

Works on any application with simple gui,config.xml configuration.

If application is behind firewall, c# code has to be recompiled with proxyObject class which is provided with source code.

If any one fixed the issues within this source code please share to me. :)

Interested to see if any one fixes the coordinate system synchronization




Tuesday, September 14, 2010

Magik Ganesh

I wish you all a Happy Ganesh chaturdhi

1. Start outlook if you have on the machine
2. Download magik file form here. say magik_ganesh.open() on emacs.

program doesn't contain any virous. just access the name from out look. Select "Allow" button in security shown in outlook.

Happy Vinakaya Chavathi .. [Name in Outlook ]. This app is similar to few flash application available

Saturday, July 17, 2010

GSS & Google Flash Maps as a Cloud in Google AppEngine with 3D

Earlier I got a chance to attend a workshop of Cloud computing IN Hyderabad, while studding different concepts and exploring different cloud computing concepts I came across Google App Engine (GAE). I thought of developing a Cloud App for Smallworld on GAE. I am successful on doing on local where App Server runs on local which is a flash GSS client running on App Server. So I deployed the client on App Engine and can be accessible from http://imegis.appspot.com/ . I saw few applications where GSS is integrated with Google Earth. Google Earth is a thick desktop client with can render 3D.



The developed client is thin web client which can render 3D and integrated with GSS.


I Me and GIS is a flash client with very basic services of Google Earth deployed on Google App Engine. ( GSS functionality not deployed on App Engine. this is just a Google flash maps on Google cloud environment)

This is flash client with 3D rendering capabilities will work similar to Google Earth client with same navigation control on the left hand side.



Client is a flash application require flash player 9 or above
3D rendering is implemented using Papervision3D

Load 3D will Render GE Building in 3D. Application can render any 3D object provided corresponding DAE(collada) or kmz available in server. (Please see pics rendering 3d will take 20-30 sec to download the 3D model from App engine)
load KML not implemented on App engine
Print Map will print the current map view

Comments, Suggestions are welcomed

Friday, May 28, 2010

Bingohoo

Finally i am able to integrate Smallworld Application with Bing web map Service + Google Static maps and yahoo maps.

I tried in 3 flavors of Binghoo…A java version, c# with managed code and with sw_dotnet_dll
I am not very successful with Java version as Bing map web services with java is not the best combination and it took lots of time with trouble shooting.
I tried to create the web services using managed C code from C#. This C code is available in …Smallworld\product\data\acp_source\ but performance is not very good.. Sometimes application is hanging (may be because of managed C code)
I could found sw_dotnet_acp_dll in magik components (Thanks to Author: Pedro Miranda for the example)

I just added methods PutObject and GetObject to this dll to make my life easier. (Image transfer from acp to maick makes application slow.. to overcome this problem, the images are cached with coordinate and zoom level. This added two advantages to application

1. No need to go to the server for every pan/zoom if the coordinate is already visited.

2. Headache of transferring image form acp to magik is removed making application faster)

I modified map_view.int!do_render and added few lines in the method

1. Self.application.plugin(:maps).current_map_view…window.render_raster(i_path, 0, 0)

2. I_path << self.get_cached_image_path_for_current_location()
This renders image at 0, 0 of map window and 2nd line will fetch the cached image path if no path exists it will request an image.





The real challenge is, to synchronize smallworld with geo images form 3-4 different map providers.


For Bing maps I tried different mathematical equations to get perfect sync between Smallworld and Bing geo images but still there are not perfectly in sync (see http://msdn.microsoft.com/en-us/library/bb259689.aspx for calculating zoom level for the coordinates)

Zoom level for Google is somewhat fine (see the image) .. The detail images from Yahoo are not of very good quality and at many places they are not in very details so zoom for yahoo maps are not affecting.

Thursday, February 11, 2010

_thisthread.sleep( 3Months)

Yesterday I completed my 2nd semester MS exams.. So I thought to blog a post which I want to do from few days back. ( sorry for the long wait to post )

The first one is web map connector…Its really cool I got a chance to play with it. infact I played with the whole Friday night in the office without going home. Thanks to Alfred Sawatzky and Brad Sileo for providing license.

I really like the application showing Bing maps on smallworld. But why only Bing why not Google, yahoo, open street map, Maps-For-Free, etc not integrated in to the web map connector..?? I don’t know..

I tried putting every thing in to one application and did an investigation and found interesting stuff to put these web maps as a service in to one application..



Bing maps
Google maps
Yahoo Maps

It’s a quite difficult to use Bing maps service in java environment. But using the managed c-acp code to develop in .net environment..

I will try to post the complete developed application in my next post

Friday, January 1, 2010

Smallworld Clouds

Clouds??... What is it..?? Clouds refer to Cloud Computing.

If you are very new to cloud computing then, this is the correct place to know cloud computing

I am studying about cloud computing from quite sometime back.. Last week I got a chance to attend a work shop conducted by IEEE on Clouds in Hyderabad. I am studying some terms like Saas, Paas, Iaas.

What is there in it for smallworld?? before going to find what is there in clouds.. lets see few problems In a Agile way... (Are these really problems.. ???..!!)

As a Electrical energy distributor i am more interested in maintaining and managing my electric network rather than maintaining lot of licenses and computers.

As a Gas Distributor I am more interested to find the critical customers if any gas lines fails rather than finding effecting users/engineers if any computer fails.

As a network operator i am more interested to invest more money to my network rater than buying licenses/computers

and many more

As a Smallworld developer what i can do for the above problems..??

I will provide services to the consumers on demand.(pay for what you used)

I don't want to maintain tens and hundreds of servers with lots of IMAGES in it.. so, i will use infrastructure as a service(Iaas). All the servers are located some where around the world and forget about marinating the servers and just use the images.

I am small electricity distributor, I don't need complete smallworld application.. but I need few application for few hours a week. I use Saas and get required software for few hours and pay for those hours..

These are the few attempts how we can use clouds..

There are many cloud computing applications available, few of them are google apps, Microsoft Azure, Amazon cloud front and ZOHO.

Windows for all is the perfect example for infrastructure as a sevice. you can try it. requires silver light plugin and takes some times to load.
its a Windows operating system in your browser. :)

Can we consider GSS as a step towards Cloud Computing??

All the above are just my imagination those are not related to GE Smallworld or any other company

Looking for comments.. :))

Friday, December 18, 2009

How do I OLE?

I saw a perfect example of using OLE objects in Magik session In Alferd's sworldwatch for regular expression validator (http://sworldwatch.blogspot.com/2009/12/regular-expressions-in-magik.html)
But finding the ole component is not a simple task, if we are looking for something new. It takes good amount of time for searching the ole components like vbscript.regexp.

So we need a tool which lists all the available ole components.

Visual studio comes with Ole Viewer Tool shows list of COM objects and its properties. Which will make life easier to find the objects, What if we don’t have VS.net ..??
Here is the solution (http://support.microsoft.com/default.aspx?scid=kb;en-us;122244)

Download ole2view this application lists all the available COM components in WINDOWS.

Wednesday, December 2, 2009

SW Media Player

sw media player is a simple media player(only audio)
This again works using ole_automation by geting handle on windows media player activex component. ( so becomes platform dependent )




I added lot of actions but couldn't implement all...
it has the basic functionality like play, stop, ff, fr, pause.
Time seek will show the current position of the audio file but it doesn't update if we drag it.

It will work from emacs with three lines of code

.player << ole_client.create_object("wmplayer.ocx")
.control << .player.controls
.player.url << "C:\WINDOWS\Media\Windows XP Logon Sound.wav"

Serves as online radio if URL is replaced with some live radio for eg: live365.com

Download sw mdia player form here

control.stop will stop playing audio file. similarly play, pause etc are available on control class.

I tried to add play list to the tree item with add and remove functionality but finally did nothing

If found any new ideas please add to comments

Sunday, November 8, 2009

Add behavior to Tree Item

I am a big fan of tree_item and Tree_item is one of the most powerful controls provided by magik language. I can't imagine many Office applications with out a tree_item (very few without a tree_item)


From few days I am trying to develop a Yahoo messenger kind of application in magik using tcp/ip communication.

One of my requirements is to show details on mouse over on the list available. But I think the tree_item doesn’t have mouse over functionality added (at least in my scope of knowledge). I spend couple of minutes to provide a customized behavior like mouse over action to tree_item

Here is the way to add the mouse over behavior to tree_item:
(These changes are to tree_agent.magik didnt tried subclassing it)
1. add a pseudo slot say mouse_over_func and define the slot access to writeable
2. add the mouse_over_func to exported_notifiers and notifier_for_action
3. initilise the handler in init() of agent as below
.mouse_over_func << handler.new(_self, :default_mouse_over|()|)
4. enable the events for the tree in window.enable_event(:move)
5. in default_handle_event(), notify to the desired method as below
_if l_id _is :move
_then

_return _self.notify(:mouse_over_func, l_row, l_row_index, p_event)

_endif
6.
_pragma(classify_level=advanced)
_private _method tree_agent.mouse_over_func << p_new
##
##


.mouse_over_func << handler.new(_self, :default_mouse_over|()|)
>> .mouse_over_func
_endmethod
$

7.
method tree_agent.default_mouse_over(p_tree, l_row_index, p_event)
##
##
#write(p_tree, l_row_index, p_event)

_local l_sel_column << _self.column_at(p_event.x)
#do some thing
write(l_sel_column)
_if l_sel_column _is _unset
_then
_return

_endif


_endmethod
$

I just tried this code and I haven’t tested fully… but this is working. I added my custom method in the class as we do for select notifier or double click notifier.. it is working with few tracebacks.. Those are to be handled in tree_agent. default_mouse_over()

Friday, November 6, 2009

sw_narrator

“SW Narrator” is a simple application which reads any action performed on smallworld application. it is as simple as Narrator provided by default in windows operating system. This is developed in magik by using SAPI.

Interestingly heart of the application is only 2 lines

MagikSF> v << ole_client.create_object("sapi.spvoice")
$

MagikSF> v.Speak("smallworld")

Sw narrator gets every action performed by application by add_filter_event to :interaction_mode_event. This will give handle to action and there it retrieves the UI value.

Code written in click_monitor in development tool serves the purpose.

Looking for some online drive to upload the module… I will update once I shared the module.