The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
 All Forums
 Origin Forum for Programming
 Forum for Origin C
 3D-Layers

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Anti-Spam Code:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkUpload FileInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
rlewis Posted - 08/18/2004 : 4:44:06 PM
Is there an OriginC method for determining whether an Origin Graph is Three dimensional other than something like


GraphPage gPG=Project.Pages(-1);
GraphLayer Lay=gPG.Layers(-1);
bool Flag;
if(gPG.IsValid())
{
Flag=LabTalk.Layer.Is3D;
}


//

I found the constant EXIST_PLOT_3D in the OC_const.h file but I do not know which functions(s) use it ....
3   L A T E S T    R E P L I E S    (Newest First)
cpyang Posted - 08/19/2004 : 11:34:33 AM
Until we provide a solution to this in Origin 8, use the following for now,

 
void test()
{
GraphLayer gl = Project.ActiveLayer();
if(gl)
{
Tree tr;
bool bIsXYZ = true;
try {
tr = gl.ZAxis.Scale;
}
catch(int nErr)
{
bIsXYZ = false;
}
if(bIsXYZ)
out_str("Is XYZ layer");
else
out_str("No Z axis found");
}
}




CP


Edited by - cpyang on 08/19/2004 11:40:48 AM
rlewis Posted - 08/19/2004 : 11:20:45 AM
Using Mike Buess's test code, I find that the pb.GetType() call returns EXIST_PLOT with all types of GraphPages. The value returned by pb.GetType() did not depend upon the type of GraphLayer (i.e. whether 2D or 3D) or combination of GraphLayers present on the GraphPage.
Mike Buess Posted - 08/19/2004 : 10:40:45 AM
EXIST_PLOT_3D is used by PageBase::GetType

PageBase pb;
pb = Project.Pages();
if( pb.GetType() == EXIST_PLOT_3D )
printf("%s is a 3D plot.\n",pb.GetName());

Is it possible to have a multi-layer graph page with a mixture of 2D and 3D plots? That might be a problem here.

Mike Buess
Origin WebRing Member

The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000