X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 17 Jan 2011 08:44 PM by  anon
Griding a sphere in Object Graphics
 1 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:
New Member


--
17 Jan 2011 08:44 PM
    I've been trying to map some data onto a sphere (and succeding!) but I have bumped into this problem a couple times and never really been able to find a satisfying way of solving it. The proble is this : I want to put 2 spherical axis' (longitude and latitude) on the sphere on which I am ploting my data. Axis' with steps, and values and possibly titles. All things which are easily done on a 2D contour plot. I've got a couple ideas but I have at least 1 problem with each one : The first one is to simply do it with contour (which has a multitude of options for axis), save the image, then reload it and map it to the sphere. Problem : IDL writting and reading isn't as cool as it could be. Colors often get screwed up and I never can seem to find the right format that makes the process bearable. Secondly, I wanted to try to simply make a "grid" image and map it on top of the image already in place. Hoever, I've found nowhere where I can make parts of my image completely transparent while letting others completely opaque. Thirdly, I've tried using IDLgrAxis but that seems only to work in cartesian. Is their a secret hidden subroutine or proprety that I'm missing (I've often spent hours coding my own only to find out that putting a 1 somewhere would do the trick) or is there something you could suggest? Thanks for the help! Nic

    Deleted User



    New Member


    Posts:
    New Member


    --
    18 Jan 2011 04:59 PM
    Try something like below. It's kind of a quick and dirty example, but something like this should work for you. The MESH_OBJ routine is very usefull in createing quick 3D polygon meshes. Then these polygons can be overlayed. Notice the STYLE=1 keyword on the second IDLgrPolygon. This creates the grid: grid = replicate(1, 36, 18) mesh_obj, 4, verts, polys, grid, /closed sphere = IDLgrPolygon(data=verts, polygons=polys, color=[100,100,255], style=2) grid += 0.001 mesh_obj, 4, verts, polys, grid, /closed thegrid = IDLgrPolygon(data=verts, polygons=polys, style=1, thick=2) omodel = IDLgrModel() omodel.add, sphere omodel.add, thegrid xobjview, omodel -Josh ITTVIS
    You are not authorized to post a reply.