標籤:緊接上篇博文 , 在擷取拍照拍下的圖片並將其設為背景的時候出現了問題系統給出了這樣的警告:Bitmap too large to be uploaded into a texture意思很明顯:就是現在的手機硬體越來越強悍了(-.-||).拍下來的圖片太大,無法直接展示.網上有說關閉硬體加速喝分區載入的辦法.不過這都不是我想要的.這種問題自然是要壓縮圖片的嘛!!壓縮代碼:/** * 圖片品質壓縮 * **/ private Bitmap
標籤:1.The difference is card.h is the public API.That’s what your dot h is.It’s your public API.It’s what methods in your class you want to make public so that other people can call them.Card.m is your private API and all your
標籤:建立元素節點:document.creatElement(TagName);建立文本節點:document.createTextNode(text);<div id="div1"> <p id="p1">This is a paragraph.</p> <p id="p2">This is another paragraph.</p></div>//新增節點var
標籤:android系統包The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files解決辦法:相應的系統的jar包沒有匯入;選add External JARs...,添加android.jar.650) this.width=650;"
標籤:建立一個 Android Studio 工程時會預設建立兩個 .gitignore 檔案.gitignore*.iml.gradle/local.properties/.idea/workspace.xml/.idea/libraries.DS_Store/build/capturesapp/.gitignore/build但這還不夠。頂層 .gitignore 改成如下才乾淨。從 stackoverflow 找到的,備份於此:# apply from stackoverflow by
標籤:Rect類主要用於表示座標系中的一塊矩形地區,並可以對其做一些簡單操作。這塊矩形地區,需要用左上右下兩個座標點表示(left,top,right,bottom),你也可以擷取一個Rect執行個體的Width和Height。就在這裡,奇葩的事情來了,作為一個有一點經驗的做映像或者矩陣運算或者編程的程式員來說,大家的共識是,如果一個矩陣是MxN的,也就是M行N列,那麼行號是[0,M-1],列號是[0,N-1]。可是奇葩的Rect類並不是這樣的!如果你這麼聲明一個Rect類: Rect