runtime check for OpenGL

Can I detect at runtime (via script) whether Uniy3D is running in OpenGL mode?

I need to check if the game was compiled using -force-opengl on pc because i could use faster opengl texture transfer via native code then and fallback to slow Texture2D.SetPixels on DirectX elsewise.

The windows standalone will always use OpenGL if it is run with the -force-opengl command line switch. That’s to says the player can run in either OpenGL or DX mode. You might care to consider having a small (non-unity) launcher app that decides whether to use OpenGL or not, and use the switch if OpenGL is the best option on the PC. See http://unity3d.com/support/documentation/ScriptReference/SystemInfo-graphicsDeviceVersion.html to determine if you are running OpenGL or not.