16ab97682fd444586ee135912a4210417a1c8781bJason Sams/*
280d819033d4687507907f787d47379b7b37eae19Jason Sams * Copyright (C) 2012 The Android Open Source Project
36ab97682fd444586ee135912a4210417a1c8781bJason Sams *
46ab97682fd444586ee135912a4210417a1c8781bJason Sams * Licensed under the Apache License, Version 2.0 (the "License");
56ab97682fd444586ee135912a4210417a1c8781bJason Sams * you may not use this file except in compliance with the License.
66ab97682fd444586ee135912a4210417a1c8781bJason Sams * You may obtain a copy of the License at
76ab97682fd444586ee135912a4210417a1c8781bJason Sams *
86ab97682fd444586ee135912a4210417a1c8781bJason Sams *      http://www.apache.org/licenses/LICENSE-2.0
96ab97682fd444586ee135912a4210417a1c8781bJason Sams *
106ab97682fd444586ee135912a4210417a1c8781bJason Sams * Unless required by applicable law or agreed to in writing, software
116ab97682fd444586ee135912a4210417a1c8781bJason Sams * distributed under the License is distributed on an "AS IS" BASIS,
126ab97682fd444586ee135912a4210417a1c8781bJason Sams * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
136ab97682fd444586ee135912a4210417a1c8781bJason Sams * See the License for the specific language governing permissions and
146ab97682fd444586ee135912a4210417a1c8781bJason Sams * limitations under the License.
156ab97682fd444586ee135912a4210417a1c8781bJason Sams */
166ab97682fd444586ee135912a4210417a1c8781bJason Sams
176ab97682fd444586ee135912a4210417a1c8781bJason Samspackage android.renderscript;
186ab97682fd444586ee135912a4210417a1c8781bJason Sams
196ab97682fd444586ee135912a4210417a1c8781bJason Sams/**
2080d819033d4687507907f787d47379b7b37eae19Jason Sams * Base class for all Intrinsic scripts. An intrinsic a script
2180d819033d4687507907f787d47379b7b37eae19Jason Sams * which implements a pre-defined function. Intrinsics are
2280d819033d4687507907f787d47379b7b37eae19Jason Sams * provided to provide effecient implemtations of common
2380d819033d4687507907f787d47379b7b37eae19Jason Sams * operations.
2480d819033d4687507907f787d47379b7b37eae19Jason Sams *
2580d819033d4687507907f787d47379b7b37eae19Jason Sams * Not intended for direct use.
266ab97682fd444586ee135912a4210417a1c8781bJason Sams **/
2780d819033d4687507907f787d47379b7b37eae19Jason Samspublic abstract class ScriptIntrinsic extends Script {
287a629fac82f88126642081b4474879f6a883e313Tim Murray    ScriptIntrinsic(long id, RenderScript rs) {
296ab97682fd444586ee135912a4210417a1c8781bJason Sams        super(id, rs);
301c8da1cccedc7194cc02edbdf26249bc3550195cJason Sams        if (id == 0) {
311c8da1cccedc7194cc02edbdf26249bc3550195cJason Sams            throw new RSRuntimeException("Loading of ScriptIntrinsic failed.");
321c8da1cccedc7194cc02edbdf26249bc3550195cJason Sams        }
336ab97682fd444586ee135912a4210417a1c8781bJason Sams    }
346ab97682fd444586ee135912a4210417a1c8781bJason Sams}
35