[xiph-commits] r7321 - in trunk/oggdsf/src: lib/core/ogg/libOOOgg

illiminable at dactyl.lonelymoon.com illiminable
Sun Jul 25 02:30:45 PDT 2004


lib/core/ogg/libVorbisComment tools/iOCE
Message-ID: <20040725093045.EB7B39AAAB at dactyl.lonelymoon.com>

Author: illiminable
Date: Sun Jul 25 02:30:45 2004
New Revision: 7321

Modified:
trunk/oggdsf/src/lib/core/ogg/libOOOgg/OggDataBuffer.h
trunk/oggdsf/src/lib/core/ogg/libVorbisComment/FileComments.cpp
trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.cpp
trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.h
trunk/oggdsf/src/tools/iOCE/frmMain.cs
trunk/oggdsf/src/tools/iOCE/frmMain.resx
Log:
* More fixes in comment editor and library,

Modified: trunk/oggdsf/src/lib/core/ogg/libOOOgg/OggDataBuffer.h
===================================================================
--- trunk/oggdsf/src/lib/core/ogg/libOOOgg/OggDataBuffer.h	2004-07-25 07:49:07 UTC (rev 7320)
+++ trunk/oggdsf/src/lib/core/ogg/libOOOgg/OggDataBuffer.h	2004-07-25 09:30:42 UTC (rev 7321)
@@ -84,6 +84,7 @@
protected:
stringstream mStream;
eState mState;
+
bool processBuffer();
virtual bool dispatch(OggPage* inOggPage);


Modified: trunk/oggdsf/src/lib/core/ogg/libVorbisComment/FileComments.cpp
===================================================================
--- trunk/oggdsf/src/lib/core/ogg/libVorbisComment/FileComments.cpp	2004-07-25 07:49:07 UTC (rev 7320)
+++ trunk/oggdsf/src/lib/core/ogg/libVorbisComment/FileComments.cpp	2004-07-25 09:30:42 UTC (rev 7321)
@@ -109,7 +109,15 @@
return mFileName;
}

-bool FileComments::writeOutAll() {
+bool FileComments::writeOutAll(string inFileName) {
+
+	fstream locFile;
+	locFile.open(inFileName, ios_base::out | ios_base::in | ios_base::binary);
+
+	if (locFile.is_open()) {
+
+
+	}
return false;
}
bool FileComments::writeOutStream(unsigned long inIndex) {

Modified: trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.cpp
===================================================================
--- trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.cpp	2004-07-25 07:49:07 UTC (rev 7320)
+++ trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.cpp	2004-07-25 09:30:42 UTC (rev 7321)
@@ -231,13 +231,22 @@

return locPackSize;
}
-OggPacket* VorbisComments::toOggPacket() {
-	//This needs prefixing data !
+OggPacket* VorbisComments::toOggPacket(unsigned char* inPrefixBuff, unsigned long inPrefixBuffSize) {
+
unsigned long locPackSize = size();
unsigned long locUpto = 0;
-	unsigned char* locPackData = new unsigned char[locPackSize];
+	unsigned char* locPackData = NULL;

-	OggMath::ULongToCharArr(mVendorString.length(), locPackData);
+	if (inPrefixBuff != NULL && inPrefixBuffSize != 0) {
+		locPackSize += inPrefixBuffSize;
+		locPackData = new unsigned char[locPackSize];
+		memcpy((void*)locPackData, (const void*)inPrefixBuff, inPrefixBuffSize);
+		locUpto += inPrefixBuffSize;
+	} else {
+		locPackData = new unsigned char[locPackSize];
+	}
+
+	OggMath::ULongToCharArr(mVendorString.length(), locPackData + locUpto);
locUpto += 4;

memcpy((void*)(locPackData + locUpto), (const void*)mVendorString.c_str(), mVendorString.length());

Modified: trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.h
===================================================================
--- trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.h	2004-07-25 07:49:07 UTC (rev 7320)
+++ trunk/oggdsf/src/lib/core/ogg/libVorbisComment/VorbisComments.h	2004-07-25 09:30:42 UTC (rev 7321)
@@ -57,7 +57,7 @@
bool addComment(string inKey, string inValue);

bool parseOggPacket(OggPacket* inPacket, unsigned long inStartOffset);
-	OggPacket* toOggPacket();
+	OggPacket* toOggPacket(unsigned char* inPrefixBuff, unsigned long inPrefixBuffSize);
string toString();

unsigned long size();

Modified: trunk/oggdsf/src/tools/iOCE/frmMain.cs
===================================================================
--- trunk/oggdsf/src/tools/iOCE/frmMain.cs	2004-07-25 07:49:07 UTC (rev 7320)
+++ trunk/oggdsf/src/tools/iOCE/frmMain.cs	2004-07-25 09:30:42 UTC (rev 7321)
@@ -331,7 +331,7 @@
this.Controls.Add(this.groupBox1);
this.Menu = this.mnuMain;
this.Name = "frmMain";
-			this.Text = "illiminable Ogg Comment Editor";
+			this.Text = "Ogg Comment Editor";
this.Load += new System.EventHandler(this.frmMain_Load);
this.groupBox1.ResumeLayout(false);
this.ResumeLayout(false);

Modified: trunk/oggdsf/src/tools/iOCE/frmMain.resx
===================================================================
--- trunk/oggdsf/src/tools/iOCE/frmMain.resx	2004-07-25 07:49:07 UTC (rev 7320)
+++ trunk/oggdsf/src/tools/iOCE/frmMain.resx	2004-07-25 09:30:42 UTC (rev 7321)
@@ -250,9 +250,6 @@
<data name="$this.TrayLargeIcon" type="System.Boolean, mscorlib, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</data>
-  <data name="$this.DefaultModifiers" type="System.CodeDom.MemberAttributes, System, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>Private</value>
-  </data>
<data name="$this.Localizable" type="System.Boolean, mscorlib, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</data>
@@ -271,4 +268,7 @@
<data name="$this.Name">
<value>frmMain</value>
</data>
+  <data name="$this.DefaultModifiers" type="System.CodeDom.MemberAttributes, System, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>Private</value>
+  </data>
</root>
\ No newline at end of file



More information about the commits mailing list