porgram opengles linux C language

Hello:

      Now i have successfully set up my SDK Packages on my host computers,i also run the tutorials it offers.But when i look into the source code,it comes to be that they have run the main functions.Now i want to write a program,but i just want plus the opengl es code,and not make it as the main function.waht should i do ???i mean that in the tutorials we saw that main function is in the SHell dir? I haven't met this before.Every time i write a program i always write the main function by myself. What should i do???

Best regars!

i have know that in the trainingcourse that the program starts at the point that PVRShell* NewDemo()
{
 return new OGLESIntroducingPVRTools();
}



this function is the start point of the program....if i want to plant it in my own program,what should i do to make it ?

PVRShell is an abstraction layer that allows applications to be written without having to worry about OS and API specific implementation details. You can find out more about the shell on our FAQ page: https://www.imgtec.com/powervr/insider/powervr-faq.asp





The NewDemo() function is used so that the shell can call your implementation of shell functions that have been overrided by your application, such as InitView() and InitApplication(). You can find out more about these functions by either reading through comments in the shell source code (as the source code is included in SDK packages), or you can read through the shell documentation (which can be found in the Shell directory of your SDK package).





If you are only interested in a single target platform, you can write your own main() function . Our HelloTriangle training course provides source code that explains how this can be done.Joe2010-07-05 17:09:23

 At first i thought that hellotriangle don't use the powerVR??Is that true??And I am working on a project about combile GPS and GIS 3D map.So i want to know wether i shold follow the syntax like PVRShell*NewDemo() as the main function?? I saw the navigator demo .it's great but i can't get the demo source,it's not open,so can you give me some advices on it?


best regards!

The HelloTriangle training course does use the POWERVR core, but does not use PVRShell. This is a good starting point for writing an application with its own main() function.





We are planning to release a navigation demo with full source code sometime in the future, but I cannot give you a definite date for the availability of this.





In the meantime, the training courses and demos in the SDK should provide a good starting point for your application. If there are any particular features of the navigation demo that you would like to try and replicate, you can start a new topic on the forums to discuss this or contact the DevTech team directly by sending an email to devtech@imgtec.com.

Dear Joe:


Thanks for your details,I'm glad to wait for the demo  coming out soon.I'm take part in a competition.Tt's time-limited.I'm not experienced.best regard for you reply......Now i'm interested in the powerVR programing.


thanks very much                          

may i ask you some detailed program question?


Now i want to write a program just with some 3Dobject .like a cube or more.just simple object. but i don't know how to rewrite the trainging course code like 04texturing.I don't want to use the later course because there are so many shading file or other files.I don't know how to make them.And they are complex to me now. Please teach me how to draw simple cube in a program. may i have a more efficent way of communication?My ebox:eeweifeng111@163.com  QQ:452019937.


best regard for you                   

If you have little OpenGL graphics experience, there are a number of good free tutorials online to get you started:


http://www.opengl.org/code/





Learning this on desktop platforms first is a better starting point than embedded platforms as it is interactive frame rates can be achieved with greater ease for simple applications. The POWERVR Graphics SDK tutorials build on existing 3D knowledge to help developers learn how to get the most from POWERVR graphics hardware in embedded devices. Once you have a stronger understanding of desktop 3D graphics, it will be easier to transfer these skills to embedded devices.





Once you have done this, it is relatively straight forward to build on applications, such as HelloTriangle, and adding additional vertices, which will allow you to draw more complex geometry