Remove unused custom shader prefix method
[platform/core/uifw/dali-adaptor.git] / dali / internal / imaging / ubuntu-x11 / native-image-source-queue-impl-x.cpp
index 6488487..8023374 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2021 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
 #include <dali/integration-api/gl-defines.h>
 
 // INTERNAL INCLUDES
+#include <dali/internal/adaptor/common/adaptor-impl.h>
 #include <dali/internal/graphics/common/egl-image-extensions.h>
 #include <dali/internal/graphics/gles/egl-graphics.h>
-#include <dali/internal/adaptor/common/adaptor-impl.h>
 
 namespace Dali
 {
-
 namespace Internal
 {
-
 namespace Adaptor
 {
-
 namespace
 {
-#define TBM_SURFACE_QUEUE_SIZE  3
-
-const char* FRAGMENT_PREFIX = "\n";
-const char* SAMPLER_TYPE = "sampler2D";
+#define TBM_SURFACE_QUEUE_SIZE 3
+} // namespace
 
-}
-
-NativeImageSourceQueueX* NativeImageSourceQueueX::New( uint32_t width, uint32_t height, Dali::NativeImageSourceQueue::ColorDepth depth, Any nativeImageSourceQueue )
+NativeImageSourceQueueX* NativeImageSourceQueueX::New(uint32_t width, uint32_t height, Dali::NativeImageSourceQueue::ColorFormat colorFormat, Any nativeImageSourceQueue)
 {
-  NativeImageSourceQueueX* image = new NativeImageSourceQueueX( width, height, depth, nativeImageSourceQueue );
+  NativeImageSourceQueueX* image = new NativeImageSourceQueueX(width, height, colorFormat, nativeImageSourceQueue);
   return image;
 }
 
-NativeImageSourceQueueX::NativeImageSourceQueueX( uint32_t width, uint32_t height, Dali::NativeImageSourceQueue::ColorDepth depth, Any nativeImageSourceQueue )
-: mWidth( width ),
-  mHeight( height )
+NativeImageSourceQueueX::NativeImageSourceQueueX(uint32_t width, uint32_t height, Dali::NativeImageSourceQueue::ColorFormat colorFormat, Any nativeImageSourceQueue)
+: mWidth(width),
+  mHeight(height)
 {
-  DALI_LOG_ERROR( "NativeImageSourceQueueX::NativeImageSourceQueueX: Not supported\n" );
+  DALI_LOG_ERROR("NativeImageSourceQueueX::NativeImageSourceQueueX: Not supported\n");
 }
 
 NativeImageSourceQueueX::~NativeImageSourceQueueX()
@@ -67,9 +60,9 @@ Any NativeImageSourceQueueX::GetNativeImageSourceQueue() const
   return Any();
 }
 
-void NativeImageSourceQueueX::SetSize( uint32_t width, uint32_t height )
+void NativeImageSourceQueueX::SetSize(uint32_t width, uint32_t height)
 {
-  mWidth = width;
+  mWidth  = width;
   mHeight = height;
 }
 
@@ -77,12 +70,27 @@ void NativeImageSourceQueueX::IgnoreSourceImage()
 {
 }
 
-bool NativeImageSourceQueueX::GlExtensionCreate()
+bool NativeImageSourceQueueX::CanDequeueBuffer()
+{
+  return false;
+}
+
+uint8_t* NativeImageSourceQueueX::DequeueBuffer(uint32_t& width, uint32_t& height, uint32_t& stride)
+{
+  return nullptr;
+}
+
+bool NativeImageSourceQueueX::EnqueueBuffer(uint8_t* buffer)
+{
+  return false;
+}
+
+bool NativeImageSourceQueueX::CreateResource()
 {
   return true;
 }
 
-void NativeImageSourceQueueX::GlExtensionDestroy()
+void NativeImageSourceQueueX::DestroyResource()
 {
 }
 
@@ -95,23 +103,33 @@ void NativeImageSourceQueueX::PrepareTexture()
 {
 }
 
-const char* NativeImageSourceQueueX::GetCustomFragmentPreFix()
+bool NativeImageSourceQueueX::ApplyNativeFragmentShader(std::string& shader)
 {
-  return FRAGMENT_PREFIX;
+  return false;
 }
 
-const char* NativeImageSourceQueueX::GetCustomSamplerTypename()
+const char* NativeImageSourceQueueX::GetCustomSamplerTypename() const
 {
-  return SAMPLER_TYPE;
+  return nullptr;
 }
 
-int NativeImageSourceQueueX::GetEglImageTextureTarget()
+int NativeImageSourceQueueX::GetTextureTarget() const
 {
   return 0;
 }
 
+Any NativeImageSourceQueueX::GetNativeImageHandle() const
+{
+  return nullptr;
+}
+
+bool NativeImageSourceQueueX::SourceChanged() const
+{
+  return false;
+}
+
 } // namespace Adaptor
 
-} // namespace internal
+} // namespace Internal
 
 } // namespace Dali