[MOD]Save videos as .mp4 instead of .3gp

Search This thread

scuccia

Senior Member
May 23, 2008
467
103
In the HTC camcorder even you choose the encoding method as MPEG it would save the file as 3gp, but with this it will save the file as mp4. I had to modify a few smali files to get it working.

This is only changing the extension. The videos are already being recorded in an mpeg-4 stream, they are just being created with a .3gp extension. This is really only for people who need the extension to be mp4 for some specific reason.

I have tested this a bit so be sure to back up your original HTCCamera.apk just in case.

Download it here.

As you can see below, nothing with the encoding has changed.

attachment.php



In recovery:

mount system
adb shell
mv /system/app/HTCCamera.apk /system/app/HTCCamera.apk_
exit
adb push HTCCamera.apk /system/app/
adb shell
chmod 0644 /system/app/HTCCamera.apk
exit
adb reboot
 
Last edited:
  • Like
Reactions: setexascustoms

quepaso

Senior Member
Jul 10, 2010
451
88
Does this also change the audio codec to something useable like AAC? Love your roms, use them and enjoy them heavily, mp4 usable on the ps3 would be amazing!
 

scuccia

Senior Member
May 23, 2008
467
103
Does this also change the audio codec to something useable like AAC? Love your roms, use them and enjoy them heavily, mp4 usable on the ps3 would be amazing!

No, I can't change how its encoded. This is only changing the extension. The videos are already being recorded in an mpeg-4 stream, they are just being created with a .3gp extension.
 

shoman24v

Senior Member
Mar 4, 2007
1,334
50
Fresno, CA
Can you make 720p or any other recording resolution do > 30fps. The framerate on 720p is garbage.

Sent from my Droid Incredible using Tapatalk
 

adrynalyne

Inactive Recognized Developer
Dec 13, 2008
10,950
6,471
720p at 30 fps is fine. The problem is that we aren't hitting that fps.

Can't squeeze blood from a turnip, and you cannot make hardware do something its unable to with the current OS.

As for aac audio streams, I doubt this phone supports it. I know where to change it, but so do a lot of people, esp. on the N1 forums. I've not heard of a successful case yet. Not even CM6 does it.
 

quepaso

Senior Member
Jul 10, 2010
451
88
Before i flashed to your newest rom, i decided to try this on the existing rom.. Took footage of my room and what do you know, streams to the ps3 just fine.. But i pressed select and the Audio had dolby digital in it, meaning sound worked.. I took another video but this time played a song. Tried it and it worked!!!

This is AMAZING news! Before i had to sit there and convert the videos and they usually ended up not even working, now using PS3 Media Server, they work no problem. Thanks so much, you should take a look for the Evo guys and get it fixed for them as well if you can, i have a feeling all my evo owning family members are going to want in!
 

adrynalyne

Inactive Recognized Developer
Dec 13, 2008
10,950
6,471
If you folks want to see if the aac audio codec will work, you can try this. Install it via clockwork, but make a nandroid.
 

Attachments

  • cam_audio_aac.zip
    162.1 KB · Views: 119

rspong

Senior Member
Dec 26, 2007
122
7
Palm Springs
720p at 30 fps is fine. The problem is that we aren't hitting that fps.

Can't squeeze blood from a turnip, and you cannot make hardware do something its unable to with the current OS.

As for aac audio streams, I doubt this phone supports it. I know where to change it, but so do a lot of people, esp. on the N1 forums. I've not heard of a successful case yet. Not even CM6 does it.
Well, i look forward to this .MP4 mod cooked into your next Rom, also, the recent WIFItether AP mode. Which by the way works great on your #2 Rom. Great Work.
 

wikywwj

Member
Jul 6, 2010
25
0
Is it possible to record videos that use H.264 when res set to 720p?it should improve its 720p quality.it can only set to WVGA when it uses H.264.
 

quepaso

Senior Member
Jul 10, 2010
451
88
Used the AAC Flash zip. Tried another video, using PS3 media server, it played fine with audio. Decided to plug the phone strait to the PS3 and try it there, Unsupported data on all 3 mp4 files. So no dice on native, but works streamed which is what i wanted in the first place.
 

tdiman

Senior Member
Jun 30, 2010
322
50
Dedham, MA
I was digging through some files on the stock froyo kernel last week and it seems that they may have added mp4 as a container option, although I haven't loaded up the .zip to check.

Sent from my Incredible using XDA App
 

coontag

Senior Member
Jun 18, 2010
189
24
Used the AAC Flash zip. Tried another video, using PS3 media server, it played fine with audio. Decided to plug the phone strait to the PS3 and try it there, Unsupported data on all 3 mp4 files. So no dice on native, but works streamed which is what i wanted in the first place.

Are you using Twonky server to connect to ps3 as a media server... or you got something better?
 

coontag

Senior Member
Jun 18, 2010
189
24
quepaso- PMS is for windows/mac/linux correct? so your saving newly encoded media files to a computer then accessing via the ps3 not connecting android to connect to ps3 directly via a media server. correct?
 

quepaso

Senior Member
Jul 10, 2010
451
88
Yes, i just copy the mp4 file to my media server pc (it houses all my music, pictures and blu-ray movies that get streamed to the ps3s in the house), and the ps3 plays them back fine.

I am not streaming directly from the phone because that would be insanely slow. My entire house is wired with ethernet.
 

coontag

Senior Member
Jun 18, 2010
189
24
hmm... im getting unsupported data error from ps3.

vid records just fine and is stored as mp4 with the acc zip installed... i then i moved video from android to desktop.

When i access the file from ps3 via PMS i can see the file (even with the thumbnail preview)but clicking it causes it to go "unsupported"

any ideas?
 

coontag

Senior Member
Jun 18, 2010
189
24
Will all do respect Quepaso implied that the mp4 extension was already supported by the ps3. If I have to convert from .mp4 to another supported output what's the point in having the vids save as mp4 in the first place?

Sent from my ADR6300 using Tapatalk
 

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    In the HTC camcorder even you choose the encoding method as MPEG it would save the file as 3gp, but with this it will save the file as mp4. I had to modify a few smali files to get it working.

    This is only changing the extension. The videos are already being recorded in an mpeg-4 stream, they are just being created with a .3gp extension. This is really only for people who need the extension to be mp4 for some specific reason.

    I have tested this a bit so be sure to back up your original HTCCamera.apk just in case.

    Download it here.

    As you can see below, nothing with the encoding has changed.

    attachment.php



    In recovery:

    mount system
    adb shell
    mv /system/app/HTCCamera.apk /system/app/HTCCamera.apk_
    exit
    adb push HTCCamera.apk /system/app/
    adb shell
    chmod 0644 /system/app/HTCCamera.apk
    exit
    adb reboot