02-28-2013 09:15 PM - 已編輯 02-28-2013 09:23 PM
當我使用CVI的 CVIOGL.fp 的功能在 CVI 建立 Panel 給OpenGl使用時:
// Create OpenGL control on CVI panel
demoControl = OGLConvertCtrl(demoPanel,MAIN_PICTURE);
.......
OGLRefreshGraph(demoPanel,demoControl);
只能出現 3D 個框架 , 無法將附件的 texure貼圖紋理顯示出來,
但是改為使用 auxMainLoop(display); 直接使用 windows Panle 時則可以顯示出來.
auxInitDisplayMode( AUX_RGB | AUX_DEPTH | AUX_DOUBLE );
auxInitWindow( "OpenGL AUX Library Demo" );
auxIdleFunc(display);
.....
auxMainLoop(display);
有人有相關經驗嗎?
在 03-03-2013 08:11 PM
可以試試看下面網址介紹的範例位址
http://digital.ni.com/public.nsf/allkb/D369558F34AA3264862565FC007CBB33
Examples for CVIOGL.FP can be found in the \CVI90\samples\userint\custctrl\cviogl directory. The simple.prj example demonstrates how to plot 3D surfaces and contours on the OpenGL control (see Figure 1).