2 * Copyright (c) 2018 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
19 #include <native-image-source-queue-impl-x.h>
22 #include <dali/integration-api/debug.h>
23 #include <dali/integration-api/gl-defines.h>
26 #include <gl/egl-image-extensions.h>
39 #define TBM_SURFACE_QUEUE_SIZE 3
41 const char* FRAGMENT_PREFIX = "\n";
42 const char* SAMPLER_TYPE = "sampler2D";
46 NativeImageSourceQueueX* NativeImageSourceQueueX::New( unsigned int width, unsigned int height, Dali::NativeImageSourceQueue::ColorDepth depth, Any nativeImageSourceQueue )
48 NativeImageSourceQueueX* image = new NativeImageSourceQueueX( width, height, depth, nativeImageSourceQueue );
52 NativeImageSourceQueueX::NativeImageSourceQueueX( unsigned int width, unsigned int height, Dali::NativeImageSourceQueue::ColorDepth depth, Any nativeImageSourceQueue )
56 DALI_LOG_ERROR( "NativeImageSourceQueueX::NativeImageSourceQueueX: Not supported\n" );
59 NativeImageSourceQueueX::~NativeImageSourceQueueX()
63 Any NativeImageSourceQueueX::GetNativeImageSourceQueue() const
68 void NativeImageSourceQueueX::SetSource( Any source )
72 bool NativeImageSourceQueueX::GlExtensionCreate()
77 void NativeImageSourceQueueX::GlExtensionDestroy()
81 unsigned int NativeImageSourceQueueX::TargetTexture()
86 void NativeImageSourceQueueX::PrepareTexture()
90 const char* NativeImageSourceQueueX::GetCustomFragmentPreFix()
92 return FRAGMENT_PREFIX;
95 const char* NativeImageSourceQueueX::GetCustomSamplerTypename()
100 int NativeImageSourceQueueX::GetEglImageTextureTarget()
105 void NativeImageSourceQueueX::SetDestructorNotification( void* notification )
109 } // namespace Adaptor
111 } // namespace internal