घुमाएं मैं घूर्णन छवि एनीमेशन करने की कोशिश कर रहा हूं। मुझे के आसपास एक आइकन को घुमाए जाने की आवश्यकता है जैसे कि वे प्रोग्रेसबार में करते हैं, लेकिन मुझे जो मिल रहा है वह एक सर्कल के चारों ओर घूर्णन वाली छवि है। यहाँ मेरी एनीमेशन कोड हैएनीमेशन एंड्रॉइड
<?xml version="1.0" encoding="utf-8"?>
<rotate
xmlns:android="http://schemas.android.com/apk/res/android"
android:fromDegrees="0"
android:toDegrees="360"
android:interpolator="@android:anim/linear_interpolator"
android:pivotX="50%"
android:pivotY="50%"
android:duration="2500"
android:repeatCount="infinite"
android:repeatMode="restart"
/>
कहाँ मैं यहाँ में गलत हो रहा हूँ?
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent" >
<Button
android:id="@+id/testButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="animationText"
android:onClick="AnimClick"/>
<ImageView
android:id="@+id/testImage"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:contentDescription="image_desc"
android:scaleType="fitCenter"
android:src="@drawable/cat2" />
</RelativeLayout>
रोटेशन एनीमेशन को लागू करने के लिए, हम XML या जावा कोड द्वारा एनीमेशन को परिभाषित कर सकते हैं: धन्यवाद
धन्यवाद। मैंने छवि में स्केलटाइप जोड़ने की कोशिश की है और फिर भी इससे मदद नहीं मिली है। – orelzion
धन्यवाद, यह काम करता है! – validcat
यह स्वीकार्य उत्तर होना चाहिए था! – Machado