SAP 3D Visual Enterprise applications SDK
DVLCore.h
Go to the documentation of this file.
1 /*
2  (C) 2016 SAP SE or an SAP affiliate company. All rights reserved.
3 */
9 #pragma once
10 class IDVLRenderer;
11 
12 
15 #pragma pack(push, 1)
17 {
18 public:
19 
21  char* m_type;
23  char* m_source;
26  const char** m_fields;
27  // The number of pairs in the m_fields array.
28  uint32_t m_count;
30  char* m_name;
31 
33  {
34  m_count = 0;
35  m_fields = nullptr;
36  m_type = m_source = m_name = nullptr;
37  }
38 
39 private:
40  sDVLRootEntityItem(const sDVLRootEntityItem& other); // non construction-copyable
41  sDVLRootEntityItem& operator=(const sDVLRootEntityItem&); // non copyable
42 
43 
44 
45 };
46 #pragma pack(pop)
47 
50 #pragma pack(push, 1)
52 {
53 public:
56 
59 
61  {
62  m_uRootEntitiesCount = 0;
63  m_pRootEntities = nullptr;
64  }
65 
66 private:
67  sDVLRootEntitiesInfo(const sDVLRootEntitiesInfo& other); // non construction-copyable
68  sDVLRootEntitiesInfo& operator=(const sDVLRootEntitiesInfo&); // non copyable
69 
70 };
71 #pragma pack(pop)
72 
99 class IDVLCore
100 {
101 protected:
102  virtual ~IDVLCore() {}//use Release() instead
103 
104 public:
105 
116  virtual DVLRESULT Init(IDVLClient *pDVLClient, uint32_t uVersionMajor, uint32_t uVersionMinor) = 0;
117 
129  virtual DVLRESULT InitRenderer() = 0;
130 
139  virtual DVLRESULT DoneRenderer() = 0;
140 
146  virtual void Release() = 0;
147 
153  virtual uint32_t GetMajorVersion() = 0;
154 
162  virtual uint32_t GetMinorVersion() = 0;
163 
168  virtual uint32_t GetMicroVersion() = 0;
169 
175  virtual uint32_t GetBuildNumber() = 0;
176 
204  virtual DVLRESULT LoadScene(const char *szURL, const char *szOptionalPassword/*set to NULL*/, IDVLScene **ppScene, size_t uBallastBufferSize = 0, sDVLRootEntityItem* pRootEntity = NULL) = 0;
205 
232  virtual DVLRESULT LoadSceneFromVDSL(const char *content, const char *password, IDVLScene **ppScene, size_t uBallastBufferSize = 0, sDVLRootEntityItem* pRootEntity = NULL) = 0;
233 
249  virtual DVLRESULT CreateEmptyScene(IDVLScene **ppScene, size_t uBallastBufferSize = 0) = 0;
250 
251 
258  virtual DVLRESULT RetrieveConfigurationList(const char *szURL, const char *szOptionalPassword, sDVLRootEntitiesInfo* listOfRootEntities) = 0;
259 
265  virtual void ReleaseConfigurationList(sDVLRootEntitiesInfo *pInfo) = 0;
266 
273  virtual IDVLRenderer *GetRendererPtr() = 0;
274 
281  virtual IDVLLibrary *GetLibraryPtr() = 0;
282 
289  virtual void OnLowMemory() = 0;
290 
297  virtual DVLRESULT SetLocale(const char *szLocale) = 0;
298 
305  virtual void ExecuteCallback(void *pCallbackParam) = 0;
306 };
307 
308 
309 
313 DVL_EXPORT IDVLCore* DVLCreateCoreInstance();
314 
315 
316 
317 #ifdef DVL_PLATFORM_ANDROID
318 
321 void DVL_JNI_OnLoad(void *pJavaVM);
322 #endif
char * m_type
An ID type.
Definition: DVLCore.h:21
const char ** m_fields
Definition: DVLCore.h:26
sDVLRootEntityItem * m_pRootEntities
Array of sDVLRootEntityItem structures. The length is defined in the m_uRootEntitiesCount member...
Definition: DVLCore.h:58
Definition: DVLScene.h:586
Definition: DVLCore.h:99
uint32_t m_uRootEntitiesCount
The number of Root entities in the list.
Definition: DVLCore.h:55
DVL_EXPORT IDVLCore * DVLCreateCoreInstance()
Definition: DVLLibrary.h:46
char * m_source
An ID source.
Definition: DVLCore.h:23
Definition: DVLCore.h:51
Definition: DVLRenderer.h:49
DVLRESULT
Defines the result of the operation. May be successful or not.
Definition: DVLTypes.h:37
Definition: DVLCore.h:16
Definition: DVLClient.h:80
char * m_name
Name of the Entity in UTF-8 encoding, can be NULL.
Definition: DVLCore.h:30