enter image description here
In this image show the result of type "c"
If you see the Json file frame id 7 result.
Code run successfully but frame not load correctly.
Problem is frame id 7 and 8 frame and type "c" look this in Json file
I am creating video collage app
Load frame
9 frame type is "r" и 2 типа кадра "c"
if (str.equals ("r")) {
каркас загрузки.
} else {
Проблема здесь
"c" Кадр типа не загружать
} < /p>
MY CODE
public void a(int i2) {
List list;
int i3;
int i4;
int i5;
int i6;
int i7;
int i8;
int i9;
List list2;
Exception exc;
List list3;
VideoCollageMakerActivity videoCollageMakerActivity;
CollageData collageData = new CollageData();
Exception exc2;
Exception exc3;
VideoCollageMakerActivity videoCollageMakerActivity2 = this;
int i10 = i2;
if (Utils.borderlayout.size() > 0) {
try {
Utils.borderlayout.clear();
} catch (Exception e2) {
e2.printStackTrace();
}
}
String str = ((FrameInfo) videoCollageMakerActivity2.u.imgInfo.get(i10)).frameType;
int i11 = ((FrameInfo) videoCollageMakerActivity2.u.imgInfo.get(i10)).noofRC;
List list4 = ((FrameInfo) videoCollageMakerActivity2.u.imgInfo.get(i10)).rcValues;
if (str.equals("r")) {
try {
int i12 = videoCollageMakerActivity2.x / i11;
int i13 = videoCollageMakerActivity2.v / i11;
int i14 = 0;
int i15 = 0;
i6 = 0;
i5 = 0;
i4 = 0;
i3 = 0;
while (i14 < i11) {
try {
int i16 = ((FrameRCInfo) list4.get(i14)).numRow;
int i17 = videoCollageMakerActivity2.w / i16;
int i18 = videoCollageMakerActivity2.v / i16;
int i19 = i4;
int i20 = i6;
int i21 = i15;
int i22 = 0;
while (i22 < i16) {
try {
list = list4;
try {
LinearLayout linearLayout = new LinearLayout(getApplicationContext());
linearLayout.setLayoutParams(new LayoutParams(i17, i12));
linearLayout.addView(videoCollageMakerActivity2.a(linearLayout, i21));
linearLayout.setX((float) i20);
linearLayout.setY((float) i5);
videoCollageMakerActivity2.f.addView(linearLayout);
CollageData collageData2 = new CollageData();
collageData2.setWidth(i18);
collageData2.setHeight(i13);
collageData2.setXPoint(i19 + 1);
collageData2.setYPoint(i3 + 1);
collageData2.setIsImage(Boolean.valueOf(false));
Utils.collageData.add(collageData2);
i21++;
i20 += i17;
i19 += i18;
BorderAttribute borderAttribute = new BorderAttribute();
if (i22 == 0 && i22 < i16 - 1) {
try {
borderAttribute.setBorderRight(aj);
} catch (Exception e3) {
e3.printStackTrace();
}
}
if (i22 > 0 && i22 < i16 - 1) {
try {
borderAttribute.setBorderLeft(aj);
borderAttribute.setBorderRight(aj);
} catch (Exception e4) {
e4.printStackTrace();
}
}
if (i22 > 0 && i22 == i16 - 1) {
try {
borderAttribute.setBorderLeft(aj);
} catch (Exception e5) {
e5.printStackTrace();
}
}
if (i14 == 0 && i14 < i11 - 1) {
try {
borderAttribute.setBorderBottom(aj);
} catch (Exception e6) {
e6.printStackTrace();
}
}
if (i14 > 0 && i14 < i11 - 1) {
try {
borderAttribute.setBorderTop(aj);
borderAttribute.setBorderBottom(aj);
} catch (Exception e7) {
e7.printStackTrace();
}
}
if (i14 > 0 && i14 == i11 - 1) {
try {
borderAttribute.setBorderTop(aj);
} catch (Exception e8) {
e8.printStackTrace();
}
}
Utils.borderParam.add(borderAttribute);
i22++;
} catch (Exception e9) {
try {
list4 = list;
videoCollageMakerActivity2 = this;
} catch (Exception e10) {
exc3 = e10;
i15 = i21;
i6 = i20;
i4 = i19;
}
}
} catch (Exception e11) {
list = list4;
list4 = list;
videoCollageMakerActivity2 = this;
}
list4 = list;
videoCollageMakerActivity2 = this;
}
List list5 = list4;
i5 += i12;
i3 += i13;
i14++;
i15 = i21;
videoCollageMakerActivity2 = this;
i6 = 0;
i4 = 0;
} catch (Exception e12) {
list = list4;
exc3 = e12;
try {
exc3.printStackTrace();
list4 = list;
videoCollageMakerActivity2 = this;
} catch (Exception e13) {
exc2 = e13;
i7 = i15;
exc2.printStackTrace();
videoCollageMakerActivity2 = this;
int i23 = videoCollageMakerActivity2.w / i11;
int i24 = videoCollageMakerActivity2.v / i11;
int i25 = i7;
i8 = 0;
while (i8 < i11) {
}
}
}
}
} catch (Exception e14) {
list = list4;
exc2 = e14;
i7 = 0;
i6 = 0;
i5 = 0;
i4 = 0;
i3 = 0;
exc2.printStackTrace();
videoCollageMakerActivity2 = this;
int i232 = videoCollageMakerActivity2.w / i11;
int i242 = videoCollageMakerActivity2.v / i11;
int i252 = i7;
i8 = 0;
while (i8 < i11) {
}
}
} **else {
list = list4;
i7 = 0;
i6 = 0;
i5 = 0;
i4 = 0;
i3 = 0;
int i2322 = videoCollageMakerActivity2.w / i11;
int i2422 = videoCollageMakerActivity2.v / i11;
int i2522 = i7;
i8 = 0;
while (i8 < i11) {
List list6 = list;
try {
int i26 = ((FrameRCInfo) list6.get(i8)).numRow;
int i27 = videoCollageMakerActivity2.x / i26;
int i28 = videoCollageMakerActivity2.v / i26;
int i29 = i3;
int i30 = i5;
int i31 = i2522;
int i32 = 0;
while (i32 < i26) {
list2 = list6;
try {
i9 = i11;
try {
LinearLayout linearLayout2 = new LinearLayout(getApplicationContext());
linearLayout2.setLayoutParams(new LayoutParams(i2322, i27));
linearLayout2.addView(videoCollageMakerActivity2.a(linearLayout2, i31));
linearLayout2.setX((float) i6);
linearLayout2.setY((float) i30);
videoCollageMakerActivity2.f.addView(linearLayout2);
collageData.setWidth(i2422);
collageData.setHeight(i28);
collageData.setXPoint(i4 + 1);
collageData.setYPoint(i29 + 1);
} catch (Exception e15) {
try {
list6 = list2;
i11 = i9;
videoCollageMakerActivity2 = this;
} catch (Exception e16) {
exc = e16;
i2522 = i31;
i5 = i30;
i3 = i29;
}
}
try {
collageData.setIsImage(Boolean.valueOf(false));
Utils.collageData.add(collageData);
i31++;
BorderAttribute borderAttribute2 = new BorderAttribute();
if (i32 == 0 && i32 < i26 - 1) {
try {
borderAttribute2.setBorderBottom(aj);
} catch (Exception e17) {
e17.printStackTrace();
}
}
if (i32 > 0 && i32 < i26 - 1) {
try {
borderAttribute2.setBorderTop(aj);
borderAttribute2.setBorderBottom(aj);
} catch (Exception e18) {
e18.printStackTrace();
}
}
if (i32 > 0 && i32 == i26 - 1) {
try {
borderAttribute2.setBorderTop(aj);
} catch (Exception e19) {
e19.printStackTrace();
}
}
if (i8 == 0 && i8 < i9 - 1) {
try {
borderAttribute2.setBorderRight(aj);
} catch (Exception e20) {
e20.printStackTrace();
}
}
if (i8 > 0 && i8 < i9 - 1) {
try {
borderAttribute2.setBorderLeft(aj);
borderAttribute2.setBorderRight(aj);
} catch (Exception e21) {
e21.printStackTrace();
}
}
if (i8 > 0 && i8 == i9 - 1) {
try {
borderAttribute2.setBorderLeft(aj);
} catch (Exception e22) {
e22.printStackTrace();
}
}
Utils.borderParam.add(borderAttribute2);
i30 += i27;
i29 += i28;
i32++;
} catch (Exception e23) {
list6 = list2;
i11 = i9;
videoCollageMakerActivity2 = this;
}
} catch (Exception e24) {
i9 = i11;
list6 = list2;
i11 = i9;
videoCollageMakerActivity2 = this;
}
list6 = list2;
i11 = i9;
videoCollageMakerActivity2 = this;
}
int i33 = i11;
i6 += i2322;
i4 += i2422;
i8++;
i3 = 0;
i2522 = i31;
list3 = list6;
videoCollageMakerActivity = this;
i5 = 0;
} catch (Exception e25) {
i9 = i11;
list2 = list6;
exc = e25;
exc.printStackTrace();
list3 = list2;
i11 = i9;
videoCollageMakerActivity = this;
}
}
}**
HERE IS MY JSON FILE
// frame 7 and 8 not load
// load in else value
// frame type "c"
// frame load but not as it is
{
"collageframes": [{
"id": "frame0",
"type": "r",
"noofrc": "1",
"values": [{
"row": "1"
}]
}, {
"id": "frame1",
"type": "r",
"noofrc": "1",
"values": [{
"row": "2"
}]
}, {
"id": "frame2",
"type": "r",
"noofrc": "2",
"values": [{
"row": "1"
}, {
"row": "1"
}]
}, {
"id": "frame3",
"type": "r",
"noofrc": "3",
"values": [{
"row": "1"
}, {
"row": "1"
}, {
"row": "1"
}]
}, {
"id": "frame4",
"type": "r",
"noofrc": "1",
"values": [{
"row": "3"
}]
}, {
"id": "frame5",
"type": "r",
"noofrc": "2",
"values": [{
"row": "2"
}, {
"row": "1"
}]
}, {
"id": "frame6",
"type": "r",
"noofrc": "2",
"values": [{
"row": "1"
}, {
"row": "2"
}]
},{
"id": "frame7",
"type": "c",
"noofrc": "2",
"values": [{
"row": "2"
}, {
"row": "1"
}]
}, {
"id": "frame8",
"type": "c",
"noofrc": "2",
"values": [{
"row": "1"
}, {
"row": "2"
}]
}, {
"id": "frame9",
"type": "r",
"noofrc": "4",
"values": [{
"row": "1"
}, {
"row": "1"
}, {
"row": "1"
}, {
"row": "1"
}]
}, {
"id": "frame10",
"type": "r",
"noofrc": "1",
"values": [{
"row": "4"
}]
}, {
"id": "frame11",
"type": "r",
"noofrc": "2",
"values": [{
"row": "2"
}, {
"row": "2"
}]
}]
}
< /code>
1.in это и другое значение для загрузки значения
, но не то же самое в файле json i
am создает.
2.2.help Me, что я изменяю.>
Подробнее здесь: https://stackoverflow.com/questions/796 ... c-not-load
Загрузите раму JSON, но загрузите кадр типа "R" и "C" не загружайте ⇐ JAVA
-
- Похожие темы
- Ответы
- Просмотры
- Последнее сообщение