Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 644a0e32 authored by Jason Sams's avatar Jason Sams
Browse files

resolved conflicts for merge of f6309041 to master

parents e30c29fe f6309041
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -68,6 +68,7 @@ public class RenderScript {
    native void nContextDestroy(int con);
    native void nContextSetSurface(int w, int h, Surface sur);
    native void nContextSetPriority(int p);
    native void nContextDump(int bits);

    native void nContextBindRootScript(int script);
    native void nContextBindSampler(int sampler, int slot);
@@ -304,6 +305,10 @@ public class RenderScript {
        nContextSetSurface(w, h, mSurface);
    }

    public void contextDump(int bits) {
        nContextDump(bits);
    }

    public void destroy() {
        nContextDeinitToClient();
        mMessageThread.mRun = false;
+9 −1
Original line number Diff line number Diff line
@@ -189,9 +189,16 @@ static void
nContextDestroy(JNIEnv *_env, jobject _this, jint con)
{
    LOG_API("nContextDestroy, con(%p)", (RsContext)con);
    return rsContextDestroy((RsContext)con);
    rsContextDestroy((RsContext)con);
}

static void
nContextDump(JNIEnv *_env, jobject _this, jint bits)
{
    RsContext con = (RsContext)(_env->GetIntField(_this, gContextId));
    LOG_API("nContextDump, con(%p)  bits(%i)", (RsContext)con, bits);
    rsContextDump((RsContext)con, bits);
}

static void
nContextPause(JNIEnv *_env, jobject _this)
@@ -1346,6 +1353,7 @@ static JNINativeMethod methods[] = {
{"nContextSetPriority",            "(I)V",                                 (void*)nContextSetPriority },
{"nContextSetSurface",             "(IILandroid/view/Surface;)V",          (void*)nContextSetSurface },
{"nContextDestroy",                "(I)V",                                 (void*)nContextDestroy },
{"nContextDump",                   "(I)V",                                 (void*)nContextDump },
{"nContextPause",                  "()V",                                  (void*)nContextPause },
{"nContextResume",                 "()V",                                  (void*)nContextResume },
{"nAssignName",                    "(I[B)V",                               (void*)nAssignName },
+4 −0
Original line number Diff line number Diff line
@@ -42,6 +42,10 @@ ContextSetSurface {
	param void *sur
	}

ContextDump {
	param int32_t bits
}

ContextSetPriority {
	param int32_t priority
	}
+18 −0
Original line number Diff line number Diff line
@@ -209,6 +209,24 @@ void Allocation::removeProgramToDirty(const Program *p)
    rsAssert(0);
}

void Allocation::dumpLOGV(const char *prefix) const
{
    ObjectBase::dumpLOGV(prefix);

    String8 s(prefix);
    s.append(" type ");
    if (mType.get()) {
        mType->dumpLOGV(s.string());
    }

    LOGV("%s allocation ptr=%p mCpuWrite=%i, mCpuRead=%i, mGpuWrite=%i, mGpuRead=%i",
          prefix, mPtr, mCpuWrite, mCpuRead, mGpuWrite, mGpuRead);

    LOGV("%s allocation mIsTexture=%i mIsTextureID=%i, mIsVertexBuffer=%i, mBufferID=%i",
          prefix, mIsTexture, mTextureID, mIsVertexBuffer, mBufferID);

}

void Allocation::sendDirty() const
{
    for (size_t ct=0; ct < mToDirtyList.size(); ct++) {
+2 −0
Original line number Diff line number Diff line
@@ -68,6 +68,8 @@ public:
    void addProgramToDirty(const Program *);
    void removeProgramToDirty(const Program *);

    virtual void dumpLOGV(const char *prefix) const;

protected:
    void sendDirty() const;

Loading