The invention discloses a custom script rendering terminal and method, the custom script drawing terminal, including Android system rendering engine, based on storage and sending module, for storing custom scripts and sending the custom script stored identifier to the Android HWUI module; the Android HWUI module is used for receiving the a custom script identifier, custom script storage location parses the custom script identifier corresponding to the custom script loading the custom script corresponding storage location. The invention also discloses a method for drawing a custom script. By setting a custom script identifier corresponding to a custom script storage location, Android HWUI module receives the custom script identifier, not loading the system default script to custom script loading custom script identifier corresponding to the storage location, the Android HWUI module loading a custom script to achieve user-defined rendering effects.
【技術實現步驟摘要】
一種自定義腳本繪制終端及方法
本專利技術涉及移動通信領域,尤其涉及一種自定義腳本繪制終端及方法。
技術介紹
隨著移動設備功能的不斷豐富,人們通過移動設備進行視頻渲染處理后便可在移動設備上方便地觀看視頻。視頻渲染,指的是將圖像數據按幀率在規定時間內按順序輸入到顯存中,再輸出到屏幕上進行顯示,從而呈現出動畫效果的過程。目前,在谷歌公司的Android(安卓)平臺(系統)運行的移動應用程序通常使用View來構建自己的應用界面,而View會經過AndroidFramework的組合抽象成多個繪制命令,這些繪制命令則形成一組顯示列表,保存下來。接下來這些顯示列表會被送到Android的HWUI庫中進行渲染。HWUI通過openGL來實現的一個渲染庫,其主要作用是用openGL實現HWUI對外提供的顯示列表的接口。現有通常情況下,應用界面會被HWUI用其系統默認的shader腳本來渲染。但如果需要實現一些系統原生不支持的特效時,這種方法就不奏效了。但如果不使用Android的View來開發應用界面,工作量又會相當大。
技術實現思路
本專利技術的主要目的在于提出一種自定義腳本繪制終端及方法,旨在解決現有技術中,HWUI只能使用系統默認的shader腳本進行渲染,無法實現用戶自定義渲染特效的技術問題。為實現上述目的,本專利技術一方面提供一種自定義腳本繪制終端,基于安卓系統的渲染引擎,包括:存儲發送模塊,用于存儲自定義腳本并將所述自定義腳本存儲的標識符發送給AndroidHWUI模塊;所述AndroidHWUI模塊,用于接收到所述自定義腳本標識符時,解析所述自定義腳本標識符對應 ...
【技術保護點】
一種自定義腳本繪制終端,基于安卓系統的渲染引擎,其特征在于,包括:存儲發送模塊,用于存儲自定義腳本并將包含所述自定義腳本存儲位置的自定義腳本標識符發送給Android?HWUI模塊;所述Android?HWUI模塊用于接收到所述自定義腳本標識符時,解析所述自定義腳本標識符對應的自定義腳本存儲位置,加載所述自定義腳本存儲位置對應的自定義腳本。
【技術特征摘要】
1.一種自定義腳本繪制終端,基于安卓系統的渲染引擎,其特征在于,包括:存儲發送模塊,用于存儲自定義腳本并將包含所述自定義腳本存儲位置的自定義腳本標識符發送給AndroidHWUI模塊;所述AndroidHWUI模塊用于接收到所述自定義腳本標識符時,解析所述自定義腳本標識符對應的自定義腳本存儲位置,加載所述自定義腳本存儲位置對應的自定義腳本。2.根據權利要求1所述的自定義腳本繪制終端,其特征在于,所述存儲發送模塊包括:存儲模塊,用于存儲自定義腳本;發送模塊,用于根據所述自定義腳本的存儲位置生成所述自定義腳本標識符,將所述自定義腳本標識符發送給AndroidHWUI模塊。3.根據權利要求1或2所述的自定義腳本繪制終端,其特征在于,還包括AndroidView模塊和AndroidFramework模塊;所述AndroidView模塊,用于接收并將所述自定義腳本標識符發送給所述AndroidFramework模塊;所述AndroidFramework模塊,用于接收并將所述自定義腳本標識符發送給所述AndroidHWUI模塊。4.根據權利要求1或2所述的自定義腳本繪制終端,其特征在于,所述AndroidHWUI模塊包括:接收模塊,用于接收所述自定義腳本標識符;解析模塊,用于解析所述自定義腳本標識符對應的自定義腳本存儲位置;加載模塊,用于根據所述自定義腳本存儲位置加載所述自定義腳本。5.根據權利要求4所述的自定義腳本繪制終端,其特征在于,所述自定義腳本標識符為字符串形式的腳本信息通過相應函...
還沒有人留言評論。發表了對其他瀏覽者有用的留言會獲得科技券。