igraph-help
[Top][All Lists]

## Re: [igraph] How to make two 3D images at the same coordinate in a rgl d

 From: Gábor Csárdi Subject: Re: [igraph] How to make two 3D images at the same coordinate in a rgl device? Date: Wed, 2 Nov 2011 09:09:34 -0400

```On Fri, Oct 21, 2011 at 12:33 PM, Zhijiang Wang
> Hi Gabor,
>
>
> Setting rescale = F, that I tried, but the attributes of edge width and
> vertex size disappear in 3D network visulazation.

I am not sure what happens here, could you please send your code and a
screenshot that shows the problem? For me the following works fine. I
get two spheres, and the layout and the vertex sizes and edge widths
are all fine.

library(igraph)
library(rgl)
g <- graph.ring(20)
l1 <- layout.sphere(g) * 2 + 2
l2 <- layout.sphere(g)
rglplot(g, layout=l1, rescale=FALSE, edge.width=30, vertex.size=30)
rglplot(g, layout=l2, rescale=FALSE, edge.width=15, vertex.size=15)

Thanks,
G.

> I am not sure where the problem is. So I'd like to choose another way that
> is seting rescale = T, then transform the 2nd img coordinate like the 1st.
> Even I want to make the 1st coordinate as a normal one for the following
> plotting.
>
> The problem is the normalization of coordinate in drawScene.rgl seems not
> work, whenever I set scale by T or F or a vector.
>
>
>
>
> 于 2011-10-21 23:53, Gábor Csárdi 写道:
>
>
> Dear all members,
>
> I want to visualize two 3D images at the same coordinate in a rgl device.
> 1st 3D plot:
>             I use rglplot, the coordinate is [-1,1]X[-1,1]X[-1,1]
>
> Give rescale=FALSE to rglplot(), and then the coordinates will not be
> rescaled.
>
> G.
>
> 2nt 3D image:
>             I use contour3d(...)
>                   drawScene.rgl(...scale = c(181,217,181))
>
> Now, the problem is the 1st plot is in (-1, 1), but the 2nd plot can not be
> transformed into one like the 1st one.
> The 2nt 3D image looks large than the 1st one.
>
> Great thansk!
> --
>
> Best wishes,
>
> Zhijiang Wang
>
> _______________________________________________
> igraph-help mailing list
> https://lists.nongnu.org/mailman/listinfo/igraph-help
>
>
>
>
>

--
Gabor Csardi <address@hidden>     MTA KFKI RMKI

```