egl/egltest/src/eglteststep.cpp
changeset 36 01a6848ebfd7
parent 0 5d03bc08d59c
child 85 cdf2f6e5c390
equal deleted inserted replaced
0:5d03bc08d59c 36:01a6848ebfd7
    29 #include "egltest_image_negative.h"
    29 #include "egltest_image_negative.h"
    30 #include "egltest_vgimagetosurfaces.h"
    30 #include "egltest_vgimagetosurfaces.h"
    31 #include "egltest_image_multithread.h"
    31 #include "egltest_image_multithread.h"
    32 #include "egltest_image_multiprocess.h"
    32 #include "egltest_image_multiprocess.h"
    33 #include "egltest_benchmark_sgimage.h"
    33 #include "egltest_benchmark_sgimage.h"
       
    34 #include "egltest_benchmark_swapbuffers.h"
    34 
    35 
    35 /*
    36 /*
    36 Entry point from egltest to create test step
    37 Entry point from egltest to create test step
    37 */
    38 */
    38 EXPORT_C CEglTestStep* EglTestStepFactory::GetEglTestStep(const TDesC& aStepName)
    39 EXPORT_C CEglTestStep* EglTestStepFactory::GetEglTestStep(const TDesC& aStepName)
    61     else if (aStepName == KDisplay_Positive_Multithread_Stress)                                     testStep = new CEglTest_Display_Positive_Multithread_Stress;
    62     else if (aStepName == KDisplay_Positive_Multithread_Stress)                                     testStep = new CEglTest_Display_Positive_Multithread_Stress;
    62     else if (aStepName == KDisplay_Positive_Multiprocess_Basic)                                     testStep = new CEglTest_Display_Positive_Multiprocess_Basic;
    63     else if (aStepName == KDisplay_Positive_Multiprocess_Basic)                                     testStep = new CEglTest_Display_Positive_Multiprocess_Basic;
    63     else if (aStepName == KDisplay_OOM_ClientHeap)                                                  testStep = new CEglTest_Display_OOM_ClientHeap;
    64     else if (aStepName == KDisplay_OOM_ClientHeap)                                                  testStep = new CEglTest_Display_OOM_ClientHeap;
    64     else if (aStepName == KDisplay_OOM_ClientHeap_Initialize)                                       testStep = new CEglTest_Display_OOM_ClientHeap_Initialize;
    65     else if (aStepName == KDisplay_OOM_ClientHeap_Initialize)                                       testStep = new CEglTest_Display_OOM_ClientHeap_Initialize;
    65 
    66 
    66 	//SyncObject tests excluding WaitFlush which requires OpenVG and OpenGL ES
    67 	// SyncObject tests excluding WaitFlush which requires OpenVG and OpenGL ES
    67 	else if (aStepName == KSyncObject_Positive_GetProcAddress)											testStep = new CEglTest_SyncObject_Positive_GetProcAddress;
    68 	else if (aStepName == KSyncObject_Positive_GetProcAddress)											testStep = new CEglTest_SyncObject_Positive_GetProcAddress;
    68 	else if (aStepName == KSyncObject_Positive_CreateDestroy)										testStep = new CEglTest_SyncObject_Positive_CreateDestroy;
    69 	else if (aStepName == KSyncObject_Positive_CreateDestroy)										testStep = new CEglTest_SyncObject_Positive_CreateDestroy;
    69 	else if (aStepName == KSyncObject_Positive_WaitSignal)											testStep = new CEglTest_SyncObject_Positive_WaitSignal;
    70 	else if (aStepName == KSyncObject_Positive_WaitSignal)											testStep = new CEglTest_SyncObject_Positive_WaitSignal;
    70 	else if (aStepName == KSyncObject_Positive_WaitSignal2)											testStep = new CEglTest_SyncObject_Positive_WaitSignal2;
    71 	else if (aStepName == KSyncObject_Positive_WaitSignal2)											testStep = new CEglTest_SyncObject_Positive_WaitSignal2;
    71 	else if (aStepName == KSyncObject_Positive_WaitDelete)											testStep = new CEglTest_SyncObject_Positive_WaitDelete;
    72 	else if (aStepName == KSyncObject_Positive_WaitDelete)											testStep = new CEglTest_SyncObject_Positive_WaitDelete;
    99 	else if (aStepName == KCreatePixmapSurface_RSgImage_Negative_RSgImage_NotInitialised)			testStep = new CEglTest_CreatePixmapSurface_RSgImage_Negative_RSgImage_NotInitialised;
   100 	else if (aStepName == KCreatePixmapSurface_RSgImage_Negative_RSgImage_NotInitialised)			testStep = new CEglTest_CreatePixmapSurface_RSgImage_Negative_RSgImage_NotInitialised;
   100 	else if (aStepName == KCreatePixmapSurface_Negative_Invalid_Pixmap_Type)						testStep = new CEglTest_CreatePixmapSurface_Negative_Invalid_Pixmap_Type;
   101 	else if (aStepName == KCreatePixmapSurface_Negative_Invalid_Pixmap_Type)						testStep = new CEglTest_CreatePixmapSurface_Negative_Invalid_Pixmap_Type;
   101 	else if (aStepName == KCreatePixmapSurface_Alpha_bit_RSgImage)									testStep = new CEglTest_CreatePixmapSurface_Alpha_bit_RSgImage;
   102 	else if (aStepName == KCreatePixmapSurface_Alpha_bit_RSgImage)									testStep = new CEglTest_CreatePixmapSurface_Alpha_bit_RSgImage;
   102     else if (aStepName == KCreatePixmapSurface_RSgImage_Positive_MantadoryFormatUsageSupport)       testStep = new CEglTest_CreatePixmapSurface_RSgImage_Positive_MantadoryFormatUsageSupport;
   103     else if (aStepName == KCreatePixmapSurface_RSgImage_Positive_MantadoryFormatUsageSupport)       testStep = new CEglTest_CreatePixmapSurface_RSgImage_Positive_MantadoryFormatUsageSupport;
   103 
   104 
   104 	// image tests
   105 	// Image tests
   105 	else if (aStepName == KEGL_Image_SgDriverHandle)												testStep = new CEglTest_EGL_Image_SgDriverHandle;
   106 	else if (aStepName == KEGL_Image_SgDriverHandle)												testStep = new CEglTest_EGL_Image_SgDriverHandle;
   106 	else if (aStepName == KEGL_Image_RSgImage_UseOpenVG_PersistImageData)							testStep = new CEglTest_EGL_Image_RSgImage_UseOpenVG_PersistImageData;
   107 	else if (aStepName == KEGL_Image_RSgImage_UseOpenVG_PersistImageData)							testStep = new CEglTest_EGL_Image_RSgImage_UseOpenVG_PersistImageData;
   107 	else if (aStepName == KEGL_Image_Consistent_Linked_List)										testStep = new CEglTest_EGL_Image_Consistent_Linked_List;	
   108 	else if (aStepName == KEGL_Image_Consistent_Linked_List)										testStep = new CEglTest_EGL_Image_Consistent_Linked_List;	
   108 
   109 
   109 	// image negative tests
   110 	// Image negative tests
   110 	else if (aStepName == KEGL_Image_eglCreateImage_Bad_Parameter)									testStep = new CEglTest_EGL_Image_eglCreateImage_Bad_Parameter;
   111 	else if (aStepName == KEGL_Image_eglCreateImage_Bad_Parameter)									testStep = new CEglTest_EGL_Image_eglCreateImage_Bad_Parameter;
   111 	else if (aStepName == KEGL_Image_UsageBits_Enforcement)											testStep = new CEglTest_EGL_Image_UsageBits_Enforcement;
   112 	else if (aStepName == KEGL_Image_UsageBits_Enforcement)											testStep = new CEglTest_EGL_Image_UsageBits_Enforcement;
   112 	else if (aStepName == KEGL_Image_DestroyImageKHR)												testStep = new CEglTest_EGL_Image_DestroyImageKHR;	
   113 	else if (aStepName == KEGL_Image_DestroyImageKHR)												testStep = new CEglTest_EGL_Image_DestroyImageKHR;	
   113 	else if (aStepName == KEGL_Image_VGImage_From_Invalid_EGLHandle)								testStep = new CEglTest_EGL_Image_VGImage_From_Invalid_EGLHandle;
   114 	else if (aStepName == KEGL_Image_VGImage_From_Invalid_EGLHandle)								testStep = new CEglTest_EGL_Image_VGImage_From_Invalid_EGLHandle;
   114 	else if (aStepName == KEGL_Image_Self_Drawing)													testStep = new CEglTest_EGL_Image_Self_Drawing;
   115 	else if (aStepName == KEGL_Image_Self_Drawing)													testStep = new CEglTest_EGL_Image_Self_Drawing;
   115 
   116 
   116 	//Siblings tests
   117 	// Siblings tests
   117 	else if (aStepName == KEGL_Image_Sibling_Basic)													testStep = new CEglTest_EGL_Image_Sibling_Basic;
   118 	else if (aStepName == KEGL_Image_Sibling_Basic)													testStep = new CEglTest_EGL_Image_Sibling_Basic;
   118 	else if (aStepName == KEGL_Image_Sibling_VGImage)												testStep = new CEglTest_EGL_Image_Sibling_VGImage;
   119 	else if (aStepName == KEGL_Image_Sibling_VGImage)												testStep = new CEglTest_EGL_Image_Sibling_VGImage;
   119 	else if (aStepName == KEGL_Image_Sibling_Two_VGImages)											testStep = new CEglTest_EGL_Image_Sibling_Two_VGImages;
   120 	else if (aStepName == KEGL_Image_Sibling_Two_VGImages)											testStep = new CEglTest_EGL_Image_Sibling_Two_VGImages;
   120 	else if (aStepName == KEGL_Image_Sibling_VGImage_Child)											testStep = new CEglTest_EGL_Image_Sibling_VGImage_Child;
   121 	else if (aStepName == KEGL_Image_Sibling_VGImage_Child)											testStep = new CEglTest_EGL_Image_Sibling_VGImage_Child;
   121 	else if (aStepName == KEGL_Image_Sibling_VGImage_Child_CheckContents)							testStep = new CEglTest_EGL_Image_Sibling_VGImage_Child_CheckContents;
   122 	else if (aStepName == KEGL_Image_Sibling_VGImage_Child_CheckContents)							testStep = new CEglTest_EGL_Image_Sibling_VGImage_Child_CheckContents;
   122 	else if (aStepName == KEGL_Image_Sibling_VGImage_Child_CheckContents_CloseSgEarlier)			testStep = new CEglTest_EGL_Image_Sibling_VGImage_Child_CheckContents_CloseSgEarlier;
   123 	else if (aStepName == KEGL_Image_Sibling_VGImage_Child_CheckContents_CloseSgEarlier)			testStep = new CEglTest_EGL_Image_Sibling_VGImage_Child_CheckContents_CloseSgEarlier;
   123 	else if (aStepName == KEGL_Image_CreatePBufferFromClient_With_Sibling_VGImage)					testStep = new CEglTest_EGL_Image_CreatePBufferFromClient_With_Sibling_VGImage;
   124 	else if (aStepName == KEGL_Image_CreatePBufferFromClient_With_Sibling_VGImage)					testStep = new CEglTest_EGL_Image_CreatePBufferFromClient_With_Sibling_VGImage;
   124 
   125 
   125 	//VgImage to surfaces tests
   126 	// VgImage to surfaces tests
   126 	else if (aStepName == KEGL_Image_VgImage_To_Pixmap)												testStep = new CEglTest_EGL_Image_VgImage_To_Pixmap;
   127 	else if (aStepName == KEGL_Image_VgImage_To_Pixmap)												testStep = new CEglTest_EGL_Image_VgImage_To_Pixmap;
   127 	else if (aStepName == KEGL_Image_VGImage_To_Pixmap_CFbs)										testStep = new CEglTest_EGL_Image_VGImage_To_Pixmap_CFbs;
   128 	else if (aStepName == KEGL_Image_VGImage_To_Pixmap_CFbs)										testStep = new CEglTest_EGL_Image_VGImage_To_Pixmap_CFbs;
   128 	else if (aStepName == KEGL_Image_VgImage_To_pBuffer)											testStep = new CEglTest_EGL_Image_VgImage_To_pBuffer;
   129 	else if (aStepName == KEGL_Image_VgImage_To_pBuffer)											testStep = new CEglTest_EGL_Image_VgImage_To_pBuffer;
   129 	else if (aStepName == KEGL_Image_VgImage_To_Window)												testStep = new CEglTest_EGL_Image_VgImage_To_Window;
   130 	else if (aStepName == KEGL_Image_VgImage_To_Window)												testStep = new CEglTest_EGL_Image_VgImage_To_Window;
   130 
   131 
   144 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_DrawAfterTerminate)						testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_DrawAfterTerminate;
   145 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_DrawAfterTerminate)						testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_DrawAfterTerminate;
   145 	else if (aStepName == KEGL_Image_Multi_Process_FontServer_Upfront)								testStep = new CEglTest_EGL_Image_Multi_Process_FontServer_Upfront;
   146 	else if (aStepName == KEGL_Image_Multi_Process_FontServer_Upfront)								testStep = new CEglTest_EGL_Image_Multi_Process_FontServer_Upfront;
   146 	else if (aStepName == KEGL_Image_Multi_Process_FontServer_Deferred)								testStep = new CEglTest_EGL_Image_Multi_Process_FontServer_Deferred;
   147 	else if (aStepName == KEGL_Image_Multi_Process_FontServer_Deferred)								testStep = new CEglTest_EGL_Image_Multi_Process_FontServer_Deferred;
   147 	else if (aStepName == KEGL_Image_Multi_Process_ThemeServer)										testStep = new CEglTest_EGL_Image_Multi_Process_ThemeServer;
   148 	else if (aStepName == KEGL_Image_Multi_Process_ThemeServer)										testStep = new CEglTest_EGL_Image_Multi_Process_ThemeServer;
   148 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_ProcessTerminate)						testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_ProcessTerminate;
   149 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_ProcessTerminate)						testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_ProcessTerminate;
   149 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_ProcessTerminate2)						testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_ProcessTerminate2;
       
   150 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_ProcessTerminateNegative)				testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_ProcessTerminateNegative;
   150 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_ProcessTerminateNegative)				testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_ProcessTerminateNegative;
   151 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_ReadWrite)								testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_ReadWrite;
   151 	else if (aStepName == KEGL_Image_Multi_Process_VgImage_ReadWrite)								testStep = new CEglTest_EGL_Image_Multi_Process_VgImage_ReadWrite;
   152 
   152 
   153 	// Benchmark
   153 	// Benchmark
   154     else if (aStepName == KBenchmark_CreateCloseImage)                                              testStep = new CEglTest_Benchmark_CreateCloseImage;
   154     else if (aStepName == KBenchmark_CreateCloseImage)                                              testStep = new CEglTest_Benchmark_CreateCloseImage;
   155     else if (aStepName == KBenchmark_Multi_Process_CreateCloseImage)                                testStep = new CEglTest_Benchmark_Multi_Process_CreateCloseImage;
   155     else if (aStepName == KBenchmark_Multi_Process_CreateCloseImage)                                testStep = new CEglTest_Benchmark_Multi_Process_CreateCloseImage;
   156     else if (aStepName == KBenchmark_DrawImage)                                                     testStep = new CEglTest_Benchmark_DrawImage;
   156     else if (aStepName == KBenchmark_DrawImage)                                                     testStep = new CEglTest_Benchmark_DrawImage;
       
   157     else if (aStepName == KBenchmark_SwapBuffers)                                                   testStep = new CEglTest_Benchmark_SwapBuffers;
   157 
   158 
   158 	return testStep;
   159 	return testStep;
   159 	}
   160 	}